Skip to content

feat(proc): UsdProc GenerativeProcedural#97

Open
bresilla wants to merge 1 commit into
mxpv:mainfrom
bresilla:feat/proc
Open

feat(proc): UsdProc GenerativeProcedural#97
bresilla wants to merge 1 commit into
mxpv:mainfrom
bresilla:feat/proc

Conversation

@bresilla
Copy link
Copy Markdown
Contributor

@bresilla bresilla commented Jun 1, 2026

Adds UsdProc behind a proc feature - GenerativeProcedural reader + authoring (proceduralSystem). It inherits Boundable, so transform/extent/visibility come from the UsdGeom layer, and its input parameters live in the primvars: namespace.

Hand-authored fixture + in-memory roundtrip.

Copilot AI review requested due to automatic review settings June 1, 2026 11:19
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Note

Copilot was unable to run its full agentic suite in this review.

Adds initial UsdProc schema support (reader + authoring) behind a new proc feature, plus tests and a fixture to validate GenerativeProcedural parsing/roundtripping.

Changes:

  • Introduce schemas::proc module with tokens, reader, types, and authoring helper for GenerativeProcedural (proceduralSystem).
  • Add unit + integration tests plus a USDA fixture scene.
  • Wire up the proc Cargo feature and test gating; update schema docs/roadmap.

Reviewed changes

Copilot reviewed 10 out of 10 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
tests/proc_reader.rs Adds an integration test that opens a USDA fixture and validates GenerativeProcedural reading.
src/schemas/proc/types.rs Defines the read-model struct for decoded GenerativeProcedural attributes.
src/schemas/proc/tokens.rs Adds schema token constants for prim/attribute names.
src/schemas/proc/read.rs Implements the GenerativeProcedural reader and token-value extraction.
src/schemas/proc/mod.rs Exposes the proc module API and adds unit tests for roundtrip and type gating.
src/schemas/proc/author.rs Implements authoring helpers for defining prims and setting proceduralSystem.
src/schemas/mod.rs Registers the proc module behind a new feature flag and documents it.
fixtures/usdProc_scene.usda Adds a real fixture used by integration tests.
ROADMAP.md Marks UsdProc as implemented and documents scope.
Cargo.toml Adds proc feature and a feature-gated integration test target.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread tests/proc_reader.rs
use openusd::sdf;
use openusd::usd::Stage;

const FIXTURE: &str = "fixtures/usdProc_scene.usda";
Comment thread tests/proc_reader.rs

#[test]
fn reads_generative_procedural_from_fixture() -> Result<()> {
let stage = Stage::open(FIXTURE)?;
Comment thread tests/proc_reader.rs
#[test]
fn reads_generative_procedural_from_fixture() -> Result<()> {
let stage = Stage::open(FIXTURE)?;
let p = read_generative_procedural(&stage, &sdf::path("/World/Scatter")?)?.expect("GenerativeProcedural");
Comment thread src/schemas/proc/mod.rs
let stage = Stage::builder().in_memory("anon.usda")?;
define_generative_procedural(&stage, sdf::path("/World/Proc")?)?.set_procedural_system("Houdini")?;

let p = read_generative_procedural(&stage, &sdf::path("/World/Proc")?)?.expect("GenerativeProcedural");
Comment thread src/schemas/proc/mod.rs
let stage = Stage::builder().in_memory("anon.usda")?;
define_generative_procedural(&stage, sdf::path("/Proc")?)?;

let p = read_generative_procedural(&stage, &sdf::path("/Proc")?)?.expect("GenerativeProcedural");
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