Hi all, i remember sometime ago someone posted code to write on the screen display
(similar to the on screen display from tv card software etc.. typically green text, big font..)

I've searched the forum for it but can't seem to find it... if anyone has it (or a link/info etc)
would you be so kind as to post it?

cheers, and happy new year...
Posted on 2008-01-01 12:53:15 by evlncrn8
I don't know what you mean here by "display". However, for DOS, you can use DOS interrupts to achieve this goal. In Windows, you could use these Win32 APIs to write on a canvas:


      [*] GetDC() or GetWindowDC().
      [*] WriteText() to write on the handle of one of the above Win32 APIs
Posted on 2008-01-01 14:50:41 by XCHG
Are you talking about display overlays exactly (like the green-looking volume indicators) or just writing text to a specific window?
Posted on 2008-01-01 15:17:28 by SpooK
the green looking overlays... like on volume controls etc.. exactly
but not using a transparent window over the desktop etc..

so far, i managed to write to the display by getting the 'DISPLAY' dc
but the text never goes away until the desktop is f5'ed to refresh...
Posted on 2008-01-01 18:35:50 by evlncrn8
This reminds me of an old question - how to display avi and other movies directly on the desktop as 'wallpaper', and iirc, its possible to treat the desktop just like any other window - obtain a dc, as u said, but also to hook its redraw notifications.
Posted on 2008-01-02 00:19:37 by Homer

This reminds me of an old question - how to display avi and other movies directly on the desktop as 'wallpaper', and iirc, its possible to treat the desktop just like any other window - obtain a dc, as u said, but also to hook its redraw notifications.

Yup, you can obtain the DC, I had posted once how to do it - use Spy++ to see the tree of windows - a SysListView32 or something was the target. Also, players like BSPlayer can show videos on desktop(shortcut  key is 'D'). Also, videos can be viewed with ActiveDesktop enabled, but I guess you had to make a .html file for it.

It makes you bored of it after a few hours to 2 days, though. Unless it's some fractal/function-based drawings or a 3D galaxy randomly-generated renders. Still, it's interesting how even on Win2k this works flawlessly and beautifully with the anti-aliased icons/text of the ListView.
Posted on 2008-01-02 10:13:15 by Ultrano
directdraw overlay surfaces

its (probably) the only reason directdraw is still supported in DX10

video players continue to use this feature ("hardware overlays")
Posted on 2008-01-09 10:48:37 by Rockoon