You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Problem/Bug]: WPF Webview2compositioncontrol load but doesnt render while WV2 works fine #5189
This bug is related to a plugin I am working on with a MVVM wpf UI I am developing for the Autodesk Building information modeling software Revit.
I am trying to use the webview2 compositioncontrol instead of webview2 to solve the airspace issue as documented inside #286
Within the same application and the same view, Webview 2 works as intended, but webview2compositioncontrol doesn't render. Right-clicking tells me the webpage is loaded and navigation is completed. I can inspect or even screenshot the webpage in my webview2compositioncontrol. My mouse recognizes the button on the webpage, but it doesn't render.
within revit 2025 and net8, I was getting the same error as #5163 but I resolved it by specifying the target platform to "net8.0-windows10.0.22000.0" and ensure NET8 SDK is 8.0.407. after that the same WV2composition control render bug as Revit 2024 and net48 still persist
it is also worth noting this example here functions on my machine https://github.com/MicrosoftEdge/WebView2Samples/tree/main/SampleApps/WebView2WpfCompositionControl
Thank you for looking at my issue
Importance
Moderate. My app's user experience is affected, but still usable.
Runtime Channel
Stable release (WebView2 Runtime)
Runtime Version
134.0.3124.93
SDK Version
1.0.3171-prerelease
Framework
WPF
Operating System
Windows 11
OS Version
10.0.22621 Build 22621
Repro steps
Please note the uploaded MRE cannot be debugged outside of the API context of Autodesk Revit. I was able to reproduce this bug on 3 different developer's machine, all with very similar if not identical system enviroment
download the repo
makesure you have the some version of Autodesk revit downloadedm Trial will do, I prefer 2024(net 48) and 2025(net 8) for debugging, this issue is reproducible in both
select the debug matching your revit version (debug R24 for revit 2024)
launch the "show modeless window" under the "RevitAddIn" tab in revit UI
I agree this is a real issue and is not machine-specific. There would be real business value for BIM tech developers if Microsoft can resolve this bug.
Update: Tried both explicit initialization and implicit initialization of the composition control via Environment.SetEnvironmentVariable("WEBVIEW2_USER_DATA_FOLDER", userDataFolder); didnt seem to make any difference.
I wonder, since composition control is rendered using GraphicsCaptureSession that is what went wrong and why I can't seem to find any exceptions in the initialization and navigation process, but I don't have any good means of checking that
Unfortunately Composition Control isn't ready for production as well. It also has HDR problems while rendering (overlighted on some pages, colors are vary on page content) while HwndHost is fine. Something like HDR screen's effect is applied to the browser's rendered content twice. It also slower while rendering on WPF.
Activity
KJSloan2 commentedon Apr 1, 2025
I agree this is a real issue and is not machine-specific. There would be real business value for BIM tech developers if Microsoft can resolve this bug.
ZMPeterZhang commentedon Apr 1, 2025
Update: Tried both explicit initialization and implicit initialization of the composition control via Environment.SetEnvironmentVariable("WEBVIEW2_USER_DATA_FOLDER", userDataFolder); didnt seem to make any difference.
I wonder, since composition control is rendered using GraphicsCaptureSession that is what went wrong and why I can't seem to find any exceptions in the initialization and navigation process, but I don't have any good means of checking that
acidmeat commentedon May 8, 2025
renderoption can't set to software
WebView2 library downgrade (#329)
aepot commentedon Jul 30, 2025
Unfortunately Composition Control isn't ready for production as well. It also has HDR problems while rendering (overlighted on some pages, colors are vary on page content) while HwndHost is fine. Something like HDR screen's effect is applied to the browser's rendered content twice. It also slower while rendering on WPF.
MingboPeng commentedon Aug 20, 2026
I am having the same issue with the latest 1.0.4129.50.