Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
9.9 KiB
9.9 KiB
Decisions
One line per decision: date · decision · alternative · reason.
| Date | Decision | Alternative | Reason |
|---|---|---|---|
| 2026-10-02 | The prototype dump docs/reference/titano-prototype.md was not supplied; algorithms are implemented from the brief's descriptions and the cited literature, with the §20.4 thresholds as acceptance tests. |
Wait for the dump | Not available in the repository or uploads; the brief fully specifies behaviour and gates. |
| 2026-10-02 | Custom WPF theme dictionaries (Titano.Ui/Themes) implementing DESIGN.md tokens instead of Application.ThemeMode Fluent. |
Fluent theme + overrides | DESIGN.md fixes exact colours/sizes; Fluent is still flagged experimental (WPF0001) and would need restyling of most controls anyway (§2.1 permits in-house dictionaries). |
| 2026-10-02 | Added shared WPF library src/Titano.Ui (theme, icons, controls, Loc markup extension) used by App, Uploader and Setup. |
Duplicate resources per app | One visual system for three programs. |
| 2026-10-02 | Added tests/Titano.Core.Windows.Tests for WIC / Media Foundation / DXGI tests. |
Put them in App.Tests | Keeps engine interop tests independent of the WPF app. |
| 2026-10-02 | Localization areas extended with Common, Jobs, Uploader, Setup. |
Fold into Shell |
Smaller, owned files; same key scheme. |
| 2026-10-02 | Resources live in i18n/<culture>/<Area>[.<culture>].resx, embedded into Titano.Core (satellite assemblies), base name Titano.Core.i18n.<Area>. Keys marked <comment>invariant</comment> need no translation. |
Raw XML loader | Uses ResourceManager as the brief requires; satellites bundle into single-file publishes. |
| 2026-10-02 | Program icons (ICO) are generated at build time into artifacts/icons by Titano.Tools make-icon, invoked from Directory.Build.targets. |
Commit generated ICO files | Brief forbids committing generated binaries and raster sources. |
| 2026-10-02 | In-house CRC-32 (Titano.Core.Hashing.Crc32). |
System.IO.Hashing | That assembly is a NuGet package, not part of the shared framework. |
| 2026-10-02 | Windows projects target net10.0-windows (platform version 7.0) without a Windows SDK projection TFM; Windows 10 APIs are reached by P/Invoke/COM. |
net10.0-windows10.0.19041.0 |
Avoids the CsWinRT projection; toasts use the in-window toast host plus tray balloon. |
| 2026-10-02 | Test projects use an explicit TestMain entry point. |
Top-level statements | Avoids the Program type clash with the server's top-level program. |
| 2026-10-02 | SQLite P/Invoke binding lives in Titano.Data with a library resolver (winsqlite3 on Windows, system libsqlite3 elsewhere for tests/dev); the Linux server still refuses SQLite at configuration time. |
Binding in Core.Windows only | Lets repository tests run on Linux CI against both dialects. |
| 2026-10-02 | Client preferences needed before the database opens (language, theme, window placement) are stored in settings.json next to the database. |
Settings table only | Language and theme must apply before the first window appears. |
| 2026-10-02 | Server Windows-service hosting will use an in-house advapi32 P/Invoke host. | Microsoft.Extensions.Hosting.WindowsServices | That assembly is a NuGet package, not part of the shared framework. |
| 2026-10-02 | Admin panel files are embedded resources served by an in-house middleware with ETags and SPA fallback. | ManifestEmbeddedFileProvider | Its manifest generator ships in a NuGet package. |
| 2026-10-02 | Container health check runs Titano.Server --healthcheck (in-process HTTP probe). |
curl/wget in the image | Keeps the runtime image free of extra tools. |
| 2026-10-02 | Container drops privileges with setpriv to PUID:PGID; /data is chowned, /archive only checked for write access. |
Recursive chown of the archive | The archive may hold terabytes on NAS shares. |
| 2026-10-02 | Release workflow publishes to RELEASES_REPO (default <owner>/titano-releases) when the RELEASES_TOKEN secret exists, otherwise to this repository. |
Fail without the token | First releases work before the public repository is set up. |
| 2026-10-02 | Release notes are generated by Titano.Tools changelog from git log piped on stdin. |
Tool spawning git | Keeps the tool free of external process calls. |
| 2026-10-02 | CI dotnet format gate checks whitespace formatting. |
Full style/analyzer verification | Analyzer rules already fail the build (warnings as errors); style preferences stay suggestions. |
| 2026-10-02 | Test runner exits 0 for a project with no tests and 2 when a filter matches nothing. | Always 2 | Empty projects during bootstrap are not failures; mistyped filters are. |
| 2026-10-02 | COM via [ComImport] + explicit ReleaseComObject; flat APIs via LibraryImport. |
[GeneratedComInterface] |
Deterministic release keeps files unlocked; the apps are not trimmed. |
| 2026-10-02 | WIC decodes to 64bppRGBA and linearises with the exact sRGB LUT (128bpp float only for float sources). | Always 128bppPRGBAFloat | WIC's integer→float gamma is not the exact sRGB curve and premultiplication darkens edges. |
| 2026-10-02 | Exif orientation is applied in managed code while de-interleaving. | IWICBitmapFlipRotator |
Microsoft documents quadratic behaviour of the flip-rotator over scanline decoders. |
| 2026-10-02 | Volume watcher uses a hidden top-level tool window plus 3 s polling. | Message-only window | Message-only windows do not receive broadcast WM_DEVICECHANGE. |
| 2026-10-02 | Camera RAW is "native" via WIC only when the Raw Image Extension package is installed. | Decoder CLSID alone | The in-box RAW codec shares the CLSID but only reads embedded previews. |
| 2026-10-02 | HEVC/AV1 decoder presence is detected with MFTEnumEx. |
Store package names | Also covers OEM and hardware decoders. |
| 2026-10-02 | Math code lives in src/Titano.Core/Math with namespace Titano.Core.Mathematics. |
Titano.Core.Math |
That namespace would shadow System.Math in every Titano.Core.* file. |
| 2026-10-02 | CCT = McCamy refined to the nearest Planckian point (Krystek, CIE 1960 uv), valid for |Duv| ≤ 0.02. | Plain McCamy | McCamy alone misses the 100 K gate above ~9000 K. |
| 2026-10-02 | Deflicker keeps (1 − strength)·ρ·S of a frame's deviation (ρ own Tukey weight, S window surviving fraction). | Blend by S only | S alone barely isolates outliers. |
| 2026-10-02 | LOWESS uses the k nearest valid samples with bandwidth = farthest distance + one spacing. | Fixed half-width | Constant sample count at sequence edges. |
| 2026-10-02 | Clock jump = backward step > 3× median interval or a ±1 h offset from cadence (DST); counts as one interval. | Any whole-hour step | Scheduled multi-hour pauses look the same. |
| 2026-10-02 | Time zone for solar labels: recorded offset → camera−GPS clock (15 min) → longitude/15 with a "time zone estimated" finding. | No day phases | Usable labels, honestly flagged. |
| 2026-10-02 | Holy-grail step is "received" when the detrended median jump ≥ 50 % of the metadata step (same sign); metadata amplitude is redistributed with smoothstep ramps lengthened until ≤ 0.3 EV/frame. | Measured amplitude | Flicker makes the measured jump noisy. |
| 2026-10-02 | Flicker fundamental = first autocorrelation peak within 80 % of the strongest; window ∈ [15, 151], odd. | Strongest peak | Avoids harmonics at fractional periods. |
| 2026-10-02 | Optical flow: dense pyramidal Lucas–Kanade with box filters, neighbour-flow correction, σ = 1 px pre-blur; grid step 4/2/1 px for Draft/Balanced/Best. | Farnebäck | Separable, SIMD-friendly, stable and as accurate on smooth motion. |
| 2026-10-02 | Phase correlation: Gaussian-shaped peak + log-parabola sub-pixel fit, both patches in one complex FFT. | Foroosh sinc fit | Exact for Gaussian peaks, half the FFT work. |
| 2026-10-02 | Stabiliser: noise-corrected texture gate, exhaustive pairwise similarity hypotheses (≤ 36) + weighted LS, path smoothed by Gaussian-weighted local linear regression (σ = 12). | RANSAC / plain Gaussian | Deterministic with nine patches; keeps intentional pans. |
| 2026-10-02 | Interpolation chooses velocities by forward–backward consistency with per-sample flow-agreement weights (τ = 3 px). | Super SloMo combination | Better at motion boundaries (36.8 vs 33 dB). |
| 2026-10-02 | Virtual-camera zoom is interpolated geometrically; trail length L ↦ decay 0.01^(1/L). | Linear zoom / half-life | Even perceived speed; the trail is gone at its stated length. |
| 2026-10-02 | Motion estimation, sharpness and noise use sRGB-encoded luminance. | Linear light | Shadows keep texture weight; less exposure dependence. |
| 2026-10-02 | Archive presets use 0.30 bpp (≈60 Mb/s at 4K24 HEVC 10-bit); share presets use the brief's per-codec defaults (0.10/0.07/0.05). | 0.07 bpp everywhere | An archive must survive later re-encoding; star fields are the hardest content. |
| 2026-10-02 | All metadata fallback chains (time, ISO, serial, lens, rating, size) live in MetadataBuilder.Build; parsers only collect candidates. |
Fallbacks inside each parser | One place for priority rules; parsers are order-independent. |
| 2026-10-02 | MetadataReader.Read(path) throws when the file cannot be opened; malformed content becomes warnings (with a parser-fault safety net the fuzz tests require to stay unused). |
Swallow everything | An unopenable file is not malformed input. |
| 2026-10-02 | HEIF irot/imir override Exif orientation (imir axis 0 = top↔bottom). |
Exif first | HEIF decoders apply the transforms themselves; both would rotate twice. |
| 2026-10-02 | Main image size comes from the container's own size field (SOF, IHDR, ispe, VP8X, RAF crop record, RW2 borders, CR3 CMP1) before raster IFDs. | Always the largest raster IFD | That is what each container defines and what decoders output. |
| 2026-10-02 | Only MPF large-thumbnail entries count as previews; XMP date-only values are never used as capture times. | Every secondary image / midnight | Gain maps are not previews; midnight would be invented. |