Upright display in ogre renderer - possible?

Forum for general chit-chat or off-topic discussion.

Moderators: CEGUI MVP, CEGUI Team

User avatar
mba
Not too shy to talk
Not too shy to talk
Posts: 41
Joined: Tue Oct 11, 2005 11:54
Location: Denmark

Upright display in ogre renderer - possible?

Postby mba » Wed Feb 22, 2006 11:46

Hi all!

I'm currently working on a project developing an Ogre application with the CEGUI system. I have posted this question on the ogre forum, and they have forwarded me to this forum as it was more a cegui type of question, hope this doesn't count as crossposting :-)..

The application im developing is for a project where it would be needed to have a standard 4:3 or 16:9 lcd flatpanel placed in an upright position, rotated 90 degrees clockwise. I'm working on a linux box, and it is possible to force for example the nvidia device driver to rotate the display, but to my knowledge this would disable any hardware acceleration.
The graphical content of the rendered ogre scene can of course be manually rotated, this is probably the best solution, we would then be independent of the capabilities of the used graphics card, but the problem is rotating the contents of the gui, is there any way to achieve this? It would probably be a change to the CEGUIOgreRenderer but where? If anybody has some ideas, input or other information it would be very much appreciated.

Kind regards
Martin

User avatar
Genva
Just popping in
Just popping in
Posts: 4
Joined: Sat Feb 05, 2005 05:40

Postby Genva » Thu Feb 23, 2006 15:49

Tweaking OgreCEGUIRenderer a bit you can achieve that:
    1. Swap width and height in OgreCEGUIRenderer::setDisplaySize and OgreCEGUIRenderer::constructor_impl.
    2. Swap x and y of d_texelOffset in OgreCEGUIRenderer::constructor_impl.
    3. Use matrix that rotate about Z axis 90 degree when _setViewMatrix in OgreCEGUIRenderer::initRenderStates.

Other similar stuff maybe missing in above list, but thought you can sort it out.

User avatar
mba
Not too shy to talk
Not too shy to talk
Posts: 41
Joined: Tue Oct 11, 2005 11:54
Location: Denmark

Postby mba » Thu Feb 23, 2006 18:52

Thanks a bundle Genva,

this will truely be helpful and hopefully be one of the last hurdles I have to overcome. I will try your directions and see if I can solve it.


Kind regards
Martin


Return to “Offtopic Discussion”

Who is online

Users browsing this forum: No registered users and 12 guests