diff options
author | Sven Gothel <[email protected]> | 2011-09-04 10:51:16 +0200 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2011-09-04 10:51:16 +0200 |
commit | c8e147620c55ff16e9d687bb36a4374e97e82176 (patch) | |
tree | 3151189f2750801baf6ae1918adc3ff17b9c6833 /src/nativewindow/native/windows/WindowsDWM.h | |
parent | 3ea949b6a14c1ba631cb41b7439af86b21db4c05 (diff) |
Complete translucency support for Win32 - tested w/ NEWT
https://jogamp.org/bugzilla/show_bug.cgi?id=517
- Adding some Windows DWM entries to GDI (manual) for translucency support
- Add translucency setting in WindowsWGLGraphicsConfiguration*
Diffstat (limited to 'src/nativewindow/native/windows/WindowsDWM.h')
-rw-r--r-- | src/nativewindow/native/windows/WindowsDWM.h | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/src/nativewindow/native/windows/WindowsDWM.h b/src/nativewindow/native/windows/WindowsDWM.h new file mode 100644 index 000000000..742db1628 --- /dev/null +++ b/src/nativewindow/native/windows/WindowsDWM.h @@ -0,0 +1,40 @@ +#ifndef _WINDOWS_DWM_H_ +#define _WINDOWS_DWM_H_ + + #include <windows.h> + + #define DWM_BB_ENABLE 0x00000001 // fEnable has been specified + #define DWM_EC_DISABLECOMPOSITION 0 + #define DWM_EC_ENABLECOMPOSITION 1 + + typedef struct _DWM_BLURBEHIND + { + DWORD dwFlags; + BOOL fEnable; + HRGN hRgnBlur; + BOOL fTransitionOnMaximized; + } DWM_BLURBEHIND, *PDWM_BLURBEHIND; + + typedef struct _MARGINS + { + int cxLeftWidth; // width of left border that retains its size + int cxRightWidth; // width of right border that retains its size + int cyTopHeight; // height of top border that retains its size + int cyBottomHeight; // height of bottom border that retains its size + } MARGINS, *PMARGINS; + + BOOL DwmIsExtensionAvailable(); + BOOL DwmIsCompositionEnabled(); + BOOL DwmEnableComposition( UINT uCompositionAction ); + BOOL DwmEnableBlurBehindWindow(HWND hwnd, const DWM_BLURBEHIND* pBlurBehind); + BOOL DwmExtendFrameIntoClientArea(HWND hwnd, const MARGINS *pMarInset); + + /* + DWM_BLURBEHIND bb = {0}; + bb.dwFlags = DWM_BB_ENABLE; + bb.fEnable = true; + bb.hRgnBlur = NULL; + DwmEnableBlurBehindWindow(hWnd, &bb); + */ + +#endif /* _WINDOWS_DWM_H_ */ |