When i run my app on ios 10 device and xcode 8 i'm getting the following message in debug console. Can any one know why this is happening
ERROR /BuildRoot/Library/Caches/com.apple.xbs/Sources/VectorKit/VectorKit-1230.32.8.29.9/GeoGL/GeoGL/GLCoreContext.cpp 1763: InfoLog SolidRibbonShader:
ERROR /BuildRoot/Library/Caches/com.apple.xbs/Sources/VectorKit/VectorKit-1230.32.8.29.9/GeoGL/GeoGL/GLCoreContext.cpp 1764: WARNING: Output of vertex shader 'v_gradient' not read by fragment shader
The error is related to the Simulator's rendering methods & framework, as opposed to those of a real device.
The issue should not reproduce on a real device.
Please see a full answer here
Related
I am loading a 3D object into ARKit on a MTLDevice with textures programmatically (.dae + .jpg) and it has transparency. However, when I set the objectNode.transparency property to anything other than 1.0 (the default float value), then I receive the following error and the app crashes: Function(commonprofile_frag): incorrect type of texture (MTLTextureTypeCubeArray) bound at texture binding at index 7 (expect MTLTextureTypeCube) for u_radianceTexture[0].' I have looked at Apple's documentation and developer blog and it seemed to be an error from an earlier Xcode version - however I am running the latest full release - 10.1 (10B61).
It turns out I actually solved this by popping into the Product>Scheme>EditScheme>Options tab and disabling "Metal API Validation". Everything seems to be working properly as of now... does this expose to scrutiny from Apple and/or possible errors? Why did this work as a solution?
We have an app that uses Metal to render. This app works correctly on devices running iOS11. When using the same app on devices running iOS12, we started getting glitches and sometimes hangs in the rendering. We also tried recompiling for iOS12 and are getting the same bad behavior. On the console we are getting the following different messages:
2018-09-22 09:22:29.508576-0500 OurApp [1286:84481] Execution of the command buffer was aborted due to an error during execution. Discarded (victim of GPU error/recovery) (IOAF code 5)
2018-09-22 09:29:55.654426-0500 OurApp [1286:84625] Execution of the command buffer was aborted due to an error during execution. Caused GPU Hang Error (IOAF code 3)
2018-09-22 09:34:37.718054-0500 OurApp [1286:87354] Execution of the command buffer was aborted due to an error during execution. Ignored (for causing prior/excessive GPU errors) (IOAF code 4)
With the first two messages the rendering seems glitchy, where a blank screen is presented and then finally the rendering occurs on screen. With the last message the rendering doesn't actually occur and the message continues being displayed until we move to a different view.
This app uses SceneKit, instantiates a SCNView and uses a default CIContext. It also uses the Physically Based Lighting model, which forces the Metal renderer to be used. The app has a simple SCNNode geometry, a cylinder. Each geometry object of the cylinder gets a normal texture (3 in total). The same diffuse, metalness and roughness values are applied to all the geometry objects of the cylinder.
Has anybody ran into this problem? If so, how did you solve it?
Thanks
UPDATE: The problem seems to be caused when an image is used as the scene's lighting environment:
let scene = SCNScene()
scene.lightingEnvironment.contents = UIImage(named: "ourLightingEnvironmentImage")
When a lighting environment isn't used, the problem goes away. This is starting to look like an Apple bug, we will file one. We are stuck because we need the lighting environment to produce realistic reflections for the models in our app.
It's a bug, caused by high resolution environment lightning images.
The solution is to resize these images, 1000x500 is what we are using now. Works perfectly.
I was able to solve my issues for the moment by choosing OpenGL ES as render mode:
I just received an update to the bug I had filed with Apple:
Apple Developer Relations
We believe this issue is resolved in the latest iOS 12.2 beta. Please test with the latest iOS beta. If you still have issues, please update your bug report with any relevant logs or information that could help us investigate. iOS beta https://developer.apple.com/download/"
I seem to be having the exact same problem. Also using ARKit and the default sceneKit Editor, I kept getting the IOAF code 4 error infinitely when the screen freezes up.
I fixed my problem by changing the environment from "Procedural Sky" to "None". Doesn't lag or freeze anymore, but this is hardly the solution as my AR object now has no lighting or environment. I believe there is a fix coming in iOS 12.2 Beta, but have yet to update.
Hope my solution helps others.
I'm making a 2D game using Unity, i exported the game to Android and it runs smoothly with no problems, i exported the same game to Xcode and then i installed the game on my iPhone, it doesn't crash but the log gives me those warning:
GfxDevice: creating device client; threaded=1
Initializing Metal device caps: Apple A11 GPU
Initialize engine version: 2017.3.1f1 (fc1d3344e6ea)
WARNING: Shader Unsupported: 'Hidden/BlitToDepth' - Pass '' has no
vertex shader
WARNING: Shader Unsupported: 'Hidden/BlitToDepth' - Setting to default
shader.
WARNING: Shader Unsupported: 'Hidden/BlitToDepth_MSAA' - Pass '' has no
vertex shader
WARNING: Shader Unsupported: 'Hidden/BlitToDepth_MSAA' - Setting to
default shader.
Setting up 1 worker threads for Enlighten.
.....
...
And the movement in the game is a little bit laggy. (but on Android devices the movement is smooth)
I searched all over the internet and i tried every solution there is. Nothing seems to work.
Any suggestions?
EDIT
I tried this but it didn't work.
EDIT2
Unity says that this is a bug and the problem is resolved, i don't see the solution!.
It has been a while since I have used XCode, but since Apple revieled XCode 6 and the new Metal API I had to check it out.
They have released examples, e.g. a converted version of their Basic3D example. I am having problems making them compile and run, though. I had to add paths the Quatz and Metal frameworks for compilation and linking to work - thought that should have worked out of the box with build-in libraries?
Also the metal shader compilation step fails, it can not find the metal compiler. Where in XCode is that path setup?
If I ignore the shader compilation step I get an error that the application will not run on any of the simulators. Can metal based 3D applications only run on actual hardware and not in simulator mode?
According to a staff on Apple dev forums, Metal does not run in the simulator.
See: https://devforums.apple.com/message/971605#971605
If you look at other samples/app templates there is no need to explicitly link any framework, indeed everything runs out of the box.
You can't run metal on simulator but you can use this workaround so that it will still compile as long as you have a fallback for the code.
http://medium.com/#jscampbell/bare-metal-working-with-metal-and-the-simulator-70e085e3a45
I started with the hello triangle example they give you to download. It contains all the platform #if's you need to know about. I recommend you get that project and take a look.
https://developer.apple.com/documentation/metal/hello_triangle
#if TARGET_OS_SIMULATOR
#error No simulator support for Metal API. Must build for a device
#endif
Im trying to add light options to kiwiviewer for visualization of medical 3D Models, in my case a surface model of a head.
I cant find a starting point for hours becouse when I delete all glsl shaders I still get the console output "INFO: Compiling shaders:" without error and the View with the 3D Model displaying correctly
I would appreciate any help.
Manuel
At build time, each shader is encoded into a cpp file and compiled into the library named libvesShaders.a. If you modify a shader, but do not recompile the library and relink the application, the app will continue to operate with the previous version of the shader.
If you want to avoid the recompile step, you could create a new shader file and add it to the xcode project so that the file is packaged with the app. Then read the shader source from the file on the iOS filesystem at runtime.
You might want to try the VES mailing list for VES and KiwiViewer questions in the future.