Thread: integratating glut in a mdi GUI

  1. #1
    Registered User
    Join Date
    Nov 2001
    Posts
    54

    integratating glut in a mdi GUI

    heres the scenario,

    i have a GUI with a standard WinMain function

    and a glut file with a main function

    what would be the best way to call the glut file from the GUI if at all it is possible

    for source code see my previous post

    thanx in advance

    korbitz

  2. #2
    Banned
    Join Date
    Jan 2003
    Posts
    1,708
    I don't believe you can call glut's main the way you are thinking. This is like having two entry points to a program, and I don't think you can do that.

    Rather, in order to achieve what I think you want to do, you need to generate a child window to render to, OR just setup your windows api window to render to . I looked at the code, and there's a lot of win32 stuff I don't understand, subsequently I can only give you a broad overview.

  3. #3
    Registered User VirtualAce's Avatar
    Join Date
    Aug 2001
    Posts
    9,607
    Just call main() but I wouldn't use the name main in your code. WinMain is effectively the new main for your program. It replaces the old DOS main(). Call it mainloop() or something else. Simply calling it from your GUI should work.

  4. #4
    Registered User
    Join Date
    Nov 2001
    Posts
    54
    sorry bout the delay in replying to this, but been busy

    okay, you mention calling mainLoop() or something like that but what parameters need to be passed into glutInit as it takes the parameters from main()

    i have tried replacing them with (0,0) with no success

    any help will be appreciated

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Inserting text into MDI program
    By Rutabega in forum Windows Programming
    Replies: 0
    Last Post: 12-23-2005, 11:25 AM
  2. calling an external program from within a windows GUI
    By korbitz in forum Game Programming
    Replies: 1
    Last Post: 03-16-2004, 10:39 PM
  3. .NET And GUI Programming :: C++
    By kuphryn in forum C++ Programming
    Replies: 4
    Last Post: 01-27-2002, 04:22 PM
  4. GUI Programming :: C++ Exclusive
    By kuphryn in forum C++ Programming
    Replies: 5
    Last Post: 01-25-2002, 03:22 PM
  5. C++: Reference Book, GUI, Networking & Beyond
    By kuphryn in forum C++ Programming
    Replies: 4
    Last Post: 11-10-2001, 08:03 PM