Release notes
Changelog
Version 1.2.0.4
Released 09 Apr 2019
Feature | Added support for CSS transitions |
Feature | Added support for pointer-events CSS property |
Feature | Enhanced the flex CSS property to support setting grow and shrink |
Feature | Added support for CSS cursors |
Feature | Added support for the console tab and script debugging on Mac OS X |
Feature | Added support for mix-blend-mode: add |
Feature | Added support for KeyboardEvent.location |
Feature | Added support for copy and paste |
Feature | Added support for Home and End keys |
Feature | Added automatic sizing for text fields |
Feature | Added API to get the Nodes attributes from cohtml::INodeProxy |
Feature | Added text selection to all elements |
Enhancement | Refactored Renoir backend API to work better with low-level rendering APIs like Metal |
Enhancement | Replaced JavaScriptCore with ChakraCore on Xbox One and PlayStation 4 |
Enhancement | Replaced JavaScriptCore with V8 on Mac OS X |
Enhancement | The inspector no longer disconnects when the view is reloaded |
Enhancement | Significantly improved inspector loading speed for pages with lots of elements |
Enhancement | Data-binding attributes are visible in the inspector |
Enhancement | Reduced thread-local variables count to allow running on more Android devices |
Enhancement | Android uses the Android NDK r15b |
Enhancement | Added gestures support in Unity3D |
Enhancement | Added range requests support in Unity3D |
Enhancement | Added gamepad support to PlayStation4 samples |
Enhancement | Improved performance for drawing polylines in canvas |
Enhancement | Allowed loading stylesheets encoded in UTF-8 with BOM |
Enhancement | Moved V8 background tasks to worker threads tasks |
Enhancement | Added GPU debug metadata in Unreal Engine 4 |
Enhancement | Implemented animation shorthand CSS property |
Enhancement | Added custom HTMLMediaElement events signaling when a decoder cannot keep up (cohplaybackstalled) and when it catches up (cohplaybackresumed). These events can be used to synchronize other animations with the video playback. |
Enhancement | Seeking paused videos now shows a preview of the seeked position |
Enhancement | Added non-standard property to the CanvasRenderingContext2D “enableFastLineSegmentDrawing” which can allows much faster drawing in a canvas if the image consists of line segments only |
Fix | Fixed assert when calling bound C++ methods with incorrect arguments from JavaScript |
Fix | Fixed assert when removing the src attribute of an img and reloading the view |
Fix | Fixed using the skewX property in animations |
Fix | Fixed leaking some GPU resources on reloading the view |
Fix | Fixed calling the connectedCallback on custom elements in appendChild |
Fix | Fixed calling bound methods on objects that have been removed with View::DestroyExposedInstance |
Fix | Fixed using unsigned numbers for specifying a color in data-binding |
Fix | Fixed possible memory leak of ParseHTML when the system is destroyed before the load has finished. |
Fix | Fixed crash when using canvas stroke with gradient |
Fix | Fixed Inspector to show all transformations on an element with multiple transformations. |
Fix | Fixed currentTime attribute when the animation is paused |
Fix | Fixed onBlur, onFocus events on input elements when using React |
API | Changed Renoir API to allow simultaneous usage from Coherent GT and Gameface |
API | Split Renoir backend in UnrealEngine 4 to a separate module |
API | Added virtual destructors to pure virtual classes and structs |
API | Added default implementation to ViewListener’s methods |
API | Renamed Renoir library files to start with lib |
API | Moved enable color writes to the PSO instead of SetRenderTarget param. This is part of a breaking change in Renoir backends. For more information, see the migration guide |
API | Moved MSAA to the PSO. This is part of a breaking change in Renoir backends. For more information, see the migration guide |
API | Added upload buffer (constant buffers) management in Renoir. This is part of a breaking change in Renoir backends. For more information, see the migration guide |
API | Moved auxiliary constant buffers from the Renoir backend to Renoir core library. This is part of a breaking change in Renoir backends. For more information, see the migration guide |
API | Started doing ClearQuad instead of ClearRenderTarget based on new backend capability. This is part of a breaking change in Renoir backends. For more information, see the migration guide |
API | Added BeginRenderPass and EndRenderPass backend commands to Renoir. This is part of a breaking change in Renoir backends. For more information, see the migration guide |
Version 1.2.1.1
Released 24 Apr 2019
Feature | Updated Unreal Engine to 4.22 |
Fix | Fixed crash when using View::UnloadDocument |
Fix | Fixed support for React v16.5 |
Fix | Fixed using iterator names that are prefix of other iterator namesin data-binding |
Fix | Fixed using {{model}} in data-binding expressions for C++ models. |
Fix | Fixed indexOf and slice for arrays exposed by-ref on ChakraCoreplatforms |
Version 1.2.2.3
Released 13 May 2019
Feature | Added the :active pseudo selector |
Feature | Added the visibility CSS property |
Feature | Added the KeyboardEvent.repeat property |
Enhancement | Added data-bind-html, which allows to set innerHTML with data-binding |
Enhancement | Allowed the localization texts to contain html tags |
Enhancement | Added the load event to script and stylesheet elements |
Enhancement | Enhanced log messages for wrong property names used for data-binding |
Enhancement | model}} (without property) can be used for data-binding |
Enhancement | Scrolling works correctly with nested scrollable elements |
Enhancement | Automatically casting enum types to int for iOS and Switch for binding |
Enhancement | Binding supports long numbers |
Enhancement | Regular on event handlers work with data-bind-for |
Enhancement | Not handled promise rejections are logged |
Enhancement | Added engine.unregisterModel API to unregister a model from JavaScript |
Enhancement | Added an API to set the ILocalizationManager in Unreal Engine 4 integration |
Enhancement | Added support for exposing UDataTable to JavaScript |
Enhancement | Added ability to customize the automatic binding in Unreal Engine 4 |
Fix | Fixed disappearing SVG images when background-image property is changed |
Fix | Positioning of text caret in text inputs with aligment |
Fix | Fixed text selection when text has CSS transform |
Fix | Fixed crash in Unreal Engine 4 when chaining multiple property accesses in data-binding |
Fix | Fixed the gamepaddisconnected event to contain which gamepad has been disconnected |
Fix | Fixed cloneNode to clone attached event listeners |
Version 1.2.3.1
Released 24 Jun 2019
Fix | Fixed crash when using by-value getters in data-binding |
Fix | Fixed crash when recreating views on PlayStation 4 |
Fix | Fixed missing text on the UMG widget on PlayStation 4 |
Fix | Fixed broken gradients on the UMG widget on PlayStation 4 |
Fix | Fixed rendering uninitialized textures with the UMG widget on Xbox One |
Migration guide
This section outlines the changes you need to apply in order to upgrade from Prysm versions 1.1 and prior to 1.2 and later.
The current backend API was designed around DirectX 11 and therefore implementing a DirectX 11 backend with the current API is simple and intuitive. However, with the advent of modern low-level APIs (e.g. Dx12, Metal and Vulkan) and concepts such as render passes, enhancements of the backend API were needed, so that the backend implementation for those graphics APIs is easier and more efficient.
You can read more about the motivation for the backend API changes here.
In Prysm 1.2, Renoir’s backend API has been modified significantly with the introduction of 2 new commands, 4 new Renoir Core capabilities and one new shader type. There are also several changes in the graphics backend that must be adapted from previous versions for the new version to work.
If you prefer to make minimal changes to your backend and not use the new capabilities, here are the steps for migrating:
- Add the following lines to the
FillCaps
method
outCaps.ShouldUseRenderPasses = false;
outCaps.ShouldClearRTWithClearQuad = false;
outCaps.ConstantBufferBlocksCount = 1;
outCaps.ConstantBufferRingSize = 1;
...
outCaps.ShaderMapping[ST_ClearQuad] = ST_ClearQuad;
- Add
unsigned size
as last argument of theCreateConstantBuffer
method and use it for the constant buffer allocation size. This is how theCreateConstantBuffer
method declaration in the backend header should look like:
virtual bool CreateConstantBuffer(CBType type, ConstantBufferObject object, unsigned size) override;
Example of using the size parameter on constant buffer creation from the DirectX11 backend:
bool Dx11Backend::CreateConstantBuffer(CBType, ConstantBufferObject object, unsigned size)
{
D3D11_BUFFER_DESC bufferDesc;
bufferDesc.ByteWidth = size;
...
// Create the constant buffer with the filled buffer description
m_Device->CreateBuffer(&bufferDesc, ..)
}
- In
SetRenderTarget
stop usingEnableColorWrites
flag, as it is no longer present and instead handle thePipelineState's
ColorMask
field inCreatePipelineState
. This field currently only supports the valuesColorWriteMask:CWM_None
andColorWriteMask::CWM_All
, which correspond to the previous false and true values ofEnableColorWrites
. Set the appropriate value of the graphics API’s render target color write mask. E.g. in DirectX11 the write mask is placed in the description of the blend state:
bool Dx11Backend::CreatePipelineState(const PipelineState& state, PipelineStateObject object)
{
...
D3D11_BLEND_DESC desc;
desc.RenderTarget[0].RenderTargetWriteMask = UINT8(state.ColorMask);
...
// Create the blend state with the filled description
m_Device->CreateBlendState(&desc, ...)
}
- In
ExecuteRendering
add empty cases with only abreak
statement in them forBC_BeginRenderPass
andBC_EndRenderPass
:
case BC_BeginRenderPass:
{
break;
}
break;
case BC_EndRenderPass:
{
break;
}
break;
The MSAASamples
field was added to the PipelineState
structure, so you may start using it in CreatePipelineState
.
Below we will describe each new capability, how it can affect your backend, and what the needed changes you need to make to use it are.
When the ShouldUseRenderPasses
capability is enabled, Renoir will start enqueuing the commands BeginRenderPass
and EndRenderPass
and stop issuing the SetRenderTarget
and ResolveRenderTarget
commands. The BeginRenderPass
command provides all the needed information for starting a render pass in modern graphics APIs like Metal and Vulkan. This information includes the render targets, whether they should be cleared on a render pass load, and if they should be resolved on store. Here are the additional steps you need to make to start using this capability:
- Set
ShouldUseRenderPasses
to true in theFillCaps
method - You can remove the implementation of the
SetRenderTarget
andResolveRenderTarget
methods and add an assert that they are never called - Implement a
BeginRenderPass
method, which will handle the corresponding command by using the provided information by it to begin a render pass in the graphics API - Implement an
EndRenderPass
method, which will handle the corresponding command by ending the current render pass, and possibly also reset any currently kept state of the render pass. E.g. in our Metal backend, the implementation of theEndRenderPass
method is the following:
[m_State->CurrentCmdEncoder endEncoding];
m_State->CurrentCmdEncoder = nil;
m_State->BoundGPUState = GPUState();
Enabling the ShouldClearRTWithClearQuad
capability will make Renoir issue a fullscreen clear quad, instead of calling ClearRenderTarget
. The clear quad is done through a new vertex and pixel shader. The capability was added so that we don’t need to create a new render pass to clear a render target in graphics APIs like Metal, which does not provide an easier way to do it. Here are the additional steps you need to make to start using this capability:
- Set
ShouldClearRTWithClearQuad
to true in theFillCaps
method - You can remove the implementation of the
ClearRenderTarget
method and add an assert that it is never called - You need to create a new
ST_ClearQuad
vertex and pixel shader, compile them if necessary and start using them. You can check out the exampleST_ClearQuad
HLSL shaders provided with the DirectX11 backend. The Metal backend is using the clear quad capability, so you can check out how to use the new shaders in its implementation.
The ConstantBufferRingSize
capability allows you to set the size of the internal ring buffer, which is used to manage Renoir’s constant buffers. We recommend setting this size to 4 for low-level graphics APIs like Dx12, Metal and Vulkan. The motivation for this particular size is that the maximum count of buffered frames in a standard pipeline is 3, and in order to surely avoid an overlap of constant buffers, they should be managed by a circular buffer with size 4. If you have a pipeline with a higher maximum count of buffered frames, then this value should be changed accordingly. For most high-level graphics APIs, the ring buffer size should be set to 1, because the drivers for them handle constant buffer overlap internally, and therefore a greater value for the ring buffer size is unnecessary.
The only steps you need to make to start using this capability are:
- Set
ConstantBufferRingSize
to the appropriate value in theFillCaps
method - If you have a ring buffer for the constant buffers in your backend, then you can remove it, because Renoir will do it automatically for you
The ConstantBufferBlocksCount
capability allows you to set the count of aligned constant buffer blocks for each constant buffer type. Renoir will issue a CreateConstantBuffer
call with a size equal to (constant buffer blocks count
) * (aligned specific constant buffer size) for each constant buffer type. If the blocks count
value is greater than 1, then if the regular constant buffer becomes full, Renoir will make sure that a new auxiliary constant buffer is allocated. If the blocks count
value is equal to 1, then Renoir won’t create any auxiliary constant buffers. Auxiliary constant buffers are allocated per frame, thus being allocated before ExecuteRendering
is called and deallocated immediately after that. Setting constant buffer ring size and blocks count
value to greater than 1 usually goes hand in hand, because both provide functionality that otherwise should be explicitly implemented in the backend for low-level graphics APIs like Dx12, Metal and Vulkan. For other APIs that don’t support constant buffers, but use uniform slots (e.g OpenGL) both capabilities should be set to 1 to avoid unnecessary constant buffer creation.
The only steps you need to make, so you can start using this capability are:
- Set
ConstantBufferBlocksCount
to the appropriate value in theFillCaps
method - Remove all the logic in your backend, which manually creates auxiliary buffers once the regular ones are full. Renoir will create and manage them automatically