Commit Graph
100 Commits
Author SHA1 Message Date
chasse20 6f8e984d7a Auto: Integrate main and reduce repeated procedural sampling work
Reuse two fur seed tables per worker, share knot noise, and skip invisible decay and brocade detail. Normalize each catalog lookup once while preserving label and saved-name aliases.

Consolidate periodic sampling helpers, move FurLock into its own module, and strengthen coverage of coarse-grid fallback and saved pattern names. Preserve main's project and Assets changes and document the expanded catalog.
2026-11-18 21:52:15 +00:00
Morion 77c39a8dd6 Read a pattern exactly when its coarse grid coordinate is not finite
plane_value blended four samples of a coarse grid, and a point so far out that the grid overflowed made the blend NaN although the pattern itself was finite there. It now reads the exact point in that case. The test checks every procedural at the extreme coordinates and fails without the fix (Cells at infinity gave NaN).
2026-11-18 11:50:53 -05:00
Morion 8e7bc663fd Fix knotty wood seam, replace coral maze with rotting flesh, test scale coverage
Knotty wood measured the ring a knot pulls towards from the copy of the unit the point was in, so a knot across the top or bottom edge left a horizontal mark when the unit repeated; it is now measured from the knot's own copy, and a test checks that no pattern is rougher across the edge of the unit than across its middle. Coral maze becomes Rotting flesh: folded wet tissue with branching veins and blistered patches of decay. The reptile scales test now asserts that a scale covers every point instead of reading a minimum brightness.
2026-11-18 11:31:25 -05:00
Morion 77eb6a2b85 Merge origin/main into feat/procedural-geometric-tilings 2026-11-18 10:53:50 -05:00
Morion 4993700189 Add organic, fabric, timber and camouflage procedurals
Thirteen seamless patterns: smooth fur, mackerel sky, soft billow, reptile scales, young bark, coral maze, camouflage, knit, basket weave, goose-eye twill, slub silk, strip flooring and knotty wood. Each repeats every unit and takes extreme and non-finite coordinates. Tests cover repetition, range, variation, the seed and the extremes, plus the specific structure of the scales, bark, maze, camouflage tones, weaves and boards.
2026-11-18 10:38:07 -05:00
chasse20 b85088526a Auto: Merge main and reconcile Tile Generator fill sources
Use the Tile Generator sampling context for gradient maps and retain pattern settings and gradient stops through fill edits. Keep the shared picker alongside the gradient, decal symmetry, and layer selection controls. Collect thumbnails after the dock and detached windows draw.

Update affected tests for the merged picker and cover image-backed and reduced-resolution gradients.
2026-11-18 07:25:28 +00:00
chasse20 0ff72b0d46 Auto: Revert export additions and evaluate brush pickup by tile
Remove DDS encoding, its dependency, export options, tests and documentation. Revert the MaterialX export-dialog option and preview additions while retaining engine export support.

Evaluate material-brush and mask Clone/Smudge pickup on demand. Give mask preview and commit an explicit value image. Sample the document in solo mode and avoid redundant export cache invalidation.

Validate saved decal axes, stencil settings and smudge strength. Bound smart-mask reads, write masks atomically and reject external anchor references. Clear stale clone sources on cross-set selection. Reject moves into another set’s folder and use layer positions to detect no-op moves without cloning the project again.

Load saved materials on shelf click and route pinch gestures to viewport zoom. Add regression tests for the affected behaviors.
2026-11-18 05:20:25 +00:00
Morion 5907ad6a45 Merge origin/main into feat/procedural-geometric-tilings 2026-11-17 23:24:15 -05:00
chasse20 26490af2b9 Auto: Harden command and clone bounds and reduce mask allocations
Reject overflowing set indexes, saturate layer moves and clone offsets, and validate path corner flags before mutation. Clear discarded path caches and replace disabled-mask previews with a blank upload.

Reduce repeated selection allocations and temporary mask buffers. Preserve public reexports while separating types, and complete scoped comment and guard-spacing cleanup.

