Skip to content

Release 1.2.0 - #35

Merged
TWiesendanger merged 90 commits into
masterfrom
dev
Jul 13, 2026
Merged

TWiesendanger merged 90 commits into
masterfrom
dev

Conversation

@TWiesendanger

Copy link
Copy Markdown
Owner

Release 1.2.0

Everything since 1.1.0: a 3D-centric release adding STEP support, an in-app 3D viewer that works without Inventor, redlining, and body coloring, followed by a full code-review pass that hardened all of it.

90 commits · 203 files · the bulk of the diff is bundled sample files, screenshots, and demo GIFs.

Highlights

  • STEP files (.stp / .step) open like any other document: the full ISO-10303 header, entity counts, products and solid bodies, and a 3D view converted in-app with Open CASCADE. Three STEP schema samples ship in the gallery, and the CLI reads STEP too.
  • 3D views with or without Inventor. A built-in converter decodes the display mesh cached inside the file, so parts and assemblies get a 3D view on machines with no Inventor installed. With Inventor present, a first-use chooser picks between exact translation and the fast best-effort engine.
  • Redlining. Draw freehand, shapes, and text, erase, and paint directly onto the model surface. Markup lives on layers with per-layer camera poses and is saved alongside the cached viewable; export any view as PNG or to the clipboard.
  • Body coloring in the 3D viewer: a colour per body, one click or the C key.
  • Rebindable keyboard shortcuts with an in-viewer shortcuts window.
  • Richer sample gallery, including a real-world fishing-reel assembly whose full reference tree resolves.

Fixes & quality

Redlining and the viewer went through a high-effort review; every confirmed correctness finding was fixed on its own branch and verified before merge:

  • Redline markup no longer lost when the viewer closes right after an edit (flush on exit)
  • Esc now closes the 3D viewer even after you have clicked into it (DOM-side close)
  • Shortcut-rebind key capture no longer leaks when the dialog is dismissed
  • A best-effort cached view no longer overrides an exact-engine preference
  • Esc / Ctrl+Z typed into viewer inputs no longer exit the mode or undo markup
  • Nav-mode drag no longer draws a stray stroke after a forwarded pan
  • Fresh installs get the welcome tip, not release notes
  • About dialog: scrollable history, notices no longer clipped, working "All notices" link
  • Engine chooser wording corrected (the viewer downloads once; it is not "fully offline")
  • Deduplication pass: shared toolbar-wiring, hotkey-suffix, and dev-tooling helpers; cached hotkey bindings; a listener leak closed

Release mechanics

  • Version stamped 1.2.0.0 across the app, About history, and the What's-New dialog (enforced by ReleaseDisciplineTests).
  • After merge, tag v1.2.0 on master to trigger the release workflow, which stamps the version into the exe and MSIX and publishes the GitHub Release.

Verification

  • Solution builds clean in Release; 91 / 91 tests pass.
  • Documentation site builds; screenshots, GIFs, and What's-New content refreshed and current.
  • README updated to cover STEP, the 3D viewer, coloring, and redlining.

Each model state embeds its own cached preview (its geometry can differ -
e.g. a suppressed feature). Extract it per member doc: ParsePropertySetInto
now returns the clipboard thumbnail blob and ExtractThumbnail becomes a
reusable DecodeThumbnail, so each ModelState gets its own Thumbnail (the
surfaced [Primary] state carries the document thumbnail). JSON reports
hasThumbnail per state. The Model States tab shows each preview, clickable
to view enlarged on a dimmed overlay. Adds a test and a docs note.
The SVF has no edge data, so LMV kept model.hasEdges false and hid the
"Display edges" setting - it could never be enabled. Load the model with
createWireframe:true so LMV derives edges client-side (mesh boundaries +
hard angles); the setting now appears under Appearance and persists. Also
call setDisplayEdges(true) after load so models open shaded-with-edges by
default. Documents it in the 3D viewer page.
Open-in-new-window / Move-to-main reparented the TabViewItem between
windows' visual trees synchronously inside the context-menu Click handler,
while the tab-anchored flyout was still dismissing. That concurrent
visual-tree mutation access-violates the VS XAML diagnostics tap
(WinUITap.dll) - the crash seen on detaching a tab. Defer both reparents to
the next dispatcher tick so the flyout closes first.
…ioning

An open TipService TeachingTip keeps re-anchoring its callout to its Target.
When that target (or the host panel) is torn down while the tip is still
pending or open - a tab tear-out reparenting the DocumentView, or a
sidebar/references rebuild recreating the target element - the next
RepositionPopup dereferences a freed element and the process fail-fasts under
Control Flow Guard (FAST_FAIL_GUARD_ICALL_CHECK_FAILURE). Being a fail-fast,
no managed handler runs, so it surfaced as an unlogged "faulting module
unknown" crash in the Store build.

Tear the tip down the moment its target or host unloads: stop both timers,
clear Target before it can reposition against freed memory, close, and
remove from the tree. Idempotent and self-unhooking.
Add an "Extrabbit.Coloring" LMV extension that gives every body its own
colour, so parts of an assembly are easy to tell apart. It enumerates the
leaf nodes of the instance tree and tints each via setThemingColor, using
HSL hues stepped by the golden angle so neighbouring bodies stay well
separated. A palette toolbar button toggles it live (multicolor <-> original
materials).

Expose the starting mode as an app option: Settings -> 3D Viewer -> Body
coloring (Default / Multicolor), persisted in ViewerSettings and passed to
the viewer via ?coloring= on the page URL. The chosen mode is also recorded
on the viewer_3d_opened analytics event.
Add a "Try a sample" button to the Home welcome card that opens a gallery of
bundled sample files, each captioned with the capability it demonstrates
(assembly + reference graph, model states, drawing, iPart / iAssembly
factories, Tube & Pipe). Clicking a card opens that file in its own tab;
"Open all" opens the set. A great zero-setup way to see what MetaReader reads.

