Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,10 @@ Some initial utilities are provided with more coming on-line as the site / requi
attempt to produce valid USD shading network (See Support Utilities)
- Input geometry (USD file)
- Input camera (USD file)
- Skydome like (A latlong HDR file)
- Skydome light (A latlong HDR file)
- Perform USD validation
- Export just the materials to a USD file.
- Render the corresponding USD file. This uses `usdrecord` currently.
- Render the corresponding USD file. This uses `usdrecord` currently. Render arguments can be passed in to specify the render delegate to use for instance. The default is GL.
- Misc options for output for test
suite compatibility:
- Use material name for file name
Expand Down
Binary file not shown.
4 changes: 2 additions & 2 deletions documents/html/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -126,10 +126,10 @@ <h2><a class="anchor" id="autotoc_md1"></a>
<li>Preprocess the MaterialX file to attempt to produce valid USD shading network (See Support Utilities)</li>
<li>Input geometry (USD file)</li>
<li>Input camera (USD file)</li>
<li>Skydome like (A latlong HDR file)</li>
<li>Skydome light (A latlong HDR file)</li>
<li>Perform USD validation</li>
<li>Export just the materials to a USD file.</li>
<li>Render the corresponding USD file. This uses <code>usdrecord</code> currently.</li>
<li>Render the corresponding USD file. This uses <code>usdrecord</code> currently. Render arguments can be passed in to specify the render delegate to use for instance. The default is GL.</li>
<li>Misc options for output for test suite compatibility:<ul>
<li>Use material name for file name</li>
<li>Create in subfolder with name being the input MaterialX name</li>
Expand Down
444 changes: 224 additions & 220 deletions documents/html/mtlx2usd_8py_source.html

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -125,10 +125,10 @@ <h3>Available Components</h3>
attempt to produce valid USD shading network (See Support Utilities)</li>
<li>Input geometry (USD file)</li>
<li>Input camera (USD file)</li>
<li>Skydome like (A latlong HDR file)</li>
<li>Skydome light (A latlong HDR file)</li>
<li>Perform USD validation</li>
<li>Export just the materials to a USD file.</li>
<li>Render the corresponding USD file. This uses <code>usdrecord</code> currently.</li>
<li>Render the corresponding USD file. This uses <code>usdrecord</code> currently. Render arguments can be passed in to specify the render delegate to use for instance. The default is GL. </li>
<li>Misc options for output for test
suite compatibility:<ul>
<li>Use material name for file name</li>
Expand Down
4 changes: 4 additions & 0 deletions source/materialxusd/mtlx2usd.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ def main():
parser.add_argument("-sf", "--subfolder", action="store_true", help="Save output to subfolder named <input materialx file> w/o extension.")
parser.add_argument("-pp", "--preprocess", action="store_true", help="Attempt to pre-process the MaterialX file.")
parser.add_argument("-ip", "--imagepaths", default="", help="Comma separated list of search paths for image path resolving. ")
parser.add_argument("-ra", "--renderargs", default="", help="Additional render arguments.")

# Parse arguments
args = parser.parse_args()
Expand Down Expand Up @@ -263,6 +264,9 @@ def main():
if camera_prim:
render_command += f' --camera "{camera_prim.GetName()}"'
logger.info(f"> Rendering using command: {render_command}")
if args.renderargs:
render_command += f' {args.renderargs}'
print('>'*20, render_command)
sys.stdout.flush()
os.system(f"{render_command} > nul 2>&1" if os.name == "nt" else f"{render_command} > /dev/null 2>&1")
#os.system(render_command)
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.