Unity RenderQueue Transform/Translate Questions
Hello,
I’m using an ECS structure and am interested in trying to jobify some draw commands. This seems difficult however as procedural paths seem to be flushed to native memory in declarative order upon calling DrawPath.
So my 2nd thought was to use Transform/Translate on the renderer between draws. Using Jobs only for quickly moving/creating matrixes and then rendering only the transforms close to the camera using quick circle checks on the shapes.
One thing I found is that Renderer.Translate does not seem to behave as expected. The Y input actually translates on the X axis and vice versa.
Renderer.Transform seems to work there is simply no scaling.
So what I want to know now is what would the Rive team suggest? Should I jobify creating paths similar to the scratch buffer using some atomic command count and appending commands? If I know the shape of each Path ahead of time I could consistently do this and then flush a giant path all at once.
However this wouldn’t take into account draw order or paint details for each specific shape.
There is also the Add Sub Path function which seems like it could help with drawing a repetitive shape with different transforms. Though again, no scaling.
So I feel my best bet is to make a new command class thats jobified using a sorted list based on Z-order. Each transforming their own points/paints and then flushing through the list when done. Though I’d love to hear Rive’s recommendations on this.