Rick Posted April 1, 2013 Share Posted April 1, 2013 I don't need this now, but was thinking about it when I was doing my GUI in 3D (textures on planes/boxes always facing the camera). When these need to be centered it works great across multiple resolutions and aspect ratios, but when you need them to be on the edges of the screen, does anyone know of a way to do that? Remember this is in 3D not 2D and wide screens show more of the 3D scene on the edges than non wide screen resolutions. Quote Link to comment Share on other sites More sharing options...
MCP Posted April 1, 2013 Share Posted April 1, 2013 Unproject() could be useful there. Unproject(0,y) for left screen edge and Unproject(screenWidth-1,y) for right edge etc. Position your quads accordingly. Quote "If our brains were simple enough for us to understand them, we'd be so simple that we couldn't." - Ian Stewart 1995. Link to comment Share on other sites More sharing options...
Rick Posted April 1, 2013 Author Share Posted April 1, 2013 I was thinking the depth would be an issue, but seems you can provide the z value of the screen space param for the depth and it would figure it out. Nice. Thanks. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.