Posts

Post not yet marked as solved
1 Replies
563 Views
I've attached a SCNProgram to a SceneKit's geometry, and I'm trying to pass uniforms to the fragment shader. In my simple code snippet I just pass the output color to the fragment shader as a uniform, which returns it as an output value.I've already tested the shaders and they work, in the sense that I can succesfully rotate an object in the vertex shader, or draw an object in a different color in the fragment shader, etc... but the problem is when I pass the uniforms. This is my fragment shader:struct Uniform { float4 color; }; fragment float4 myFragment(MyVertexOutput in [[ stage_in ]], constant Uniforms& uniforms [[buffer(2)]]) { return uniforms.color; }And this is how I try to pass the uniforms in my SceneKit+Swift code:SCNTransaction.begin() cube.geometry?.setValue(NSValue(SCNVector4:SCNVector4(0.0,1.0,0.0,1.0)), forKey: "uniforms.color") SCNTransaction.commit()But my object (it's a cube) is not even drawn (it's black), and I get this error: 2016-04-01 01:00:34.485 Shaded Cube[30266:12687154] SceneKit: error, missing buffer [-1/0]
Posted
by ramy.
Last updated
.
Post marked as solved
4 Replies
2.3k Views
I am developing a human activity recognition application for iOS and watchOS that uses Core Motion, Core Location and Health Kit and I am encountering some problems using these frameworks. Bugs that I cannot solve alone so I am thinking about submitting a TSI to Apple.But the TSI page says: "DTS does not provide support for pre-release software. You can post questions about pre-release software on the Apple Developer Forums.I am planning to put my application on the App Store, but it's not fully developed yet, I'd say that it's 40% done and it's not even in iTunes connect yet. I am still allowed to ask for a TSI?
Posted
by ramy.
Last updated
.