- Home /
Efficient way to keep a fixed rotation for sprite?
I'm faking some visual effects, and i have a large number of sprites (a quad with a texture) that need to be aligned in a constant rotation relative to the screen. They're parented to another object that rotates, so I need to negate the rotation that they inherit from the parent.
Currently I do this by
void Update () { transform.rotation = Quaternion.identity; }
Haven't really experienced any performance issue from having lots of these objects with that script on them, but I'm thinking there ought to be a better way to go at it than letting the CPU negate the rotation in each frame.
For example, could I somehow instruct the shader to ignore that the uv's are being rotated and just use a static rotation all the time? Or are there objects (particles maybe, don't know alot about those...) that behave this way natively, i.e. have a constant rotation relative to the screen?
Thanks