-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
HdMtlxCreateMtlxDocumentFromHdNetwork should copy colorSpace metadata back to MaterialX #1523
Comments
Hi there, @JGamache-autodesk, |
Filed as internal issue #USD-6703 |
Hi - we're dealing with some fallout from this failure to roundtrip MaterialX colorspace information as well. Are there any updates? If not - @spiffmon, can you provide some clarification on how fixing Until / unless you decide to revert that decision (and make usdMtlx NOT author colorSpace in USD), I feel the right thing to do is make From a larger perspective... it's a recurring pattern where we have questions of how to deal with non-homogeneous or poorly formatted input data. Frequently, there's a way to automatically correct it at runtime, but it has performance implications. So in an environment where you can enforce quality control and homogenization on input data (ie, a studio environment), implementing such automatic runtime fixes has little benefit and tangible downside. I think we could start adopting the general pattern of having an auto-fix system that can be disabled via an option somehow, accompanied with checks for situations that would require the fix. ie, in this situation, we could add the option to do per-attribute colorspace handling, which is on by default. Studio environments that can ensure input colorspaces are consistent can disable colorspace correctives, and still get the maximum performance. And we add in a validation that there are either no declared colorspaces, or that they have the "expected" value. (The validation isn't really required, but would be nice!) As for renderers - they can declare whether or not they support colorspace correctives (and we can optionally run validations if they don't.) Thoughts? |
Hi @pmolodo , thanks for your patience... the MaterialX community has been patiently waiting for this for some years now. The good news is that we're prioritizing colorSpace work, and expect to start early in the new year. Some of our thoughts about it:
|
Description of Issue
Trying to update the MayaUsdPlugin Hydra render delegate to support MaterialX via hdMtlx. Everything works very well, but final render does not have the right color space for input textures.
Steps to Reproduce
colorspace="srgb_texture"
declarations.colorSpace = "srgb_texture"
metadata.MaterialXSampler.zip
, and dump the MaterialX document generated by HdMtlxCreateMtlxDocumentFromHdNetwork. You will notice that the colorspace was not added back to the tiledimage node:
<input name="file" type="filename" value="Images\brass_color.jpg" />
Separate question: A procedural material example was added recently to MaterialX and fails conversion via UsdMtlx._TestFile( ): MaterialX/resources/Materials/Examples/StandardSurface/standard_surface_brick_procedural.mtlx
This is possibly due to the usage of an inlined node definition. Will this be a supported workflow?
System Information (OS, Hardware)
Windows 10, x86_64.
Package Versions
USD: tip of dev branch
MaterialX: tip Autodesk adsk_contrib/dev branch, with lighting update PR not yet merged.
Build Flags
-DCMAKE_INSTALL_PREFIX=E:/Ws/UsdBuild/PixarUSD/install
-G Ninja
-DCMAKE_BUILD_TYPE=RelWithDebInfo
-DCMAKE_TOOLCHAIN_FILE=c:\ws\vcpkg2019\scripts\buildsystems\vcpkg.cmake
-DMATERIALX_ROOT=e:\Ws\UsdBuild\MaterialX\install
-DPXR_BUILD_OPENIMAGEIO_PLUGIN=TRUE
-DPXR_BUILD_OPENCOLORIO_PLUGIN=TRUE
-DPXR_BUILD_ALEMBIC_PLUGIN=TRUE
-DPXR_ENABLE_MATERIALX_SUPPORT=TRUE
-DTBB_USE_DEBUG_BUILD=OFF
The text was updated successfully, but these errors were encountered: