Skip to content

Development - #137

Merged
DraTeots merged 42 commits into
mainfrom
development
Oct 9, 2026
Merged

DraTeots merged 42 commits into
mainfrom
development

Conversation

@DraTeots

@DraTeots DraTeots commented Oct 9, 2026

Copy link
Copy Markdown
Collaborator

Firebird 2026.10.0-beta.1: reusable packages, ePIC pack, new release layout

What changes

  • Packages. The frontend splits into publishable packages:

    • @dexvis/firebird-ng: the Angular library (services, components, <firebird-display>, firebirdRoutes()).
    • @dexvis/firebird-core: worker-safe event model, DEX io, painters.
    • @dexvis/root2dex: ROOT -> DEX conversion in the browser.
    • @dexvis/firebird-epic: the ePIC experiment pack.

    firebird-ng/ is now the app alone: app.config.ts is provideFirebird(withEpic(...), withExampleCherenkov()).

  • Extension API.

    • Features carry ids, with one override rule for every registry and withoutFeatures(id) to drop parts.
    • Loaders return data and throw errors with the reason.
    • New seams: withRootGeometryRules, withGeometryPostProcessor, withGeometryTheme, withCameraPreset, withCollisionIntro, withToolbarAction, withWorkers.
  • ePIC knowledge leaves generic code. Geometry rules, themes, prettifier, arranger, camera views, the collision intro and the data catalog live in packages/epic.

  • dexvis submodules are tagged and published on npm: root-geo-tree-editor 0.2.0, plus threejs-tree-editor, viewport-gizmo, shell and app-features at 0.1.0. app-features-ng is now a public repo and a submodule.

  • Build. The plain-TS packages build with one shared tsdown.config.ts; the Angular libraries build with ng-packagr. ES modules only.

  • Example data. All samples are DEX 1.0 files on https://seeeic.org/d/. The bundled copies left the repo, so the wheel shrinks from 100 MB to 10 MB.

  • pyrobird.

    • Out-of-range ROOT entries clamp, with one warning.
    • merge and convert write real zip files.
    • smooth --max-points caps output size.
    • Licenses: GPL-3.0-or-later for the app and pyrobird, MIT for the libraries.
  • Versions: the app and pyrobird are 2026.10.0-beta.1 (pip install --pre pyrobird); the new libraries are 0.1.0-beta.1.

Deploy

The seeeic.org autobuild (firebird-deploy) watches main. Merging this PR deploys the new frontend within 20 minutes.

Known follow-ups

  • The bundled "DIS CC" samples hold DIS NC events and need regenerating.
  • Some combinations in the Physics tab have no sample file yet.
  • Later: the geo-viewer, the mini-player, the tutorial, the docs overhaul and the move to apps/firebird.

DraTeots added 30 commits March 19, 2026 12:05
Replace Three.js WebGLRenderer with WebGPURenderer across the frontend.
WebGPURenderer automatically falls back to WebGL2 when WebGPU is not
available, ensuring compatibility with Chrome and Firefox.

Key changes:
- Import WebGPURenderer and PMREMGenerator from 'three/webgpu'
- Make renderer init async (await renderer.init() required before render)
- Propagate async init through event-display and main-display
- Migrate clipping: remove renderer.localClippingEnabled and
  renderer.clippingPlanes (WebGL-specific), apply Z clipping via
  material clipping planes alongside angular clipping
- Update perf service, animation, gizmo, and prettifier types
- Replace LineMaterial with Line2NodeMaterial (from three/webgpu) in
  trajectory.painter, step-track.painter, and three-event.processor.
  LineMaterial is WebGL-specific and incompatible with the node material
  system used by WebGPURenderer.
- Fix race condition: move initThree() from ngOnInit to ngAfterViewInit
  in main-display component. Since init() is now async, ngAfterViewInit
  was running before the renderer was ready, causing
  'addEventListener' errors in CubeViewportControl.
- Add type casts for Line2 constructor (expects LineMaterial type but
  Line2NodeMaterial is API-compatible at runtime).
- Guard updateMaterialClipping() against calls before init completes.
  Angular effects in geometry-clipping component fire before async
  ThreeService.init() finishes, causing 'traverse' on undefined.
- Replace geometry.instanceCount = Infinity with actual segment count.
  WebGPU's drawIndexed rejects Infinity as instanceCount (WebGL
  silently clamped it). Use points.length - 1 for trajectories and
  getAttribute('instanceStart').count for event-display tracks.