SampleFiles now extracts the whole bundled sample folder (not just the
assembly) and exposes a curated, on-disk-verified gallery list; the existing
welcome-tip path (EnsureSampleAssembly) is unchanged.
feat: per-model-state thumbnails, clickable to enlarge
feat: show edges in the 3D viewer (on by default)
fix: defer tab tear-out so it does not crash mid-flyout-dismiss
feat: "Try a sample" gallery on the start page
feat: body coloring in the 3D viewer (a colour per body)
fix: intermittent CFG fail-fast (0xC0000409) from TeachingTip reposit…
…ESULT

When MetaReader attaches to an already-running Inventor that is momentarily
busy (mid-operation or showing a dialog), incoming COM calls are rejected and
- with no message filter registered - fail instantly with a generic
"Unexpected HRESULT has been returned from a call to a COM component"
(RPC_E_CALL_REJECTED), killing the whole translation in milliseconds.

Three changes:
- Register the classic OLE IMessageFilter on the STA generation thread so a
  rejected/busy call is retried (200 ms) for up to a minute instead of failing.
- Wire the existing step logging through to Serilog and log the raw HRESULT +
  exception type on failure, so the exact failing COM call is diagnosable
  instead of a generic string.
- Map the busy HRESULTs to a clear, actionable message ("Inventor was busy...
  close any open dialog, or that session, then try again").
Parse ISO 10303-21 headers dependency-free (StepFile.cs) and show STEP files
like Inventor documents. The 3D view triangulates the geometry with the
bundled occt-import-js WASM module (OCCT) and renders it as GLB in the
Autodesk viewer - no Inventor needed.
Add an Open-Source Notices section to the About dialog, THIRD-PARTY-NOTICES.md
at the repo root, and a vendor README pinning occt-import-js 0.0.23 provenance
(hashes, unmodified, how to replace the module).
A real-world steel part (Fishing Rod project) showing material, mass, volume
and version history back to Inventor 11 - opens from the start-page gallery.

The extracted samples folder is now topped up with files added in an update
(previously it was copied once and new samples never arrived on existing
installs).
Ship the same part in three STEP schemas (AP203, AP214 as .step, AP242) and
show them in the "Try a sample" gallery. Sample folders are now generalised
(SampleBg + SampleSteps) and topped up on updates instead of copied once.
Point the tests at the shipped SampleSteps files (linked like SampleBg) and
drop the separate test copies. The three files cover one schema each, so
every protocol the app claims to open is exercised.
feat: add Line Guide Drive Shaft as a bundled sample
fix: retry a busy Inventor during SVF generation, and log the real HR…
Load viewer3D.min.js and style.min.css from a pinned release (7.122, what
7.* resolves to today) instead of the floating 7.* alias, so an
Autodesk-pushed viewer update cannot change behaviour under us. Bump the
LmvViewerVersion constant deliberately and retest.

Fixes #29
feat: pin the Autodesk viewer to a fixed version
fix: CLI accepts STEP files for info/states/json/props/graph
The feature/step-file-support and feature/fishing-rod-sample merge left both
sides interleaved: a gallery entry spliced into a doc comment, a stray "];"
and a duplicated single-folder EnsureSampleFolder referencing the removed
Folder constant - dev did not compile. Keep the multi-folder version and add
the Line Guide Drive Shaft entry to the gallery properly.
Use the ExtrabbitCode.Inventor.SvfConverter NuGet package as a second
generation engine: it converts .ipt/.iam to SVF from the mesh cached in the
file, no Inventor needed.

- No Inventor installed: 3D views now work via the built-in converter. A
  one-time notice explains they are best effort (positions/rotations can be
  off) with a mail link (extrabbitcode@gmail.com) to report wrong models.
- Inventor installed: the first generation asks which engine to use - a
  two-card chooser laying out the trade-offs (exact vs fast/best effort).
  The choice persists and can be changed in Settings -> 3D Viewer.
- Best-effort views carry a warning badge in the viewer's top-left with a
  "Report this model" link that opens a prefilled mail.
- Cache: an Inventor entry has bubble.json, a built-in entry has
  output\0.svf - the layout marks the engine, so cached best-effort entries
  keep their badge. The viewer loads raw SVF entries via loadModel.
Raw-SVF loads get their object tree after GEOMETRY_LOADED (or not at all
until the property DB finishes), so the coloring extension found no instance
tree and silently did nothing - initial multicolor never applied and the
toolbar button no-oped.

Re-apply on OBJECT_TREE_CREATED, and when no tree is available collect the
dbIds straight from the fragment list (the converter stamps one dbId per
body there too). Colors are cleared before re-applying so a late tree
replaces the fragment-based pass cleanly.
The initial multicolor pass can run while fragments are still streaming in
(the toolbar exists from the start), so only the bodies loaded at that moment
were colored; GEOMETRY_LOADED then did nothing because coloring was already
on. Re-apply on GEOMETRY_LOADED and OBJECT_TREE_CREATED alike, so the pass
that sees the complete model wins.
…s, cached bindings, toggle() API, listener + dead-code cleanup
…neMarkup, ViewerReadyJs), engine-title and redline-file constants
@TWiesendanger TWiesendanger self-assigned this Jul 13, 2026
@TWiesendanger TWiesendanger added bug Something isn't working enhancement New feature or request labels Jul 13, 2026
@TWiesendanger
TWiesendanger merged commit 108cd4a into master Jul 13, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant