BLEN-356: Automatically configure PXR_MTLX_STDLIB_SEARCH_PATHS #9

Merged
Bogdan Nagirniak merged 4 commits from blen-356-pxr_mtlx_stdlib_search_paths into hydra-render 2023-03-06 17:29:17 +01:00
Collaborator

No response

_No response_
George-Shakula added 1 commit 2023-03-03 00:24:24 +01:00
Bogdan Nagirniak approved these changes 2023-03-03 10:00:10 +01:00
@ -477,6 +477,7 @@ int main(int argc,
#ifdef WITH_USD
USD_ensure_plugin_path_registered();
USD_setup_usd_mtlx_environment();

do we need #ifdef WITH_MATERIALX ?

do we need `#ifdef WITH_MATERIALX` ?
Author
Collaborator

It's not a requirement but it makes sense to wrap it into an #ifdef. Because if there is no mtlx there is also no usdMtlx

It's not a requirement but it makes sense to wrap it into an #ifdef. Because if there is no mtlx there is also no usdMtlx
George-Shakula marked this conversation as resolved
George-Shakula added 1 commit 2023-03-03 10:10:39 +01:00
Bogdan Nagirniak requested changes 2023-03-03 17:02:37 +01:00
@ -32,4 +35,43 @@ void ensure_usd_plugin_path_registered()
#endif
}
void setup_usd_mtlx_environment()
Move this to https://projects.blender.org/BogdanNagirniak/blender/src/branch/hydra-render/source/blender/render/hydra/python.cc#L27
BogdanNagirniak marked this conversation as resolved
@ -35,0 +67,4 @@
else {
size_t env_var_len = strlen(env_var);
size_t combined_len = stdlib_path_len + 1 + env_var_len + 1;
char *combined = (char *)malloc(sizeof(char) * combined_len);

Use more c++ approach, for example std::string

Use more c++ approach, for example std::string
BogdanNagirniak marked this conversation as resolved
George-Shakula force-pushed blen-356-pxr_mtlx_stdlib_search_paths from e2bf52a80e to 4f8a0f4935 2023-03-05 14:33:25 +01:00 Compare
George-Shakula requested review from Bogdan Nagirniak 2023-03-05 14:34:34 +01:00
George-Shakula added 1 commit 2023-03-05 14:36:03 +01:00
Bogdan Nagirniak approved these changes 2023-03-06 14:52:25 +01:00
Bogdan Nagirniak merged commit aababbde86 into hydra-render 2023-03-06 17:29:17 +01:00
Sign in to join this conversation.
No reviewers
No Label
No Milestone
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: BogdanNagirniak/blender#9
No description provided.