hi,
what are you experience with animated objects? I have 3 Characters with 700 triangles on screen and the framerate drops to 20 fps.
hi,
what are you experience with animated objects? I have 3 Characters with 700 triangles on screen and the framerate drops to 20 fps.
if you have many bounds or different materials on your skinned models, this sounds reasonable
I have a character with 880 polygons with one material and I still get 30 FPS.
Of course, there isn’t much else in the scene at the moment so the number of draws calls is pretty low.
Please also keep in mind both your poly counts and your processor load. Having three animated characters induces a heavier processor load and may be a part of the recipe here.
if i instead will use only planes with uv animations does it will increase performance
Yeah, seriously actually.
Thats why monkey ball works with this setup for example.
Also UV animations allow you to have any graphical style as the whole “rendering” happens outside of unity where you can do anything, including fullscale toon
I am considering using billboard sprites (imposters) to replace my 3D model when they are not close to the camera. It would be faster and I doubt it will look that different.
animated sprites ?
Yes, I would use animated sprites when the character is far from the camera then swap to a 3D once it comes close enough to worry about rendering detail.
I’m using a animated skinned model with 880 polygons so it wouldn’t take too many off those on screen at once to pull the frame rate down below acceptable levels.
I’ve found animated billboards to be pretty expensive too. It might not be worth the trouble.
why? its only a plane with a 256x256 compressed (“moving”) texture. Why it should be expensive?
It becomes expensive if you use 20 billboards → 20 drawcalls
what you need to do is write an own single mesh system or missuse the particle system and single particle scripting to ensure that only a single mesh is used for the billboards, then it will run much better.
Ooooh… neat idea!
Ah! That’s a useful idea.
That’s actually what I’m working on right now - creating my own “sprite manager” that works much like the particle system. It should allow tons of billboards (acting as sprites) to all fall under a single draw call, yet allow them to move independently, just as in the particle system. But unlike the particle system, it will allow you to scale the quads any way you like and modify their UV coords to achieve UV animation.
I’d like that to handle a distant crowd of characters. How would you do collisions with the ground? You wouldn’t want to use a collider for each one, would you?
No you wouldn’t
I think the simplest here is just using a very short vertical ray cast towards the bottom. As you know that they have been on ground the update before, they can’t have gotten far away from ground.
Thats at least what I would attempt, as line → triangle collision is the least performance hungry thing and with a short raycast length (never checked if unity gives you this possibility … ) the check itself also isn’t very costly commonly
if i use uv animation, the problem is when i have 3 different animations for my character i need 3 different textures, right? or can i put 3 different animations in one texture for uv animations?
If they all fit onto the same texture, sure why not.
You just have to write a small animation system which lets you specify start frame, end frame and the direction (moving into + frame range or - frame range) of the animation and likely the frames per second