[No] Move texture alignment from rendering to elsewhere

Moderator: GZDoom Developers

Move texture alignment from rendering to elsewhere

Postby RockstarRaccoon » Wed Jun 27, 2018 1:11 pm

This is less of a request in more of a notice of intent. While looking through the rendering process, I've noticed that it does texture alignment for every line on the fly, every frame. This amounts to about 6 extra calculations per line per frame, and would probably be better handled only when it is set or modified, such as windy map is loaded or an attached sector is moved. I would like to write a version of the code which does this instead, while I write the code for my new texture alignment options.

Would there be any problem with that? Am I fully understanding the situation?


Edit: to clarify, this is something I'd like to look into because I'm already planning on screwing with it to implement the feature request I made for "more robust pegging options", which was, in turn, a consolidation of my long-standing requests for pegging a texture to the floor and pegging to the 0 on the map height. If this is something that should be done, it'd be best to do it before completing the code for those so there will be less code to move around.
User avatar
RockstarRaccoon
Totally Babies
 
Joined: 31 Jul 2016

Re: Move texture alignment from rendering to elsewhere

Postby Graf Zahl » Wed Jun 27, 2018 2:13 pm

It's not that simple. Offloading this stuff can cost more than these 6 calculations due to cache misses, and will require checks elsewhere to check for animations.
Ultimately optimizing this is pointless.

The goal should be, once Vulkan is working, to pre-generate command buffers for larger structures in the level to avoid recalculating this stuff entirely.
User avatar
Graf Zahl
Lead GZDoom Developer
 
Joined: 19 Jul 2003
Location: Germany

Re: Move texture alignment from rendering to elsewhere

Postby RockstarRaccoon » Wed Jun 27, 2018 11:10 pm

Alright then, I'll just worry about the alignment stuff then.
User avatar
RockstarRaccoon
Totally Babies
 
Joined: 31 Jul 2016


Return to Closed Feature Suggestions

Who is online

Users browsing this forum: No registered users and 2 guests