BabylonReactNative: iOS Playground Crashing With MTLRenderPassDescriptor texture and resolveTexture size mismatch
I know this is a heavy work in progress but I’m trying to get the iOS playground working but can’t seem to get past this crash after successfully building in Xcode.
_MTLValidateResolveTexture:328: failed assertion `MTLRenderPassDescriptor texture and resolveTexture size mismatch.'
With the crash taking me to line 167-169 at BabylonNative/Dependencies/bgfx/bgfx/Header Files/renderer_mtl.h
// Creating Command Encoders
id<MTLRenderCommandEncoder>renderCommandEncoderWithDescriptor(MTLRenderPassDescriptor* _renderPassDescriptor) {
return [m_obj renderCommandEncoderWithDescriptor:_renderPassDescriptor];
}
Have tried deleting then re-cloning and following build instructions a couple times with no luck, and was able to get the MacOS build target to work with no problems. Also tried building on simulator and real device with same outcome.
I’m on MacOS 10.15.2 and Xcode 11.4.1. Any help would be greatly appreciated!
Edit: Added the cmake output below which I imagine would be helpful
-- Merging integrated CMake 3.14+ iOS,tvOS,watchOS,macOS toolchain(s) with this toolchain!
-- Building with Xcode version: 11.4.1
-- Configuring iphoneos build for platform: OS64COMBINED, architecture(s): arm64;x86_64
-- Using SDK: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS13.4.sdk for platform: OS64COMBINED
-- Disabling bitcode support by default on simulators. ENABLE_BITCODE not provided for override!
-- Hiding symbols visibility by default. ENABLE_VISIBILITY not provided!
-- Using NON-strict compiler checks by default. ENABLE_STRICT_TRY_COMPILE not provided!
-- Using C compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang
-- Using CXX compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++
-- Using libtool: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool
-- Using install_name_tool: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/install_name_tool
-- Will combine built (static) artifacts into FAT lib...
-- Using a data_ptr size of 8
-- Building for minimum iphoneos version: 12 (SDK version: 13.4)
-- Version flags set to: -mios-simulator-version-min=12
-- Disabling bitcode support.
-- Disabling ARC support.
-- Hiding symbols (-fvisibility=hidden).
-- Not setting any manual command-line buildflags, since Xcode is selected as generator.
-- Merging integrated CMake 3.14+ iOS,tvOS,watchOS,macOS toolchain(s) with this toolchain!
-- Building with Xcode version: 11.4.1
-- Configuring iphoneos build for platform: OS64COMBINED, architecture(s): arm64;x86_64
-- Using SDK: iphoneos for platform: OS64COMBINED when checking compatibility
-- Using libtool: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool
-- Will combine built (static) artifacts into FAT lib...
-- Using a data_ptr size of 8
-- Building for minimum iphoneos version: 12 (SDK version: 13.4)
-- Version flags set to: -mios-simulator-version-min=12
-- Disabling bitcode support.
-- Disabling ARC support.
-- Hiding symbols (-fvisibility=hidden).
-- Not setting any manual command-line buildflags, since Xcode is selected as generator.
-- The C compiler identification is AppleClang 11.0.3.11030032
-- The CXX compiler identification is AppleClang 11.0.3.11030032
-- Check for working C compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang
-- Check for working C compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++
-- Check for working CXX compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found Git: /usr/bin/git (found version "2.24.2 (Apple Git-127)")
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Success
-- Found Threads: TRUE
-- Finding Git version for SPIRV-Cross.
-- Git hash: 3e53273c
-- The Swift compiler identification is Apple 5.2.2
-- Configuring done
-- Generating done
-- Build files have been written to: /Users/kanethomas/dev-projects/BabylonNative/Build
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 15 (7 by maintainers)
I do not get the crash on BabylonNative Playground. I will just clone the ReactNative one again and see if my issue is still happening with a fresh install and if it is, make an issue there. Thanks for the help and the workaround!
Can confirm it’s working on a real device and simulator.
Yeah that’s working for me, and screen sizing is correct now too.