2
\$\begingroup\$

Making a space strategy game focusing on commanding a large fleet, with 1000+ ships per side.(I'm new in XNA 3D...below is a test screenshot. The ships will be scaled down another 2-5 times) When a unit is too far away, it's not rendered anymore.(obviously...when people get killed, they die) are there any way (as fast as possible) to force XNA to render the model into a 1-pixel dot if it's too far/smaller than 1 pixel? (I'm thinking about dynamic scaling, but that will probably drag down the performance severely) Fuck Yeah!

\$\endgroup\$

2 Answers 2

5
\$\begingroup\$

Problem is two-fold:

  1. Determine how many pixels the model will take when rendered
  2. Replace model with a dot

Suggestions:

  1. Pick the cut-off distance by eye. So when the model is this big and this far - it should be replaced with a dot. I would make it a property of the ship.
  2. Render all models that are closer than their cutoff distance as usual. Do not render all models that are farther. Instead render dots (single pixels or sprites, whichever is simpler for you) in their places.
\$\endgroup\$
-1
\$\begingroup\$

Hmm interesting but I'm not sure if that's the strategy I'd use.. what about using distance as a determining factor or have you looked into or considered camera culling? Something like this article.

\$\endgroup\$
1
  • \$\begingroup\$ If you insert a link, then insert the main part of the content on it so you can avoid link rot \$\endgroup\$
    – Bálint
    Oct 6, 2016 at 6:57

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .