Preview: MewUI v0.16.0 Release Notes #138
Closed
al6uiz
announced in
Announcements
Replies: 4 comments 1 reply
This comment has been hidden.
This comment has been hidden.
This comment has been hidden.
This comment has been hidden.
-
Beta Was this translation helpful? Give feedback.
0 replies
-
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment


Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
This will be the first MewUI release in about a month, and it includes a larger set of changes than usual.
The main focus of this release is the new GPU-accelerated rendering and interop foundation, which enables the new SVG renderer, Skia integration(as library), and video playback sample.
This preview is intended to share the upcoming changes before the final release.
What's Changed
This release introduces a new GPU-accelerated rendering and interop foundation for MewUI.
It replaces the previous offscreen render-target abstraction with the new
IRenderSurface/IRenderDevicemodel, adds external GPU/raster interop paths, and introduces a GPU-accelerated image filter graph.The most visible results of this work are the new
MewUI.Svglibrary,MewUI.Skiaintegration, and the FFmpeg-based video playback sample.On top of that foundation, this release adds several user-facing features, including the
ColorPickercontrol and a live hierarchical performance profiler.It also includes major backend improvements such as asynchronous OpenGL PBO uploads, Win32 transparent windows backed by DirectComposition, a shared D3D11 device across Direct2D consumers, and a 1:1 BitBlt fast path for external GDI DIBs.
Because the release contains breaking changes across backend interfaces and the platform-surface namespace, custom backends,
WriteableBitmapControl, and code that uses platform-surface interfaces will need to be migrated.Rendering abstraction
IBitmapRenderTargetremoved — Offscreen render targets are replaced by the newIRenderSurface. Surface creation now flows throughRenderSurfaceDescriptor(pixel format / size / DPI / usage intent / lifetime hint) and a capability-interface model.IGraphicsFactory.CreateBitmapRenderTarget(...)removed —IGraphicsFactorynow extends the newIRenderDevice; callers create surfaces viaCreateSurface(RenderSurfaceDescriptor).IGraphicsFactory.CreateImageFromPixelSource(...)renamed toCreateImageView(IPixelBufferSource).Window.RenderFrameToSurfacesignature changed —IBitmapRenderTarget→IRenderSurface.Direct2DBitmapRenderTarget/GdiBitmapRenderTarget/OpenGLBitmapRenderTarget/MewVGMetalBitmapRenderTargetremoved — replaced by each backend's*PixelRenderSurfaceimplementation.Backend / platform
GraphicsBackendenum removed — backend identification moved from an enum to astringname (Backendproperty). The backend name matches the<Name>portion of the package nameMewUI.Backend.<Name>("Direct2D","Gdi","MewVG.Win32","MewVG.X11","MewVG.MacOS"). Code that branched on the enum must switch to string comparison.Platform/Surfaces/I*interface files moved toShared/Platform/{Win32,MacOS,Linux/X11}/—IWin32WindowSurface,IWin32TransparencyCapabilities,IMacOSWindowSurface,IX11GlxWindowSurface, etc. relocated to platform folders. Namespaces (Aprillz.MewUI.Platform.{Win32,MacOS,Linux.X11}) are unchanged, so ordinary consumer code is unaffected; only custom csproj files that include these paths via explicit<Compile Include>need their paths updated.IWindowSurfaceSelectorandIWin32LayeredWindowSurfaceremoved — no longer referenced; equivalent roles are exposed via backend capability interfaces.Resources / controls
IExternalLockedTexturereplaced byIRasterSource— the external texture interop contract moved from a lock-based model to a raster-source model. Adapters such asExternalSampleSourceandExternalLockedTextureSampleSourceare consolidated intoExternalRasterSource.IPixelBufferSourcegainsHasAlphaandLockModemembers — default implementations are provided, so most code is unaffected; explicit implementors may see compiler warnings.WriteableBitmapControlremoved — for simple display, assign aWriteableBitmapdirectly toImage.Source(WriteableBitmapimplementsIImageSource); for pixel drawing combined with interaction, wrap it withIGraphicsFactory.CreateImageViewto obtain anIImageand callDrawImagefromFrameworkElement.OnRender. ExistingOnRenderPixels/LockForWrite/UseBitmapGraphicsContextcallers must migrate.Added
Libraries / samples
MewUI.Svglibrary — SVG rendering that uses the GPU interop path to composite directly onto each backend's GPU surface.MewUI.Skialibrary — Skia integration over the GPU interop path. Composes Skia (SKCanvas) content zero-copy inside the MewUI control tree. Ships per-backend interop bridges for Direct2D, GDI, MewVG.Win32, MewVG.X11, and MewVG.MacOS.MewUI.Video.Sample, with NVDEC hardware-decode fallback. Decoder frames are displayed without a copy through the external GPU interop path.Rendering / backend
ImageFilternode graph evaluated throughIImageFilterContext/ScratchSurfacePool. Ships with a CPU reference executor and Direct2D / Metal / OpenGL GPU executors, plus a separable Gaussian blur as a built-in node.IRasterSource,ExternalRasterSource,ExternalGpuWriteScope,GpuInteropInvalidation, andGpuResourceAffinityexpose externally owned or GPU-resident textures asIImagewithout copy, and manage write scopes and invalidation for shared GPU resources. On Win32, D3D11 surfaces are shared into OpenGL contexts viaWGL_NV_DX_interop.D3D11RenderTargetDeviceProviderlets multiple D2D consumers (GPU surfaces, DXGI images, etc.) reuse a single D3D11 device, removing duplicate device creation and cross-context state churn.IImagewithout an intermediate copy, and matching source/destination rectangles take a directBitBltpath instead ofStretchBlt, improving both pixel accuracy and cost.IGraphicsContextextensions —SetClipPath(PathGeometry)andGetClipBoundsLocal().IImageBrush+TileMode— image / pattern fill brush (maps to SVGpatternandpatternTransform).PathGeometry.Transform(Matrix3x2)— bakes a transform matrix into the geometry so that a subsequentStrokepreserves element-DIP thickness.IGlyphOutlineFont— every font backend can extract glyph outlines asPathGeometry, with synthetic bold / italic support.HasAlphaflag on bitmap resources — skips GPU blending cost for sources that do not carry alpha.Platform
IWin32TransparencyCapabilitiesexposes which mode (layered HWND / DirectComposition / opaque) each backend supports. Includes DirectComposition native bindings such asDCompositionCreateDevice.Controls
HsvColorstruct.Grid.ShareStarSizeproperty — share star sizing across multiple Grids.NumericUpDown.IsIntegermode — integer-only input.Core
AffectsVisualStateattribute — declares that a dependency-property change should automatically trigger visual-state refresh.ISubtreeInvalidationHost— host for subtree-scoped layout invalidation.Text
Diagnostics
Ctrl+Shift+Pand the timeline window withCtrl+Alt+Shift+P.Improved
Rendering / backend
*PixelRenderSurface— Direct2D ships both a CPU-readable variant and a copy-free GPU (DXGI) variant. The GDI implementation is renamed toGdiPixelRenderSurface.WGL_NV_DX_interoplocking and texture lifecycle are stabilized under context-loss conditions, and the PBO fence pool retires more robustly under sustained pressure.presentsWithTransactionmanagement.MewUI.Backend.*csproj has been adjusted toProjectReferencethe matchingMewUI.Platform.*project, and duplicate-compiled shared types such asInlineArrays.csare now built in a single location.Text
Controls / layout
Shapestretch handling — bakes the stretch transform into the geometry so thatStrokeThicknessstays in element-DIP.ScrollViewer;TabItemcontent uses an independent ScrollViewer instead.Core / performance
CollectionPool,PathGeometrycaching,BorderGeometryextraction,stackallocfor dash patterns, in-place BGRA↔RGBA conversion, pre-parsed AccessKey, FormattedTextStore measurement-constraint caching, and more.MewObjectproperty storage and inheritance handling optimized.Fixed
Backend / platform
BadDrawableon X11 window destruction — GL resources are now released beforeXDestroyWindow.Controls / layout
Windowadorner cleanup, clipping, and transform handling stabilized.Text / resources
Full Changelog: v0.15.2...v0.16.0
Beta Was this translation helpful? Give feedback.
All reactions