Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

SnuuT

OpenGL render in child (winapi&opengl)

This topic is 5805 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

how you read in the topic i want to render in a child window. but it doesn't work like i want. i call glClear, and after this, the window should be black, shouldn't it? but in my case, the window isn't black at all, there is also a region that has the default backgroundcolor, like the other windows. it seems like this region of the window isn't cleared (?). here's a screen, maybe you now know better what i tried to explain. http://www.cevi-buchsi.ch/screen.jpg source: http://www.cevi-buchsi.ch/main.cpp thx 4 help & sry 4 my english [edited by - SnuuT on August 26, 2002 6:55:56 AM]

Share this post


Link to post
Share on other sites
Advertisement
1. Your desktop colors are really ugly
2. Are you sure you use the right DC in wglCreateContext? It should be that of the child, the same goes for SetPixelFormat, wglMakeCurrent etc...
3. Are you using GL_SCISSOR_TEST ? Scissor affects glClear.

Share this post


Link to post
Share on other sites
so...i solved it with glScissor. it works, but now, i wan''t to know what i''ve to do that in the top left corner of the scissor has the coordinates (0, 0) and the bottom right corner has the coordinates (800, 600). with glViewport i didn''t get it running like i wan''t, is there any other possibility ?

btw: why''s my windows'' bgcolor green? i know it''s cause of glScissor but why is it? actually i don''t care, so it doesn''t matter...

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!