Closed projectBreakableAccAPI closed 11 months ago
I should also add that when the update is done in Update or LateUpdate I get pretty bad flickering, which doesn't happen with transforms. I'm currently using FixedUpdate to get around this, but that means that the model only updates its position at about 50 fps. So, I guess I'm really asking, "Why is it flickering?" and, "How can I update its position faster?"
Ok final update, I did some tests with delaying a transform's position, and the same flickering occurred so that means I just need to know how to update the instance a frame earlier and all of the other problems should disappear.
I don't believe I see this issue in any of the demos, have you tried looking at the parasitedemo
This demo calculates the positions of the bones of an entity every frame
If they don't come up in the animator it's most likely due to its inclusion in the Instance Modification pass, as it appears a lot of my issues thus far stem from the execution order. Is there a way I can make GPU Instance receive and apply instance changes immediately after the default scripts execute? Like, is there a change I can make to the Script Execution Order?
When you are setting the positions/animations/etc you are setting them for what will happen on the next render
You can see what the Update function is doing here: It will update all the buffers, do a simulation step, and then call unity drawindirect https://github.com/mkrebser/GPUInstance/blob/master/Assets/Resources/GPUInstance/scripts/instancemesh.cs#L1674
Here is unity execution order: https://docs.unity3d.com/460/Documentation/Manual/ExecutionOrder.html
Hello again! I've noticed that when an instance's position is appended, it only visually applies a frame late, at least when compared with a transform. Is there a way to circumvent this? I typically wouldn't mind an issue this minor, but I'm attempting to use this instance as a player view model, making the delay quite noticeable to players when moving.
Thanks in advance, Max