diff --git a/impeller/BUILD.gn b/impeller/BUILD.gn index 01feaa41eb27a..b206c99e9f584 100644 --- a/impeller/BUILD.gn +++ b/impeller/BUILD.gn @@ -13,6 +13,10 @@ config("impeller_public_config") { defines += [ "IMPELLER_SUPPORTS_PLATFORM=1" ] } + if (impeller_supports_rendering) { + defines += [ "IMPELLER_SUPPORTS_RENDERING=1" ] + } + if (is_win) { defines += [ "_USE_MATH_DEFINES" ] } diff --git a/impeller/entity/BUILD.gn b/impeller/entity/BUILD.gn index d5062f3038971..51c2766dbc99b 100644 --- a/impeller/entity/BUILD.gn +++ b/impeller/entity/BUILD.gn @@ -87,6 +87,7 @@ impeller_component("entity_unittests") { deps = [ ":entity", + "../geometry:geometry_unittests", "../playground", ] } diff --git a/impeller/renderer/backend/metal/command_buffer_mtl.mm b/impeller/renderer/backend/metal/command_buffer_mtl.mm index ebdd3d2d75242..f5a9667479756 100644 --- a/impeller/renderer/backend/metal/command_buffer_mtl.mm +++ b/impeller/renderer/backend/metal/command_buffer_mtl.mm @@ -53,6 +53,18 @@ return CommandBufferMTL::Status::kError; } +// TODO(dnfield): remove this declaration when we no longer need to build on +// machines with lower SDK versions than 11.0.s +#if !defined(MAC_OS_X_VERSION_11_0) || MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_11_0 +typedef enum MTLCommandEncoderErrorState : NSInteger { + MTLCommandEncoderErrorStateUnknown = 0, + MTLCommandEncoderErrorStateCompleted = 1, + MTLCommandEncoderErrorStateAffected = 2, + MTLCommandEncoderErrorStatePending = 3, + MTLCommandEncoderErrorStateFaulted = 4, +} API_AVAILABLE(macos(11.0), ios(14.0)); +#endif + API_AVAILABLE(ios(14.0), macos(11.0)) NSString* MTLCommandEncoderErrorStateToString( MTLCommandEncoderErrorState state) {