Comments (6)
Shouldn't we be tagging the inputs accordingly based on the spec otherwise this is very "brittle" ?
from materialx.
Definitely. I was not aware of the hint
metadata until you pointed it to me. This is going to solve many issues.
from materialx.
I don't see any new code in isTransparentShaderNode() that uses those hints though. And none of the surfaces in bxdf
use the new spec. I guess the feature did not make it in 1.39.1.
from materialx.
I guess not.
I'd suggest the following interface changes:
- Add a
Input.hasTransparencyHint()
and / orInput.hasOpaqueHint()
and setters for completeness. - Add a
Node.getOpaqueHintList()
on the node which can scan using methods in 1. to build a "opaque comparison" dictionary. - Call
getOpaqueHintList()
when testing
from materialx.
Looks very good. Adding a bit of caching at the NodeDef level would help to make sure we do not rescan the list of inputs every time looking for the ones with hints.
from materialx.
I did not add in caching to keep this the logic for generic "hint" accessors and the transparency checking logic localized in the util.
from materialx.
Related Issues (20)
- Add implementation of `updirection` node HOT 1
- Graph Editor: Reproducible crash after renaming node HOT 2
- Regression: Top level inputs not working in code generation
- Graph Editor ImGui Delete Key
- Investigate removing the installation of 'resources' for MaterialXGenShader module HOT 1
- Investigate moving MDL library source to 'libraries' folder
- Graph Editor: Reproducible crash after copying node and connect in certain ways
- State of Material Inherits HOT 14
- Suggestion: provide string constants for all types HOT 1
- Update the glTF PBR implementation to support thin-walledness
- Crash when loading / viewing an existing nodegraph into graph editor - related to swizzle node upgrade process HOT 8
- libMaterialXFormat exports pugixml symbols HOT 8
- Add reference thumbnail images for the spec docs
- MDL shader uniform block reflection inconsistency
- Instructions for running MaterialXGraphEditor on Mac HOT 4
- Proposal: Migrate comment documentation to nodedef doc attributes for std libraries HOT 2
- MaterialXGraphViewer: `time_float` and `frame_float` do not have any effect HOT 3
- GLSL ShaderGen: `time_float` and `frame_float` do not have any effect HOT 6
- Proposal: MaterialX Hair BSDF
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from materialx.