Render Anything Engine: tell your AI what to make. Videos, motion graphics, 3D and games as React and TypeScript, rendered on your own GPU. Rust + Bevy, macOS, Linux and Windows.
TypeScript 3dagent-skillsai-agentsai-videobevyclaude-codegame-enginegpulinuxmacosmotion-designmotion-graphicsreactrusttypescriptvideo-editingvideo-renderingwgpuwindows
FC0a: ui/widgets/standard_widgets_observers ports at 0.99874: the headless Button, Slider and Checkbox as their observers leave them at rest, the thumb at 50% once update_widget_values inserts the resource's value. The bar fails only the Hover mutant; probes catch the rest (the thumb at 0%: its pixel 13, not 191; a checked mark: 191, not 44; no TextShadow: the button's region 207 pixels off, not 168). 95 of 99 ported examples pass
shinyobjectze31303c7fd4d
diff --git a/bench/bevy-parity/examples.list b/bench/bevy-parity/examples.listindex 18dd7bbf..30087e04 100644--- a/bench/bevy-parity/examples.list+++ b/bench/bevy-parity/examples.list@@ -98,3 +98,4 @@ ui/widgets/tab_navigationui/widgets/viewport_nodeui/widgets/vertical_sliderui/widgets/virtual_keyboard+ui/widgets/standard_widgets_observersdiff --git a/bench/bevy-parity/runs.tsv b/bench/bevy-parity/runs.tsvindex 093799ff..a14b23ad 100644--- a/bench/bevy-parity/runs.tsv+++ b/bench/bevy-parity/runs.tsv@@ -97,3 +97,4 @@ ui/widgets/tab_navigation - 10ui/widgets/viewport_node - 10ui/widgets/vertical_slider - 10ui/widgets/virtual_keyboard - 10+ui/widgets/standard_widgets_observers - 10diff --git a/docs/bevy-parity.md b/docs/bevy-parity.mdindex f418ec15..35e23781 100644--- a/docs/bevy-parity.md+++ b/docs/bevy-parity.md@@ -4,7 +4,7 @@ Bevy v0.20.0's examples against their raea TSX ports (docs/control.feature FC0a)don't edit. An example passes when every probed frame passes pixels (SSIM 0.98 and no 32 px tile off by more than 24 of 255) and cost (batch keys andframe time at most 1.25x the example's). Wall time is one machine's, measured in the same run.-Examples: **438**, ported **98**, passing **94**, excluded **16** (docs/bevy-parity/excluded.tsv), left **328**.+Examples: **438**, ported **99**, passing **95**, excluded **16** (docs/bevy-parity/excluded.tsv), left **327**.raea's frame ms is its update's plus the time React takes to step a frame for its 3D (step), which the exampledoesn't pay.@@ -154,6 +154,7 @@ doesn't pay.| ui/widgets/viewport_node | 10 | 0.999871 | 0 | 1 / 1 | 446 / 498 | 6 / 8 | 2 / 2 | 38.34 / 2.039 = 2.039 + 0 | yes | || ui/widgets/vertical_slider | 10 | 0.999004 | 11 | 0 / 0 | 459 / 493 | 5 / 7 | 1 / 1 | 37.247 / 1.764 = 1.764 + 0 | yes | || ui/widgets/virtual_keyboard | 10 | 0.993705 | 13 | 0 / 0 | 646 / 493 | 5 / 7 | 1 / 1 | 40.167 / 1.441 = 1.441 + 0 | yes | |+| ui/widgets/standard_widgets_observers | 10 | 0.998736 | 14 | 0 / 0 | 473 / 493 | 5 / 7 | 1 / 1 | 37.156 / 0.873 = 0.873 + 0 | yes | |## Excludeddiff --git a/sdk/raea/bench/bevy-parity/ui/widgets/standard_widgets_observers.tsx b/sdk/raea/bench/bevy-parity/ui/widgets/standard_widgets_observers.tsxnew file mode 100644index 00000000..a7b3e2a3--- /dev/null+++ b/sdk/raea/bench/bevy-parity/ui/widgets/standard_widgets_observers.tsx@@ -0,0 +1,44 @@+// Bevy v0.20.0 examples/ui/widgets/standard_widgets_observers.rs in raea's TSX (docs/control.feature FC0a): a+// full-window column, centred both ways with 10 px rows, of the headless widgets at rest, as the observers leave them+// once each component is inserted. A 150 x 65 round Button (5 px black border on srgb(0.15, 0.15, 0.15)) reading+// "Button" in FiraSans-Bold 33 px srgb(0.9, 0.9, 0.9) with TextShadow's default; a Slider 30% wide and 12 px high, its+// 6 px srgb(0.05, 0.05, 0.05) track (3 px corners) and a round 12 px srgb(0.35, 0.75, 0.35) thumb at left 50% of a box+// 12 px short of its right (update_widget_values puts DemoWidgetStates' 50 into SliderValue on the first frame); a+// Checkbox, a 16 px box with a 2 px srgb(0.45, 0.45, 0.45) border (3 px corners) and no mark, beside "Checkbox" in+// FiraSans-Bold 20 px; and "Press 'D' to toggle widget disabled states" in Bevy's default font. Hover, presses and 'D'+// change them only under input. Bevy's Camera2d over the default clear colour is the layered <Canvas3D>, in Bevy's+// default 1280 x 720 window.+import { AbsoluteFill, Composition, registerRoot, staticFile } from "raea";+import { Canvas3D } from "raea/3d";+import { BorderRadius, Node, Text, TextShadow, UiRect, percent, px } from "raea/ui";+import { Srgba } from "raea/color";++const BOLD = "fonts/FiraSans-Bold.ttf";++function Shot() {+ return (+ <AbsoluteFill>+ <Canvas3D layered clearColor="rgb(43, 44, 47)" />+ <Node width={percent(100)} height={percent(100)} align_items="Center" justify_content="Center" display="Flex" flex_direction="Column" row_gap={px(10)}>+ <Node width={px(150)} height={px(65)} border={UiRect.all(px(5))} justify_content="Center" align_items="Center" border_radius={BorderRadius.MAX} border_color={new Srgba(0, 0, 0)} background_color={new Srgba(0.15, 0.15, 0.15)}>+ <Text font={staticFile(BOLD)} font_size={{ Px: 33 }} color={new Srgba(0.9, 0.9, 0.9)} shadow={TextShadow.default()}>Button</Text>+ </Node>+ <Node display="Flex" flex_direction="Column" justify_content="Center" align_items="Stretch" justify_items="Center" column_gap={px(4)} height={px(12)} width={percent(30)}>+ <Node height={px(6)} border_radius={BorderRadius.all(px(3))} background_color={new Srgba(0.05, 0.05, 0.05)} />+ <Node display="Flex" position_type="Absolute" left={px(0)} right={px(12)} top={px(0)} bottom={px(0)}>+ <Node display="Flex" width={px(12)} height={px(12)} position_type="Absolute" left={percent(50)} border_radius={BorderRadius.MAX} background_color={new Srgba(0.35, 0.75, 0.35)} />+ </Node>+ </Node>+ <Node display="Flex" flex_direction="Row" justify_content="FlexStart" align_items="Center" align_content="Center" column_gap={px(4)}>+ <Node display="Flex" width={px(16)} height={px(16)} border={UiRect.all(px(2))} border_radius={BorderRadius.all(px(3))} border_color={new Srgba(0.45, 0.45, 0.45)}>+ <Node display="Flex" width={px(8)} height={px(8)} position_type="Absolute" left={px(2)} top={px(2)} background_color={new Srgba(0, 0, 0, 0)} />+ </Node>+ <Text font={staticFile(BOLD)} font_size={{ Px: 20 }}>Checkbox</Text>+ </Node>+ <Text>Press 'D' to toggle widget disabled states</Text>+ </Node>+ </AbsoluteFill>+ );+}++registerRoot(() => <Composition id="main" component={Shot} durationInFrames={11} fps={60} width={1280} height={720} />);