Release notes

Changelog

Version 1.25.1.2


Released 04 Mar 2022
FeatureSupport for Binary WebSockets in the Network panel in the inspector
FeatureSupport MQTT over WebSockets
FeatureBinary messages support for WebSockets
FeatureIntroduced support for anti-aliased clipping
FeatureUnreal EngineAdded option that enables the loading of UTextures instead of raw images if they exist inside an Atlas or can be located on disk
EnhancementExposed V8 Tracing events on Xbox, which show where V8 is spending time when executing JavaScript code
EnhancementIntroduced new member in Compositor’s DrawInfo structure to show which view owns the composition which has to be drawn
EnhancementReduced various internal classes memory footprint
EnhancementCache attributes NamedNodesMap instead of allocating a new one on each query for better performance and memory
EnhancementOptimized redrawing areas size and frequency
EnhancementReduced the HTMLParser memory usage
EnhancementOptimized the transitions performance to be not affected by using transition: all
EnhancementAdded support for render passes in the DirectX12 backend
FixFixed a crash when GC happens inside MutationObserver notification
FixFixed premature removal of data-bind nodes from the evaluation graph when they have mutators
FixFixed Player app gamepad swapped buttons 8 and 9
FixFixed possible graphics artifact (color bleeding) when using a SVG as repeated background image
FixFixed positioning of SVG elements when using the WAAPI
FixFixed the class, style and id attributes to be able to be empty
FixAdded missing mutation records when classes are changed through classList
FixHandle possible assertion for a degenerate triangle when handling glyphs that contain cubic curves
FixFix SVG clipping for background SVGs with viewBox attribute that has non-zero position
FixFixed mutation observers being garbage collected too early
FixFixed resized images being minified when drawing them onto CanvasRenderingContext2D
FixFixed possible null access crash in DrawShadowShape
FixFixed suffix attribute selector
FixFixed flex absolute children size calculation not respecting the direct parent
FixCalculate transform origin based on snapped to pixel size box
FixFixed ArrayBuffer type on JSC VM
FixAllow cohtml.js to be included multiple times without side effects
FixFixed a rare crash when profiling performance via the inspector
FixFixed stale stacking contexts which in certain cases improves memory consumption
FixFixed an assert failure when using the compositor feature in Debug configuration
FixFixed rare cases where elements would be missing their visual style during rendering leading to assert failures and crashes
FixFixed wrong AABB debug visualization when using ShowElementAABBs feature
FixFix disappearing pseudo elements
FixFixed URL parsing for URLs that contain backslashes
FixTransitionend events are no longer fired when an element with a transition is shown
FixTransition property changes now correctly take effect when the active transition ends
FixFix incorrect display of preloaded images using non-premultiplied alpha
FixUnreal EngineFixed Video sample crash on Switch by disabling the Procedural sounds
APIModified the User fonts API so it takes the Ascent/Descent of a font instead of just the baseline
APIIntroduced new field in the RenderCaps structure of the backends – EndingRenderPassRequiresStateUpdate

Migration guide

Anti-aliased clipping

Version 1.25 of Prysm introduces anti-aliased clipping (for more details see Anti-Aliased Clipping. This has required some changes to the rendering.

  • All backends now support 5 texture slots instead of 4.
  • The PerPrimitivePS constant buffer now has a new int field ShouldClip.
  • There is a new pixel shader – CohClipMaskPS.hlsl
  • There are a few new pixel shader types (renoir::PixelShaderTypes). renoir::PixelShaderTypes::PST_ClippingRect – used for drawing a clip rectangle, renoir::PixelShaderTypes::PST_ClippingCircle – used to drawing clip circle, renoir::PixelShaderTypes::PST_ClippingTexture – used for drawing clip image, and renoir::PixelShaderTypes::PST_ClippingPath – used to draw a clip-path. The handling of these shader types is in the new CohClipMaskPS.hlsl pixel shader.
  • There are a few new shader types that all backends are being able to handle – renoir::ShaderType::ST_Clipping, renoir::ShaderType::ST_ClippingRect, renoir::ShaderType::ST_ClippingCircle, renoir::ShaderType::ST_ClippingTexture, and renoir::ShaderType::ST_Clipping::ST_ClippingPath. The handling of these shader types can be seen in the renoir::Dx11Backend backend.

Enhancement of user fonts API

Previously, the cohtml::UserFontDescription structure contained a Baseline field, which divided the line height into 2 parts. In version 1.25 this field is removed in favor of adding 2 different ones - Ascent and Descent, which are produced by most font authoring tools and provide greater control for the glyph positioning. The Ascent is the part above the baseline and the Descent is the part below. These 2 values may not sum up to the LineHeight - the excess height is the line gap, which is used internally for proper positioning.

The samples and documentation are updated to reflect this change.

  • If the tool you’re using for generating user fonts outputs the Ascent and Descent, you can directly use them (ascent is positive and descent is negative).
  • If you don’t have those values readily available, you can do an approximation that assumes no line gap using the Baseline value:
    • Ascent = Baseline
    • Descent = Baseline - LineHeight

Compositor API Enhancement

Version 1.25 of Prysm introduces enhancement of the usage of Compositor (see Compositor.

  • unsigned ViewId is added to the renoir::ISublayerCompositor::DrawData structure. With this change, you can have the same composition IDs in different views.
  • Likewise, unsigned viewId is added as a parameter to OnCompositionRemoved callback to identify the actual composition for removal

New rendering backend capability

  • There is a new field in the renoir::RendererCaps structure - EndingRenderPassRequiresStateUpdate. The field indicates whether the GPU state should rebound after a render pass has been ended. This is a requirement for some graphics APIs (e.g. Metal) where the driver requires you to update the GPU pipeline state every time after the end of a render pass. The EndingRenderPassRequiresStateUpdate has been added in order not to burden the backend themselves to cache the GPU state and rebind it again after a render pass ends.