Validated paint and focused engine tests, workspace Clippy, production wasm checks, layering and formatting.
2026-11-18 04:14:11 +00:00
chasse20 7d1573d491 Auto: Fix tile rendering, panel edits, and localized test harnesses
Respect per-UV-tile resolution when reducing procedural patterns. Cover rotated tiles across repeat boundaries without counting overlapping copies more than once.

Preserve both contrast and invert edits when committed together, with regression coverage. Pin tile-panel tests to English and allow missing glyphs in the image-menu preview-cache harness.
2026-11-18 01:17:09 +00:00
chasse20 f06c8acecf Auto: Integrate main and defer hidden picker previews
Create image and anchor previews only for visible picker tiles, advance
outside thumbnail frames so stale handles can expire, and reuse bilinear
corner samples. Add focused preview and lifetime regressions and complete
scoped comment, spacing, and slider-constant cleanup.

Preserve the prepared main integration. Validated with affected release
tests, workspace Clippy, layering, wasm, panic_hunt, formatting, and
offscreen UI snapshots.
2026-11-18 00:05:33 +00:00
vangel76 d9bdef92b2 TextureCraft UI parity batch: 45 changes in one commit
Combines 45 open pull requests so the Windows proof build runs once. Included:

- Fill layers can color from dark to light with a gradient map (PR #535, fixes #482)
- Front, side and top views, and F5/F6 switch between perspective and orthographic (PR #539, part of #241)
- Textures export as DDS, with compressed normal and grayscale maps for game engines (PR #543, fixes #354)
- The active layer and the eye in the Layers panel are much easier to see (PR #561, fixes #553)
- Export dialog can also write a MaterialX file for each texture set (PR #563, fixes #558)
- Layers toolbar stays on one row and cut-off layer names show on hover in small windows (PR #564, fixes #560)
- Save a layer's mask as an image file or copy it to the clipboard from the layer menu (PR #565, fixes #559)
- Shift + wheel and Ctrl + wheel change the brush size, and Ctrl+drag brush changes have a fine mode (PR #566, part of #545)
- Select several layers in the Layers panel with Shift+click, Ctrl+click and Ctrl+A (PR #567, fixes #247)
- Pressing F frames the object you are painting, so a floor plane no longer throws off the view (PR #568, fixes #478)
- Save a mask as your own smart mask and reuse it on other layers and projects (PR #569, fixes #562)
- Show one layer alone in the viewport, with or without its mask (PR #570, fixes #544)
- On-screen orbit, pan and zoom buttons let a pen tablet move the 3D and 2D views (PR #573, fixes #288)
- Decals can be mirrored to the opposite side of the mesh across X, Y or Z, with optional U or V flip (PR #576, fixes #272)
- Shift+click lines in the 3D view start at the spot you last painted, even after turning the view (PR #578, fixes #574)
- History steps now name the tool and layer and appear in the interface language (PR #580, fixes #572)
- Path tool keeps your points when you click in the other view and tells you why (PR #582, fixes #575)
- Brush, symmetry and tool settings stay when you open another project or restart the app (PR #584, fixes #571)
- Reset only the panel layout from the Window menu, and Reset UI now asks first (PR #586, fixes #577)
- Output templates ask before deleting and before dropping an unfinished edit (PR #588, fixes #579)
- Clone tool shows its source in the 2D view, forgets it when you switch texture set, and can restart at the source each stroke (PR #590, fixes #581)
- Move the symmetry plane to the model's middle or to a clicked point in one click (PR #591, fixes #585)
- Projection stencil can be dropped in from Assets, moved and reset with fields, turned in snapped steps, and the 2D view says projection works in 3D (PR #593, fixes #583)
- Smudge now shows which channels it drags and lets you switch them (PR #594, fixes #587)
- Save panel layouts under a name and switch between them from the Window menu (PR #595, fixes #589)
- Clone and Smudge now work on layer masks (PR #596, fixes #592)
- A layer image menu test no longer fails when another test switches the interface language (PR #597)
- Clicking a material in the shelf now paints with it instead of adding a layer (PR #599, fixes #305)
- Alt+click on a mask thumbnail now labels the mask view and blanks the other texture sets (PR #605, fixes #600)
- Painting on a texture set that is not active now shows a hint why nothing happens (PR #607, fixes #601)
- Ctrl+Shift+click draws straight lines that snap to 15 degree steps (PR #609, fixes #604)
- Output template channels can be inverted (PR #611, fixes #603)
- Smudge now follows the mirror and radial symmetry planes (PR #613, fixes #602)
- The shortcut list now shows the stencil, clone source, straight line and path gestures (PR #614, fixes #608)
- Symmetry now also mirrors strokes painted in the 2D view (PR #615, fixes #610)
- Decals keep their image's proportions while sizing and can be flipped (PR #617, fixes #606)
- Polygon fill now also fills the mirrored side when symmetry is on (PR #619, fixes #612)
- A decal dragged over a curved or differently facing surface now turns with it instead of tilting or flipping (PR #622, fixes #616)
- Every brush alpha now has size, roundness, contrast and invert settings (PR #623, part of #598)
- Decals placed as a mask can now be sized, turned and moved from Properties like decal layers (PR #624, fixes #618)
- Renaming effects and linking fills to mask anchor points are now tested in the interface (PR #626, fixes #621)
- Path points can be corners, so paths can have hard edges (PR #627, fixes #620)
- Layer menu can apply a layer's blending mode and opacity to all channels, and copy/paste channel blending (PR #631, fixes #629)
- Display Settings can now set glow, vignette, sharpen and film grain (PR #632, fixes #630)
- Every command a key can run can now get a keyboard shortcut (PR #633, fixes #628)

Fixes found while combining them: the named layouts window is drawn again, layer remove/duplicate/group/visibility stay bindable to keys, the Clone tool's Aligned switch is kept with the other tool settings, smudge copies in the 2D view keep their own trails, and a UI or control-channel camera command during a view glide is no longer undone by the glide.
2026-11-17 22:51:06 +01:00
Rebornim d858fdba36 Pattern edits take the seed with tile settings, a uniform pick outranks them, gray rows take a typed value, the output size follows the UV tiles 2026-11-17 16:27:46 +00:00
Rebornim 7c28d4f5f5 Tile Generator image inputs
The Custom image input shape draws one of the pattern's input images in each tile, picked at random or by tile number, through the shape's tiling, angle, scale and turns; the background image shows under the shapes instead of the background value. Patterns read images through a PatternContext (its resolution and the image resources), which the compositor passes; procedural() keeps evaluating without images.
2026-11-17 16:27:37 +00:00
Rebornim 37edd3c44b Tile Generator pattern and pattern resolution
A Tile Generator pattern kind lays shapes out in a grid of tiles: 15 shapes and image inputs, tile counts, row or column offset, middle size, interstice, size modes, scale, free and quarter-turn rotation, mirroring, per-tile random scale, position, rotation and luminance, masks, Add/Max/Add sub blending, background, opacity and a position/contrast window. Its settings are a TileGenerator on Procedural (saved only for that kind).

Every pattern gets an output resolution like generators: below the UV tile's resolution it is read from an image of that size, bilinearly. Patterns saved before keep their form and render unchanged.
2026-11-17 16:26:06 +00:00
chasse20 009bb0c4d1 Merge remote-tracking branch 'origin/main' into HEAD 2026-11-17 16:22:03 +00:00
chasse20 f8a202c77a Auto: Expand painting and baking workflows and integrate main
Add configurable mesh-map baking, cage previews, polygon fill, path editing, symmetry controls, generator settings, and material previews. Update shelf, docking, project configuration, localization, and UI persistence.

Update mesh import, project loading and recovery, rendering, compositing, and painting. Expand regression tests and benchmarks, refresh dependencies and documentation, and incorporate CI, updater, and packaging changes.
2026-11-17 08:40:45 +00:00
chasse20 55120d3ae4 Merge latest main into CPR 13 preserving reviewed repairs 2026-11-17 08:19:56 +00:00
chasse20 c5f7f17380 Auto: Preserve HDR fills and adapt benchmarks to main
Integrate main and adapt the performance suite to current bake settings,
map selection and undo APIs.

Preserve full triplanar image weighting for floating-point resources and
add a regression for lost HDR contributions. Use hardware floor when
SSE4.1 is enabled, retaining the portable fallback.

Split Report and Row into their own files and complete scoped naming,
spacing and comment cleanup.

Validated with 132 release tests, workspace Clippy, wasm and layering
checks, formatting, and retained targeted noise and performance probes.
2026-11-17 07:57:09 +00:00
Chris Hassebrook b2c7806961 Merge pull request #437 from subtilicus/fix/viewport-normal-precision
Keep baked normals above 8 bits in the viewport
2026-11-17 02:46:08 -05:00
chasse20 071d410d8a Auto: Integrate main and harden half-float normal display
Preserve signed RGBA16F normal uploads while integrating current main.
Reject invalid baked samples before blending, skip sampling absent baked
normal maps, and cover two-set normal shading with a headless test.

Complete scoped spacing, comment and shader constant cleanup while
preserving shader values.
2026-11-17 06:42:03 +00:00
chasse20 22742ce173 Auto: Integrate latest main with tile-aware recomposition 2026-11-17 06:39:06 +00:00
chasse20 ff4c285b1d Auto: Integrate main and preserve tile-aware invalidation 2026-11-17 06:32:23 +00:00
chasse20 379288e8c3 Merge current main into PR #226 2026-11-17 06:20:17 +00:00
chasse20 efaff5e13e Merge main into PR #226 and preserve reviewed fixes 2026-11-17 06:10:52 +00:00
Morion 920438c73b Merge latest main and retain rewritten roadmap audit 2026-11-17 00:32:18 -05:00
chasse20 f10d92b997 Auto: Respect curvature modes and filter inherited anchor choices
Combine micro height with edge and cavity responses before mode selection. Build inherited-effect Fill and micro-detail anchor choices from the effect owner. Add focused regressions for both behaviors.
2026-11-17 03:56:18 +00:00
chasse20 fd4b06c3e5 Auto: Integrate main and preserve filtered mask anchor values
Retain intermediate filter stages needed by mask anchors, with measured
buffer capacity and release checks. Preserve main's generator and layer
controls while fixing instance-owner validation, micro defaults, inactive
anchor labels, and clipboard dependency reporting. Move MicroDetail into
its own module and complete scoped cleanup.

Validated affected release suites, Clippy, wasm, layering, formatting,
panic_hunt, and the final diff.
2026-11-17 02:55:37 +00:00
Morion 101206b9cd Merge main into geometric pattern additions 2026-11-16 12:37:57 -05:00
chasse20 442edf310a Auto: Integrate main and preserve generator review repairs 2026-11-15 19:26:39 +00:00
chasse20 6825aac7e4 Auto: Integrate main and reduce compositor buffer lifetimes
Preserve filter lookahead alongside main image-cache invalidation and input
bounds. Move HeldFields into its own module and finish scoped cleanup.
Charge repeated USD path names before allocating retained strings.
Reuse the blur transpose-back buffer and release scattered texels before
allocating filter temporaries.

Validated compose/engine release tests, Clippy, layering, wasm and formatting.
2026-11-15 07:14:57 +00:00
chasse20 7bfcf3fc27 Auto: Integrate main and reuse decoded material maps
Preserve main's decoder, atomic-save, material-payload, and USDC limits.
Bound material reads by the remaining payload budget and trim retained
buffers. Replace quadratic image-name searches with map lookups, and
cache validated linked-material maps before synchronization so they
are not decoded twice.

Add import/undo/redo and payload-boundary regressions, extract
ImageIdentity, remove the unchecked scratch example, and complete
scoped cleanup. Correct the integrated style guide's product name.

Validated 546 release tests, Clippy, layering, wasm, formatting, and
focused allocation and lifetime probes.
2026-11-15 04:16:43 +00:00
Morion 74d213272d Release kept filter fields when a stroke begins during a sliced pass (#475)
Fields kept for the coming composites stayed allocated for as long as a
stroke lasted while tiles still followed, because the end-of-pass cleanup only
runs when none do. A stroke already kept them from being used; now it also
drops them. The test keeps fields first, then starts the stroke.
2026-11-13 14:20:27 -05:00
Morion 1a742d3fa4 Frame-sliced recomposites filter a run of tiles once (#475)
A stack with a neighbourhood filter (blur, high pass, bevel, glow...) made a
recomposite spread over frames many times slower than the same recomposite in
one call: every chunk filtered its own surroundings again, and on a machine
with many threads the filter's per-texel parallel steps cost more to hand out
than to run on a region of a few tiles.

- Neighbourhood filters split their per-texel work into tasks of at least
  16384 texels. Each texel is computed on its own, so results do not change.
- Session::update_for tells the compositor which dirty tiles follow the chunk
  in its block (up to 64). The compositor filters the chunk and those tiles at
  once and keeps the fields for the composites that follow, compared by
  everything the stack reads, and drops them at the end of the pass, after an
  edit, and under a live stroke.

Results are identical to the one-call composite: tests cover cold, warm and
partly evicted hot-layer caches, an edit mid-pass and a live stroke.
perf::bench_sliced_filters_4k times both paths.
2026-11-13 12:38:58 -05:00
Morion d5675e090b Keep cached layer composites across unrelated image imports 2026-11-13 09:38:39 -05:00
Morion Tutoriales b982d66008 fix(compose): retain curvature cache layout variants (#459) 2026-11-13 08:28:43 +01:00
Subtilicus f32e4ea7f0 Keep baked normals above 8 bits in the viewport
The viewport's Normal display texture was RGBA8, so baked normals (stored
as f32) were quantised to 8 bits per axis before shading. On smooth,
mirror-like materials this showed as banding. The texture is now RGBA16F
holding the signed normal (flat is exactly +z), as Height already does;
the raster and GPU path-tracing shaders read it directly.
2026-11-12 10:23:09 +01:00
Rebornim 7bd6c0ef2b Generators: global adjustments, output resolution and image inputs
- Global blur, balance and contrast on every generator (GeneratorGlobal).
  The blur blurs only the generator's own value, up to a 64-texel radius
  at 2K, weighted by mesh coverage; balance picks the input range that is
  stretched to 0..1 and contrast narrows it; invert stays last.
- Output resolution (OutputResolution, ResolutionMode): Auto or UV tile,
  Texture set or a custom size, times a factor from 1/8 to x8, never
  coarser than one value per 64 texels. Below the UV tile's resolution
  the generator is averaged over cells and read back bilinearly.
- Image inputs: each mesh map a generator reads can read an image, a
  uniform value or an anchor point instead. Generator inputs count as
  anchor and image readers (compositing order, paste, remove unused).
- Blur and resolution run as a neighbourhood stage of the mask, listed
  the same way by every caller and only in masks.
- Commands: blur, balance, contrast, resolution, customResolution,
  resolutionFactor on effect.add.generator / effect.set, and input with
  inputImage / inputValue / inputAnchor / inputBaked on effect.set.

New fields are skipped when they hold their defaults and neutral settings
return the value untouched, so saved projects load, save and render as
before.
2026-11-12 04:39:32 +00:00
Morion dd82b923f2 Merge origin/main into feat/procedural-geometric-tilings
The translation tables this branch extended were replaced by the shared craft-i18n catalogs (#427), so the labels of the six new patterns stay English strings through tr() and their translations belong in a craft-i18n PR.
2026-11-11 23:21:55 -05:00
BFlat b1806e4010 Merge pull request #231 from vangel76/fix/217-generator-offset
Add an offset slider to mesh-map generators
2026-11-12 08:52:04 +07:00
Morion a1fd0120c3 Geometric tilings: take extreme coordinates; halftone dots stay continuous
Review findings on #421:

- A huge but finite coordinate saturated a cell index to i32::MAX, and the
  next neighbour index overflowed, which panics in debug builds; an infinite
  one gave NaN. As the six tilings repeat every unit, each now first moves
  the point into the unit square, which also keeps far coordinates precise.
  Coordinates that are not finite become 0.
- Halftone dots picked a single center by rounding, so on the line halfway
  between two centers the dot jumped from one size to the other. Each texel
  now takes the dot that covers it most among the four nearest centers, and
  skips the tone of centers no dot could reach from there.

New tests feed extreme coordinates to every tiling and check that the
halftone has no jump where two dots meet; both fail without the change.
Halftone dots now take about 97 ns per texel in release.

Part of #409
2026-11-11 10:48:34 -05:00
Morion f7a7c11de4 Procedural patterns: halftone dots, diamond brocade and Truchet arcs
Three more geometric tilings:

- Halftone dots: dots on a grid turned 45 degrees, sized by a cloudy tone.
- Diamond brocade: raised diamonds of concentric rings on a twill ground.
- Truchet arcs: quarter-circle arcs that join into winding paths.

The halftone tone comes from a new value noise whose lattice indices wrap,
summed over octaves with a whole number of cells per unit, so the noise and
the dots repeat every unit. All six tilings are now in the seamless test.
Their labels are added to the nine translation tables. In release they take
38 to 85 ns per texel.

Part of #409
2026-11-11 09:44:11 -05:00
Morion 9378d2fe11 Procedural patterns: hexagon tiles, wave scales and herringbone planks
Fills and masks had few geometric tilings. Three new procedurals, generated
in code like the others:

- Hexagon tiles: hexagons with joints and a tone per tile.
- Wave scales: rows of overlapping fans of concentric arcs.
- Herringbone planks: planks three times as long as wide, with gaps, a tone
  and a grain per plank.

Each repeats every unit, tones included, so it tiles without seams; a test
checks that, and another one the joints between hexagons and planks. Their
labels are added to the nine translation tables. In release they take 43 to
62 ns per texel, like Bricks and Twill.

Part of #409
2026-11-11 09:17:14 -05:00
chasse20 77a03ddcb3 Merge main and fix decal placement and input handling 2026-11-10 18:29:43 -05:00
Rafael Mendes 10aaae2f51 Merge main: rename editor in the redesigned effect rows 2026-11-10 18:32:29 -03:00
Chris Hassebrook d664dc239c Revert "Show a whole material at once: coarse first look, then the exact result" 2026-11-10 16:08:27 -05:00
Chris Hassebrook 783cbdcb27 Merge pull request #381 from SteamSmith/perf/material-loading
Show a whole material at once: coarse first look, then the exact result
2026-11-10 16:07:09 -05:00
Rafael Mendes 732f6bae28 Anchor points in masks, generator micro detail, effect rename
Anchor point effects can now sit in a mask, where they record the mask
value at their place for fills and generators above. Generators take an
anchor's height as micro detail (microAnchor, microAmount). Effects can
be renamed from the Layers panel, and the anchor picker lists anchors
under their own heading.

Closes #389
2026-11-10 17:52:26 -03:00
FredApps 26ddc8c256 Merge main and keep nested thumbnail controls accessible 2026-11-10 20:10:52 +01:00
SteamSmithandClaude Sonnet 5.5 208c645d0c Show a whole material at once: coarse first look, then the exact result
Applying a material filled the model in tile by tile, and each apply made the
next one slower. Now:
- a big recomposite first draws a coarse look of every tile (sampled texels
  repeated across blocks), then refines to the exact result;
- layers hidden behind an opaque layer are skipped (not when anchors or height
  masks are involved);
- compositing and upload budgets adapt: larger when idle, smaller while the
  user is interacting, and uploads reserve time for conversion;
- no coarse pass during a live stroke or with neighbourhood filters;
- blending at full weight returns the blended value exactly.

Tests: coarse-then-exact, hidden-layer culling gives identical pixels, coarse
pass covers every tile, no coarse pass while a stroke is live.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-10 06:40:11 -05:00