-
Type:
Bug
-
Resolution: Unresolved
-
Priority:
P4
-
Affects Version/s: internal
-
Component/s: javafx
-
generic
-
windows
D3D12 backend initializes the SwapChain using CreateSwapChainForHwnd() function. This turns out to be an incorrect pick when we want to support UNIFIED Stage style - transparency is not properly applied then.
Thanks to [~mfox] research we know we have to switch to using CreateSwapChainForComposition() in order to enable transparency. There must be some extra work done to properly support this:
- Composition uses additional objects - CompositionDevice, CompositionTarget and CompositionVisual. CompositionDevice probably should be kept with the D3D12 Device, while Visual/Target should be kept with the SwapChain.
- There might be issues when resizing the SwapChain - unnecessary elements must be properly freed (ie. after GPU uses them - integrate with ResourceDisposer?)
- Glass must be very slightly updated by providing WS_EX_NOREDIRECTIONBITMAP flag to HWND to remove the default surface.
Worth to also check if performance changes in any way after these additions.
Thanks to [~mfox] research we know we have to switch to using CreateSwapChainForComposition() in order to enable transparency. There must be some extra work done to properly support this:
- Composition uses additional objects - CompositionDevice, CompositionTarget and CompositionVisual. CompositionDevice probably should be kept with the D3D12 Device, while Visual/Target should be kept with the SwapChain.
- There might be issues when resizing the SwapChain - unnecessary elements must be properly freed (ie. after GPU uses them - integrate with ResourceDisposer?)
- Glass must be very slightly updated by providing WS_EX_NOREDIRECTIONBITMAP flag to HWND to remove the default surface.
Worth to also check if performance changes in any way after these additions.