omni.flux.utils.material_converter#
This is a simple utility to convert materials from a given shader to another shader.
SPDX-FileCopyrightText: Copyright (c) 2024 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
SPDX-License-Identifier: Apache-2.0
Licensed under the Apache License, Version 2.0 (the “License”);
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an “AS IS” BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
- class omni.flux.utils.material_converter.MaterialConverterCore#
Bases:
object
- async static convert(
- context_name: str,
- converter: ConverterBase,
Convert the material
- Parameters:
context_name – the context to use
converter – the converter to use
- Returns:
Success, message, skipped or not
- async static find_matching_supported_material(
- input_shader_prim: Usd.Prim,
Find the matching supported material from all inputs. It can happen that inside a MDL, a supported MDL is imported and some attributes are set. But the MDL is not supported. So to check if this is really supported, we check if the attributes are matching with a supported MDL
- class omni.flux.utils.material_converter.NoneToAperturePBRConverterBuilder#
Bases:
ConverterBuilderBase
- build(
- input_material_prim: Usd.Prim,
- output_mdl_subidentifier: str,
- class omni.flux.utils.material_converter.OmniGlassToAperturePBRConverterBuilder#
Bases:
ConverterBuilderBase
- build(
- input_material_prim: Usd.Prim,
- output_mdl_subidentifier: str,