- Update trajectory painter tests to match new instanceCount values.
Replace material-level clipping planes with ClippingGroup on sceneGeometry.
Only geometry is clipped — sceneEvent remains a regular Group and is never
subject to clipping.
Effects in geometry-clipping.component fire before init() finishes (async).
The clipping state was stored but updateClippingGroups() bailed out due to
the initialized guard. Now updateClippingGroups() is called right after
initialized = true so the stored state is applied.
ClippingGroup applies clipIntersection to ALL its planes. When angular
clipping used intersection mode, Z clipping was incorrectly affected,
causing the Z clip position to appear camera-dependent.

Now uses two nested ClippingGroups:
  zClippingGroup (union mode, Z plane)
    └── sceneGeometry (intersection/union, angular wedge planes)

Each group has its own independent clipIntersection flag.
The gizmo overlay was appended to an empty .three-container div with no
dimensions or positioning context. Now uses the renderer's parent element
(#eventDisplay) as the container, and adds position:relative to it so the
absolute-positioned gizmo overlay aligns correctly.
three-viewport-gizmo computes viewport Y using WebGL's bottom-left origin.
WebGPU uses top-left origin, causing the gizmo to render at bottom-right
while hit-testing stays at top-right. Monkey-patch domUpdate() to use
top-left Y when WebGPURenderer is detected.

Ref: https://github.com/nicivore/three-viewport-gizmo/issues/13
Use X-axis as up vector for top/bottom views so Z (beam axis) maps to
screen-right and X maps to screen-up, matching collider convention.
Increase top offset from 85 to 115 to clear the header panel.
Patch _setOrientation to use Z-axis as up vector when viewing along Y
(Top/Bottom faces). The default library uses Y-up for all lookAt calls,
which is degenerate when the camera position is along Y. With this fix,
clicking "Top" looks down Y with Z (beam axis) horizontal.
return send_file(filename, as_attachment=True, conditional=True)
# Serve the resolved path that passed the check, under the requested name
real_path = os.path.realpath(filename)
if os.path.isfile(real_path):
# Serve the resolved path that passed the check, under the requested name
real_path = os.path.realpath(filename)
if os.path.isfile(real_path):
return send_file(real_path, as_attachment=True, conditional=True,
Comment on lines +331 to +332
return {"error": f"Invalid entry format: '{shorten(entries)}'. "
f"Expected integers or ranges like '1-5'."}, 400
err_msg = (f"For entries='{shorten(entries)}' the request names {requested_count} entries; "
f"at most {max_entries} are allowed per request.")
logger.warning(err_msg)
return {"error": err_msg}, 400
@@ -59,7 +117,7 @@ def capture_screenshot(url, output_path):
print(" python3 -m playwright install chromium")
print("Beware that on the first run, if chrome is not installed in the system it will try to download it")
print("Google playwright-python if not sure. Exiting without screenshot now")
exit(1)
exit(EXIT_FAILURE)
Comment on lines +3 to +8
import {
AMBER_50, BLUE_50, GRAY_50, INDIGO_80, PINK_50, PURPLE_50, GRAY_100, GREEN_100, ORANGE_100,
YELLOW_100, BLUE_200, BROWN_100, AMBER_200, INDIGO_200, GREEN_200, ORANGE_200, ORANGE_DEEP_200,
TEAL_200, YELLOW_200, BLUE_300, GRAY_300, BLUE_GRAY_400, PURPLE_400, AMBER_500, GUNMETAL_BLUE,
PEWTER, STEEL_BLUE, TITANIUM, CHROME, SILVER,
} from "@dexvis/firebird-ng/geometry-palette";
// 10) SCENE TREE / UI
private updateSceneTreeComponent() {
// Example: rename lights
const scene = this.eventDisplay.three.scene;
Comment on lines +35 to +46
import {
COLLISION_INTRO,
CollisionIntro,
DataSelectionService,
EVENT_DATA_LAYER,
EVENT_LOADERS,
GEOMETRY_LOADERS,
PAINTERS,
ROOT_COLLECTIONS_CONFIG,
ROOT_EVENT_RANGE_CONFIG,
SELECTION_CONFIG_KEYS,
} from '@dexvis/firebird-ng/api';
let endTime = 0;
if (points[0].length > this.timeColumnIndex) {
startTime = points[0][this.timeColumnIndex];
endTime = points[points.length - 1][this.timeColumnIndex]
@DraTeots
DraTeots merged commit ee65aa1 into main Oct 9, 2026
28 of 35 checks passed
@DraTeots
DraTeots deleted the development branch October 9, 2026 22:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants