Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. Visible Client Area question

Visible Client Area question

Scheduled Pinned Locked Moved C / C++ / MFC
questiongraphicsgame-dev
3 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    Steve The Plant
    wrote on last edited by
    #1

    Hi, How do I determine if the client area of my window has been totally covered up by other windows? In my OpenGl program, I still want to render when the user switches away to another program, but not when the rendering/client area is not visible. Thanks! Shawn

    T J 2 Replies Last reply
    0
    • S Steve The Plant

      Hi, How do I determine if the client area of my window has been totally covered up by other windows? In my OpenGl program, I still want to render when the user switches away to another program, but not when the rendering/client area is not visible. Thanks! Shawn

      T Offline
      T Offline
      Tomasz Sowinski
      wrote on last edited by
      #2

      I guess you could fire WM_PAINT with InvalidateRect/UpdateWindow and check the rectangle returned by GetClipBox. Or - you could sample coords in client area with WindowFromPoint :) Tomasz Sowinski -- http://www.shooltz.com

      *** Si fractum non sit, noli id reficere. ***

      1 Reply Last reply
      0
      • S Steve The Plant

        Hi, How do I determine if the client area of my window has been totally covered up by other windows? In my OpenGl program, I still want to render when the user switches away to another program, but not when the rendering/client area is not visible. Thanks! Shawn

        J Offline
        J Offline
        JT Anderson
        wrote on last edited by
        #3

        You might want to have a look at KB article Q75236. http://support.microsoft.com/default.aspx?scid=kb;en-us;Q75236 I have to admit to never having used OpenGL. Do you not do your rendering in response to WM_PAINT messages? 'Cause if your rendering is in response to WM_PAINT, you won't get any WM_PAINT messages if the window is totally obscured.

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups