My Next Addon
http://i.imgur.com/Gv339aQ.png
Wolfenstein 3-D The screenshot itself is from a raycaster test I did a ways back - nice enough performance, but the original Wolf source code had a lot of assembly in it - something I know nothing of. But then, the other day - I noticed that they released the "source" to their javascript browser port (probably a while ago I guess, no HTML5 in sight). Now, that is something I can work with. :D Amusing thing is, their "draw" for that port, is all DoM based - easily replicable with Frames and Textures, with probably a lot better performance. |
How can you transform textures like that?
|
By drawing a separate texture for every horizontal line at different scales you can create perspective, I used the same technique to show what path oregorger was going to take in an addon for my guild.
|
You could use trapezoid-shaped texcoords to do the same thing. That would use one texture for Semlar's example instead of anywhere between a few dozen to hundreds depending on the size of the output.
Code:
texture:SetTexCoord(ULx,ULy,LLx,LLy,URx,URy,LRx,LRy) This is the function we had to use to rotate textures before they gave us texture:SetRotation() and the animation system. Edit: Nevermind. Although it would work good in theory, the graphics engine doesn't quite support this. |
Quote:
In the case of multiple textures per vertical line (i.e. Doom), you'd have to have a separate line for each wall/ceiling/floor texture. |
Quote:
I'll probably go over it again, once the porting is complete. |
Quote:
You can see why from this post - http://wowinterface.com/forums/showp...73&postcount=2 |
I forgot I came across that before a while ago. I did a bunch of testing following up my previous post and it's because of how the game engine draws textures. The game draws them internally as 2 triangles positioned top-left and bottom-right. Each triangle uses 3 points from the texcoords to render the image.
I'll just bring this image back from the other post... In this example, the bottom 2 texcoord points were widened past the bounds of the image. The bottom-right triangle stretched properly while the top-left one merely skewed the image. I'm assuming if the top points were widened instead, the situation would be reversed. |
Quote:
|
Quote:
|
Quote:
Quote:
|
Quote:
|
Most of my stuff is non-published. Mostly because I keep starting projects and never finish them. :p
|
Quote:
|
Other than the front end (titles, menus) the UI layout is done, including all the in-game visuals, shy of the actual raycasting/sprites. Now I can start on the main porting.
http://i.imgur.com/pW7MmvR.jpg |
Quote:
|
Quote:
|
Quote:
I think 10leej has the impression that I'm drawing on the game world like AVR, and that's completely unrelated. |
Quote:
|
Quote:
|
All times are GMT -6. The time now is 05:09 AM. |
vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI