From 7a6138597e5e154d57319ff1c27cb614841a4315 Mon Sep 17 00:00:00 2001 From: Ben Doherty Date: Fri, 5 Apr 2024 17:50:07 -0700 Subject: [PATCH] Metal re-apply: throw an NSException when attempting to draw with invalid program (#7741) --- filament/backend/src/metal/MetalDriver.mm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/filament/backend/src/metal/MetalDriver.mm b/filament/backend/src/metal/MetalDriver.mm index f0e23ccb033..f99a6b63a66 100644 --- a/filament/backend/src/metal/MetalDriver.mm +++ b/filament/backend/src/metal/MetalDriver.mm @@ -1634,7 +1634,7 @@ return; } - ASSERT_PRECONDITION(bool(functions), "Attempting to bind an invalid Metal program."); + functions.validate(); auto [fragment, vertex] = functions.getRasterFunctions();