Use the "modern" cmake way of naming/passing along targets; as a bonus,
this lets us bump the version of openexr we ship as a submodule to be
the most recent release.
Fixes#478, which was due to pbrt not handling having a modern version of
openexr installed locally.
* Adds a post-configuration step that explicitly installs `zlibstatic` into the `Ptex` export set.
* Prevents "target not in any export set" errors during the installation stage.
* Leaves the existing Ptex submodule files unmodified, preserving upstream compatibility.
* Verified on Windows 10 with Visual Studio 2022.
Normalize unicode strings for user-supplied names (objects, materials,
media, etc.) Note that there is no need to normalize strings for things
like the name of the selected sampler, light source types, or the
parameters provided to pbrt objects, as all of the valid ones are plain old
ASCII text. We also intentionally do not normalize pathnames, as doing so
can cause all sorts of trouble.
- #undefine interface, which somehow gets #defined in debug builds, thwarting
the layered BxDF code
- Move a CHECK out of (possibly) GPU code
- And some cmake tidying
Every 100ms, logs CPU (and GPU, if PBRT_NVML is enabled at cmake configure
time) utilization and memory use to the verbose log.
This is currently only useful on Linux; OSX and Windows need their
system-specific calls wired up to get current CPU utilization.
Beyond the convenience of having them as a vector of strings, this
is where UTF16 -> UTF8 conversion of args happens on Windows.
This led to some adjustments to ParseArg()...
With this (and a number of preceeding commits), #136 should now be fixed.
* Generalize GPU rendering path to run on both CPU and GPU
Now we have a WavefrontIntegrator that can both run on the CPU (backed by
ParallelFor() for parallelization and pbrt's aggregates for ray
intersection acceleration) and on the GPU (backed by GPUParallelFor() for
parallelization and OptiX for ray intersection on NVIDIA GPUs.)
Beyond generalizing the code, this refactor allows CPU-side debugging and
testing of the wavefront integrator. Doing so allows further isolation of
the GPU-specific code into a few source files, now just ~2.5k lines of code.
This includes a bug fix in the wavefront medium code to resolve MixMaterials
to one of their constituent materials before enqueuing material evaluation
and shading work.
Note that on the CPU, the wavefront integrator runs 5-10x more slowly than
pbrt's regular CPU integrators, so it is not recommended for regular use...
Co-authored-by: Wenzel Jakob <wenzel.jakob@epfl.ch>