Repository navigation
This patch release makes call-heavy and tint-heavy code much faster and fixes several behaviors found in production apps, most of them checked against a real Roku device with a probe app under test/simulator/probes/. In the core engine, return, exit, continue and goto no longer capture a JavaScript stack trace, and return is handed back as a value instead of thrown, so 200k function calls now run close to device speed (from ~780ms to ~210ms in the Desktop Simulator, against ~180ms on a Roku Express). An roBitmap keeps up to 64 tinted copies instead of one, so drawing the same bitmap in alternating colors no longer re-tints it on every draw, and a tinted roAnimatedImage reuses its tinted frames until the frame changes. roAnimatedImage now exposes the device's interface and states, roRegion.Clear() replaces the region's pixels instead of blending over them, and GetPng() writes PNGs that other decoders accept. In the browser API, initialize() now resolves only after common.zip has loaded. In the SceneGraph extension, a channel component named like a built-in node type (e.g. ButtonGroup) now shadows the built-in as on a device, renderTracking changes only when a frame is painted, and two loops that ran a production app out of memory are fixed: an observer that re-registered itself during dispatch, and a list re-assigning itemContent on every frame. Read the full release notes below for more details.
Release Changes
Core Engine
- (brs) Cut per-call overhead:
return/exit/continue/gotono longer capture a JS stack trace and node locations are memoized, and atryblock's location now starts attryby @markwpearce in #1335 - (brs)
returnis now passed back as a value instead of thrown, bringing function and method calls close to device speed by @markwpearce in #1336 - (draw2d)
roBitmapnow caches several tinted copies, so drawing it with alternating colors no longer re-tints the whole bitmap each time by @markwpearce in #1334 - (draw2d)
roRegion.Clear()now replaces the region's pixels instead of blending over them, soClear(0)clears to transparent by @markwpearce in #1342 - (draw2d) A tinted
roAnimatedImagenow reuses its tinted frames, and its interface, states and error events match the device by @lvcabral in #1345 - (draw2d)
GetPng()now writes standard PNGs that libpng and other decoders accept, by upgrading@lvcabral/upngto 2.4.0 by @lvcabral in #1343 - (api)
initialize()now waits forcommon.zipbefore resolving, and anexecute()made during initialization waits for it by @lvcabral in #1344
SceneGraph Extension (brs-scenegraph release v0.7.2)
- (rsg) A channel component now shadows a built-in node type of the same name, as on the device by @larsmaultsby in #1333
- (rsg)
renderTrackingnow changes only when a frame is painted, as on the device by @lvcabral in #1346 - (rsg) Fixed two loops that ran a production app out of memory: a field change runs only the observers registered when it started, and lists re-assign
itemContentonly when the content really changed by @lvcabral in #1347 - (rsg) An
AnimatedImagenode that loaded but never played shows its first frame, and one without content measures 0x0 by @lvcabral in #1345
Chores, Build and Dependencies
- Bumped versions and the
brs-scenegraph→brs-enginepeer dependency to v2.7.2, and updated the limitations documentation by @lvcabral in #1348
New Contributors
- @larsmaultsby made their first contribution in #1333 - welcome to the project!
Full Changelog: v2.7.1...v2.7.2