visual c++ - Using GDi drawing with both 32 & 64 bit applications -


can com 32 bit out of process server used gdi drawing on 64 bit process?

yes can. gdi object handles , window handles, it's guaranteed low 32-bits used in 64-bit mode, should safe pass these between 32-bit , 64-bit. of course, com server must out of process.

quoting this page

on 64-bit windows, out-of-process 32-bit com server can communicate 64-bit client, , out-of-process 64-bit com server can communicate 32-bit client. therefore, if have 32-bit dll not com-aware, can wrap in out-of-process com server , use com marshal calls , 64-bit process.

similarly, this page

64-bit versions of windows use 32-bit handles interoperability. when sharing handle between 32-bit , 64-bit applications, lower 32 bits significant, safe truncate handle (when passing 64-bit 32-bit) or sign-extend handle (when passing 32-bit 64-bit). handles can shared include handles user objects such windows (hwnd), handles gdi objects such pens , brushes (hbrush , hpen), , handles named objects such mutexes, semaphores, , file handles.


Comments

Popular posts from this blog

php - Wordpress website dashboard page or post editor content is not showing but front end data is showing properly -

javascript - Get parameter of GET request -

javascript - Twitter Bootstrap - how to add some more margin between tooltip popup and element -