Jump to content

  • Log In with Google      Sign In   
  • Create Account

Interested in a FREE copy of HTML5 game maker Construct 2?

We'll be giving away three Personal Edition licences in next Tuesday's GDNet Direct email newsletter!

Sign up from the right-hand sidebar on our homepage and read Tuesday's newsletter for details!


We're also offering banner ads on our site from just $5! 1. Details HERE. 2. GDNet+ Subscriptions HERE. 3. Ad upload HERE.


#Actualgchewood

Posted 26 January 2013 - 01:34 PM

Sorry, I should've been clearer in explaining that all of the models would be visible at once. I was thinking about grass billboards at the time.
Hardware instancing would probably be the best solution, now I think of it. It's just easier for level-editing if you can group them into bunches of
50 (for example) billboards along a flat plane and then copy and paste to cover the map. I know it's probably better to do grass procedurally,
so I might consider that instead.

Efficient rendering is a higher-level process and very involved. You need to keep updated AABB’s for each object and use them for frustum culling, which can be further improved via an oct-tree.

Once you have a list of things you want to draw you need to sort them by shader, texture, and possibly depth in order to reduce the number of redundant state changes.

Then render them in sorted order. Of course that does no good if you don’t also have a system in place for eliminating redundant state changes. That is if the same shader is set twice in a row, the second time should be a do-nothing call.


Yeah I realised the majority of my work is ahead of me. Was just focusing on this specific problem first.

Thanks for the info people.

#2gchewood

Posted 26 January 2013 - 01:34 PM

Sorry, I should've been clearer in explaining that all of the models would be visible at once. I was thinking about grass billboards at the time.
Hardware instancing would probably be the best solution, now I think of it. It's just easier for level-editing if you can group them into bunches of
50 (for example) billboards along a flat plane and then copy and paste to cover the map. I know it's probably better to do grass procedurally,
so I might consider that instead.

Efficient rendering is a higher-level process and very involved. You need to keep updated AABB’s for each object and use them for frustum culling, which can be further improved via an oct-tree.

Once you have a list of things you want to draw you need to sort them by shader, texture, and possibly depth in order to reduce the number of redundant state changes.

Then render them in sorted order. Of course that does no good if you don’t also have a system in place for eliminating redundant state changes. That is if the same shader is set twice in a row, the second time should be a do-nothing call.


Yeah I realised the majority of my work is ahead of me. Was just focusing on this specific problem first.

Thanks for the info people.

#1gchewood

Posted 26 January 2013 - 01:26 PM

Sorry, I should've been clearer in explaining that all of the models would be visible at once. I was thinking about grass billboards at the time.

Hardware instancing would probably be the best solution, now I think of it. It's just easier for level-editing if you can group them into bunches of

50 (for example) billboards along a flat plane and then copy and paste to cover the map. I know it's probably better to do grass procedurally,

so I might consider that instead.

 

Thanks for the info people.


PARTNERS