Skip to content

Commit

Permalink
Document constructors.
Browse files Browse the repository at this point in the history
  • Loading branch information
JGamache-autodesk committed Dec 5, 2024
1 parent d59cc51 commit db374a6
Show file tree
Hide file tree
Showing 2 changed files with 52 additions and 5 deletions.
29 changes: 27 additions & 2 deletions lib/mayaUsd/render/MaterialXGenOgsXml/ShaderGenUtil.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,34 @@ namespace ShaderGenUtil {
class MAYAUSD_CORE_PUBLIC TopoNeutralGraph
{
public:
/*! Creates a barebones TopoNeutralGraph that will process the provided material and generate a
* topo neutral version of it.
* @param[in] material the material to process
*/
explicit TopoNeutralGraph(const mx::ElementPtr& material);
TopoNeutralGraph(const mx::ElementPtr& material, const LobePruner::Ptr& library);
TopoNeutralGraph(const mx::ElementPtr& material, const LobePruner::Ptr& library, bool textured);

/*! Creates a TopoNeutralGraph that will process the provided material and generate a topo
* neutral version of it. It will also substitute lobe pruned categories if a LobePruner is
* provided.
* @param[in] material the material to process
* @param[in] lobePruner an instance of a LobePruner. These are usually singletons that
* accumulate pruned NodeDefs
*/
TopoNeutralGraph(const mx::ElementPtr& material, const LobePruner::Ptr& lobePruner);

/*! Creates a TopoNeutralGraph that will process the provided material and generate a topo
* neutral version of it. It will also substitute lobe pruned categories if a LobePruner is
* provided.
* @param[in] material the material to process
* @param[in] lobePruner an instance of a LobePruner. These are usually singletons that
* accumulate pruned NodeDefs
* @param[in] textured is true if the full material is to be processed. When false, we will
* generate an untextured topo neutral material instead
*/
TopoNeutralGraph(
const mx::ElementPtr& material,
const LobePruner::Ptr& lobePruner,
bool textured);
~TopoNeutralGraph() = default;

TopoNeutralGraph() = delete;
Expand Down
28 changes: 25 additions & 3 deletions lib/mayaUsdAPI/render.h
Original file line number Diff line number Diff line change
Expand Up @@ -145,11 +145,33 @@ class MAYAUSD_API_PUBLIC LobePruner
class MAYAUSD_API_PUBLIC TopoNeutralGraph
{
public:
TopoNeutralGraph(const MaterialX::ElementPtr&);
TopoNeutralGraph(const MaterialX::ElementPtr&, const LobePruner::Ptr& lobePruner);
/*! Creates a barebones TopoNeutralGraph that will process the provided material and generate a
* topo neutral version of it.
* @param[in] material the material to process
*/
TopoNeutralGraph(const MaterialX::ElementPtr& material);

/*! Creates a TopoNeutralGraph that will process the provided material and generate a topo
* neutral version of it. It will also substitute lobe pruned categories if a LobePruner is
* provided.
* @param[in] material the material to process
* @param[in] lobePruner an instance of a LobePruner. These are usually singletons that
* accumulate pruned NodeDefs
*/
TopoNeutralGraph(const MaterialX::ElementPtr& material, const LobePruner::Ptr& lobePruner);

/*! Creates a TopoNeutralGraph that will process the provided material and generate a topo
* neutral version of it. It will also substitute lobe pruned categories if a LobePruner is
* provided.
* @param[in] material the material to process
* @param[in] lobePruner an instance of a LobePruner. These are usually singletons that
* accumulate pruned NodeDefs
* @param[in] textured is true if the full material is to be processed. When false, we will
* generate an untextured topo neutral material instead
*/
TopoNeutralGraph(
const MaterialX::ElementPtr& material,
const LobePruner::Ptr& library,
const LobePruner::Ptr& lobePruner,
bool textured);
~TopoNeutralGraph();

Expand Down

0 comments on commit db374a6

Please sign in to comment.