Skip to content

Commit

Permalink
Merge fix 7.2.5 in master (#1828)
Browse files Browse the repository at this point in the history
* Update tests after arnold changes on curves (#1766)

(cherry picked from commit 2fcc262)

* Fix the incorrect orientation of the PointInstancer instances in the render delegate (#1777)

* add test for #1776

* Initialize the rotation matrix with the quad directly

* update changelog for #1776

* Fix changelog for 7.2.5 release (#1788)

* More changelog fixes

* handle vertex interpolated uvs on bspline curves (#1792)

* FIx the error "Cannot load _htoa_pygeo library required for volume rendering in Solaris" (#1811)

* Improve material network creation times by caching the nodes returned by Arnold (#1813)

* Improve material network creation by caching the nodes returned by arnold

* optimize further by first checking if the shader is an arnold shader

* move shader node entry and osl code cache in the render delegate and use lock/mutex

* cache materialx nodes only

* Fix build with older versions of arnold (#1820)

* fix build with older versions of arnold

* fix compatibility with older versions of arnold

* convert AtString to string

* allow materialx for versions > 7.1.4

* fix ifdef versions for materialx

* compatibility with older arnold versions

---------

Co-authored-by: Sebastien Blaineau-Ortega <sebastien.blaineau.ortega@autodesk.com>
  • Loading branch information
cpichard and sebastienblor committed Jan 25, 2024
1 parent a1a94a7 commit 8ec123e
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 22 deletions.
9 changes: 8 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,15 @@

### Bug fixes

- [usd#1812](https://github.com/Autodesk/arnold-usd/issues/1812) - Improve Material network creation by caching the node entries and the osl code. (fix-7.5.)
- [usd#1808](https://github.com/Autodesk/arnold-usd/issues/1808) - Fix the error "Cannot load _htoa_pygeo library required for volume rendering in Solaris" in Houdini 19.5+.
- [usd#1812](https://github.com/Autodesk/arnold-usd/issues/1812) - Improve Material network creation by caching the node entries and the osl code.

## [7.2.5.1] - 2024-01-18

### Bug fixes

- [usd#1776](https://github.com/Autodesk/arnold-usd/issues/1776) - Fix incorrect PointInstancer instance orientations in the render delegate.
- [usd#1769](https://github.com/Autodesk/arnold-usd/issues/1769) - Fix curve uvs when they are vertex interpolated.

## [7.2.5.0] - 2023-12-13

Expand Down
36 changes: 15 additions & 21 deletions libs/render_delegate/volume.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@
#include "utils.h"

#include <iostream>
#include <array>

#include <pxr/base/arch/defines.h>
#include <pxr/base/arch/env.h>
Expand Down Expand Up @@ -111,7 +112,7 @@ struct HtoAFnSet {

HtoAFnSet()
{
/// The symbol is stored in _htoa_pygeo.so in python2.7libs, and
/// The symbol is stored in _htoa_pygeo.so in pythonX.Xlibs, and
/// htoa is typically configured using HOUDINI_PATH. We should refine
/// this method in the future.
/// One of the current limitations is that we don't support HtoA
Expand All @@ -122,29 +123,22 @@ struct HtoAFnSet {
if (path == "&") {
return false;
}
const auto dsoPath27 = path + ARCH_PATH_SEP + "python2.7libs" + ARCH_PATH_SEP + "_htoa_pygeo" +
//. HTOA sets this library's extension .so on MacOS.
std::string dsoPath;
void* htoaPygeo = nullptr;
#ifdef ARCH_OS_WINDOWS
".dll"
std::string ext = ".dll";
#else
".so"
std::string ext = ".so";
#endif
;
const auto dsoPath37 = path + ARCH_PATH_SEP + "python3.7libs" + ARCH_PATH_SEP + "_htoa_pygeo" +
#ifdef ARCH_OS_WINDOWS
".dll"
#else
".so"
#endif
;
std::string dsoPath = dsoPath27;
void* htoaPygeo = ArchLibraryOpen(dsoPath27, ARCH_LIBRARY_NOW);
if (htoaPygeo == nullptr) {
dsoPath = dsoPath37;
htoaPygeo = ArchLibraryOpen(dsoPath37, ARCH_LIBRARY_NOW);
if (htoaPygeo == nullptr) {
return false;
}
// TODO: we need to find a solution that doesn't require to add the future python version of houdini
std::array<std::string, 4> pythonVersions = {"2.7", "3.7", "3.9", "3.10"};
for (const auto &pyVer : pythonVersions) {
dsoPath = path + ARCH_PATH_SEP + "python" + pyVer + "libs" + ARCH_PATH_SEP + "_htoa_pygeo" + ext;
htoaPygeo = ArchLibraryOpen(dsoPath, ARCH_LIBRARY_NOW);
if (htoaPygeo) break;
}
if (!htoaPygeo) {
return false;
}
convertPrimVdbToArnold = reinterpret_cast<HtoAConvertPrimVdbToArnold>(GETSYM(htoaPygeo, convertVdbName));
if (convertPrimVdbToArnold == nullptr) {
Expand Down

0 comments on commit 8ec123e

Please sign in to comment.