-
Notifications
You must be signed in to change notification settings - Fork 408
Type description improvements #2176
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
jstone-lucasfilm
merged 45 commits into
AcademySoftwareFoundation:main
from
niklasharrysson:typedesc_updates
Feb 18, 2025
Merged
Changes from 26 commits
Commits
Show all changes
45 commits
Select commit
Hold shift + click to select a range
8f59b0e
Use single data block pointer to store TypeDesc large data
niklasharrysson 65d5061
Refactor TypeDesc handling for struct types
niklasharrysson 4fc277e
Fix python errors
niklasharrysson 97b56a1
Fix GraphEditor build error
niklasharrysson f97390d
Fix Mac build error
niklasharrysson 4fee5be
Fix test failure
niklasharrysson 0cf5ab8
Fix more test failues
niklasharrysson 1b6ffa0
Fix more test failures
niklasharrysson da3e39f
Fix python test errors
niklasharrysson 48a8ea2
Fix more test failures.
niklasharrysson 00ed265
Add TypeSystem class to hold and handle registered types.
niklasharrysson 8855f4c
Code cleanup
niklasharrysson 1335d86
Fix link error
niklasharrysson 1c77a46
Add struct unit tests from Lee
niklasharrysson b0c5861
Fix python test failure
niklasharrysson d9e9df2
Fix python unit tests - v2
niklasharrysson adbe61b
Small cleanup
niklasharrysson 608b6df
Handling of re-registration of types
niklasharrysson 45b04fc
Merge remote-tracking branch 'aswf/main' into typedesc_updates
niklasharrysson b8450a6
Improve documentation
niklasharrysson 6904889
Small documentation fix.
niklasharrysson 6d730cb
Merge branch 'main' into typedesc_updates
jstone-lucasfilm 69c75c7
Merge branch 'main' into typedesc_updates
jstone-lucasfilm 4e91629
Minor spacing fix
jstone-lucasfilm 3e77211
Streamline example
jstone-lucasfilm d73b1b5
Streamline example
jstone-lucasfilm 6683180
Update to shader generator constructors
niklasharrysson fc28ec7
Fix python wrappers
niklasharrysson d70d7f4
Attempt to fix JS bindings
niklasharrysson 4d3e63e
Update JS bindings to use shader generator create functiions
niklasharrysson bb5ba27
Attempt to fix JS bindings
niklasharrysson 7eb06a5
More fixes to JS bindings
niklasharrysson b7110a3
More fixes to JS code
niklasharrysson f665c50
Simplify shader generator create functions
niklasharrysson 8db9000
Attempt to fix the JS bindings
niklasharrysson 3e4a256
Merge branch 'main' into typedesc_updates
jstone-lucasfilm 9cb1f38
Restore TypeSystemPtr argument
jstone-lucasfilm 2856137
Fix typo
jstone-lucasfilm 12e6f28
Add new TypeDesc argument
jstone-lucasfilm 1dacfb8
Simplify python wrappers for shader generator construction
niklasharrysson aeeb613
Attempt to fix JS bindings
niklasharrysson 5587773
Attempt to fix JS bindings
niklasharrysson 902d1fb
Merge branch 'main' into typedesc_updates
jstone-lucasfilm fbda1d2
Merge branch 'main' into typedesc_updates
jstone-lucasfilm c7a3eaf
Update sheen node
jstone-lucasfilm File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 30 additions & 0 deletions
30
resources/Materials/TestSuite/stdlib/structs/struct_texcoord.mtlx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,30 @@ | ||
| <?xml version="1.0"?> | ||
| <materialx version="1.39"> | ||
|
|
||
| <typedef name="texcoord_struct"> | ||
| <member name="ss" type="float" value="0.5"/> | ||
| <member name="tt" type="float" value="0.5"/> | ||
| </typedef> | ||
|
|
||
| <nodedef name="ND_extract_s_texcoord" node="extract_s" nodegroup="shader" > | ||
| <input name="in" type="texcoord_struct" value="{0.1;0.1}" /> | ||
| <output name="out" type="float" value="0.0" /> | ||
| </nodedef> | ||
|
|
||
| <implementation name="IM_extract_s_texcoord_genglsl" nodedef="ND_extract_s_texcoord" target="genglsl" sourcecode="{{in}}.ss" /> | ||
| <implementation name="IM_extract_s_texcoord_genmsl" nodedef="ND_extract_s_texcoord" target="genmsl" sourcecode="{{in}}.ss" /> | ||
| <implementation name="IM_extract_s_texcoord_genosl" nodedef="ND_extract_s_texcoord" target="genosl" sourcecode="{{in}}.ss" /> | ||
| <implementation name="IM_extract_s_texcoord_genmdl" nodedef="ND_extract_s_texcoord" target="genmdl" sourcecode="{{in}}.ss" /> | ||
|
|
||
| <extract_s name="extract" type="float"> | ||
| <input name="in" type="texcoord_struct" value="{0.01;0.5}"/> | ||
| </extract_s> | ||
| <surface_unlit name="unlit_surface1" type="surfaceshader"> | ||
| <input name="emission" type="float" nodename="extract" /> | ||
| <input name="opacity" type="float" value="1.0" /> | ||
| </surface_unlit> | ||
| <surfacematerial name="test_struct_texcoord" type="material"> | ||
| <input name="surfaceshader" type="surfaceshader" nodename="unlit_surface1" /> | ||
| </surfacematerial> | ||
|
|
||
| </materialx> |
43 changes: 43 additions & 0 deletions
43
resources/Materials/TestSuite/stdlib/structs/struct_texcoordGroup.mtlx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,43 @@ | ||
| <?xml version="1.0"?> | ||
| <materialx version="1.38"> | ||
|
|
||
| <typedef name="texcoord_struct"> | ||
| <member name="ss" type="float" value="0.5"/> | ||
| <member name="tt" type="float" value="0.5"/> | ||
| </typedef> | ||
| <typedef name="texcoordGroup_struct"> | ||
| <member name="st_0" type="texcoord_struct" value="{0.1;0.1}"/> | ||
| <member name="st_1" type="texcoord_struct" value="{0.5;0.5}"/> | ||
| <member name="st_2" type="texcoord_struct" value="{0.9;0.9}"/> | ||
| </typedef> | ||
|
|
||
| <nodedef name="ND_extract_first_s_texcoordGroup" node="extract_first_s_group" nodegroup="shader" > | ||
| <input name="in" type="texcoordGroup_struct" value="{{0.1;0.2};{0.3;0.4};{0.5;0.6}}"/> | ||
| <output name="out" type="float" value="0.0" /> | ||
| </nodedef> | ||
|
|
||
| <implementation name="IM_extract_first_s_texcoordGroup_genglsl" nodedef="ND_extract_first_s_texcoordGroup" target="genglsl" sourcecode="{{in}}.st_0.ss"> | ||
| <input name="in" type="texcoordGroup_struct" implname="data" /> | ||
| </implementation> | ||
| <implementation name="IM_extract_first_s_texcoordGroup_genmdl" nodedef="ND_extract_first_s_texcoordGroup" target="genmdl" sourcecode="{{in}}.st_0.ss"> | ||
| <input name="in" type="texcoordGroup_struct" implname="data" /> | ||
| </implementation> | ||
| <implementation name="IM_extract_first_s_texcoordGroup_genmsl" nodedef="ND_extract_first_s_texcoordGroup" target="genmsl" sourcecode="{{in}}.st_0.ss"> | ||
| <input name="in" type="texcoordGroup_struct" implname="data" /> | ||
| </implementation> | ||
| <implementation name="IM_extract_first_s_texcoordGroup_genosl" nodedef="ND_extract_first_s_texcoordGroup" target="genosl" sourcecode="{{in}}.st_0.ss"> | ||
| <input name="in" type="texcoordGroup_struct" implname="data" /> | ||
| </implementation> | ||
|
|
||
| <extract_first_s_group name="extractfirstsgroup" type="float"> | ||
| <input name="in" type="texcoordGroup_struct" value="{{0.1;0.2};{0.3;0.4};{0.5;0.6}}"/> | ||
| </extract_first_s_group> | ||
| <surface_unlit name="unlit_surface1" type="surfaceshader"> | ||
| <input name="emission" type="float" nodename="extractfirstsgroup" /> | ||
| <input name="opacity" type="float" value="1.0" /> | ||
| </surface_unlit> | ||
| <surfacematerial name="test_struct_texcoordGroup" type="material"> | ||
| <input name="surfaceshader" type="surfaceshader" nodename="unlit_surface1" /> | ||
| </surfacematerial> | ||
|
|
||
| </materialx> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.