Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Results 1 to 3 of 3

Thread: OpenGL splitter windows

  1. #1
    Junior Member Newbie
    Join Date
    May 2001
    Posts
    21

    OpenGL splitter windows

    Do I need one unique class for each splitter window?

    I'm programming OpenGL MFC and my COpenGL class is directly descended from CView. As I dynamically create static splitter windows, I wonder if I can use the same class on all splitter windows, or do I have to derive different classes from COpenGL?

    anybody?

  2. #2
    Junior Member Newbie
    Join Date
    Nov 2000
    Posts
    12

    Re: OpenGL splitter windows

    It's probably best to create a class for each splitter window so you don't have to keep track of the different options for each view separately. I'm not sure what you're trying to do, but lets say you want to do a 4-way splitter with 4 views (front, top, side and 3D). Create a CView derived class (CGLView) to handle the base OpenGL stuff (like setting up the device context and handling the WM_ERASEBKGND message) then create 4 new classes from CGLView for each of your views. In these classes you can specify the camera angle through a gluLookAt command or glRotate commands. Use these classes in each of the splitter windows in your OnCreateClient method.

    Hope that helps.

    liB

  3. #3
    Junior Member Newbie
    Join Date
    May 2001
    Posts
    21

    Re: OpenGL splitter windows

    thanx!

Posting Permissions

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