Results 1 to 2 of 2

Thread: how to resize FBO???

  1. #1
    Junior Member
    Join Date
    Jan 2013
    Posts
    1

    how to resize FBO???

    The FBO is used in my Mobile 3D viewer.(iPhone)
    The base of this application is from the book 'iPhone 3D Programming Developing Graphical Applications with OpenGL ES'.

    The anti-aliasing is also implemented as the book introduced.(Super Sampling)

    These day, I'm trying to apply it to iPad.

    Then,....how can I resize the FBO for horizontal display?(Landscape mode)
    At first, I tried a tricky way to rotate camera as +-90deg. :P

    but, it is just tricky and has many limitations to use UI that is automatically rotated.

    Remove all FBO, and then remake all of them horizontally again?

    Any comments would be helpful for me.
    Thank you.

  2. #2
    Member
    Join Date
    Jun 2012
    Location
    Texas
    Posts
    61

    Re: how to resize FBO???

    I think the best solution is to allocate your FBOs for a worst case size that accommodates both landscape and portrait orientations. Then, rather than resizing them to change between orientations, simply change the set of texture coordinates that you use with the textures that are attached to the FBOs. The area specified by the texture coordinates should be reduced so that the excess area of the textures is ignored when rendering frames. This approach does waste some memory, but will be much faster than deleting and recreating the FBOs and textures.

    Regards, Clay

Similar Threads

  1. problem refreshing resize
    By srobles in forum OpenGL ES general technical discussions
    Replies: 7
    Last Post: 06-03-2008, 06:09 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •