Open Moonray Arras Developer Reference

website·Indexed 34 days ago

https://docs.openmoonray.org/

Technical API documentation for the Arras component of Open Moonray, specifically focusing on the mcrt_dataio namespace. This reference includes Doxygen-generated documentation for classes such as ClientReceiverDenoiser, TimingAnalysis, and the telemetry subsystem, including Overlay, LayoutBase, and LayoutUtil.

Tokens
237.3K
Snippets
965
Records
1.7K
Agent score
65%

What's inside Open Moonray

  1. Overview of MoonRay Material Shaders and BsdfBuilder

    MoonRay uses the BsdfBuilder API to simplify the creation of energy-conserving materials. Instead of manually managing low-level constructs like Bsdf, BsdfLobe, and Fresnel classes, developers use BsdfComponent objects. The BsdfBuilder handles the construction, weighting, Fresnel behavior, and energy conservation of these components based on the order they are added.

    Supported shading models include:

    • BRDFs: Mirror, Lambertian, FlatDiffuse, OrenNayar, Microfacet (Anisotropic/Isotropic), Fabric, Velvet, GlitterFlake, StochasticFlakes, Toon, and ToonSpecular.
    • BTDFs: Mirror, Microfacet (Anisotropic/Isotropic).
    • BSDFs: Mirror, Microfacet (Anisotropic/Isotropic).
    • Specialized: DipoleDiffusion, NormalizedDiffusion, RandomWalkSubsurface, EyeCaustic, Hair (Diffuse, BSDF, RBRDF, TRTBRDF, TTBTDF, TRRTBRDF), and HairToonSpecular.
  2. Overview of BarnDoorLightFilter

    The BarnDoorLightFilter simulates stage lighting barn doors by creating a rectangular portal (flap opening) that restricts where light can shine. The portal can be moved, resized, rotated, rounded, colored, and blurred. It supports two primary operational modes:

    • Physical Mode: Checks if the ray between the shading point and the light passes through the rectangular portal. Rays masked by the portal are darkened.
    • Analytical Mode: Similar to physical mode, but treats the light as a point light for filter shadowing, replacing the light's end-ray with the singular position of the Barn Door.

    Additionally, it supports two projection types:

    • Perspective: The flap opening size scales with projector_focal_distance to maintain a consistent solid angle/cone size.
    • Orthographic: The flap opening remains a fixed size.
  3. Overview of ProjectTriplanarNormalMap_v2

    ProjectTriplanarNormalMap_v2 is used to procedurally apply normal maps using triplanar projection. It functions similarly to the standard ProjectTriplanarNormalMap but replaces the use_reference_space attribute with input_position_source. This allows users to choose between surface position/normal, reference position/normal, or custom position/normal data provided via the input_position and input_normal attributes.
  4. Overview of DirectionalMap

    DirectionalMap is used to blend colors based on the alignment of the surface normal and a specified "prime direction." This is commonly used for physical phenomena (e.g., dust accumulating on top of surfaces) or view-dependent effects. Note: DirectionalMap does not automatically detect downstream normal mapping; you must explicitly connect relevant normal maps to the node to include them in the calculation.
  5. Overview of RectLight

    RectLight is a flat rectangular light source that exists in the light's local (x,y)-plane. Its dimensions are defined by the width and height attributes. By default, light is emitted from a single surface corresponding to the positive direction of the light's local z-axis; this behavior can be modified using the sidedness attribute.
  6. Overview of MoonRay denoising engines

    MoonRay supports two denoising engines that can be used via the moonray_gui or the denoise command-line tool. The engine is selectable based on available hardware:

    1. NVIDIA OptiX denoiser: Requires a compatible NVIDIA GPU.
    2. Intel Open Image Denoise (OIDN): Runs on the CPU.
  7. Overview of MoonRay Materials and BSDFs

    Materials in MoonRay produce Bidirectional Scattering Distribution Functions (BSDFs) that define how a surface scatters light. BSDFs are categorized into BRDFs (reflection) and BTDFs (transmission). The balance between reflection and transmission is determined by Fresnel equations, with MoonRay primarily supporting dielectric (non-metals) and conductor (metals) Fresnel models.
  8. Overview of ProjectTriplanarNormalMap

    ProjectTriplanarNormalMap applies and blends normal textures procedurally using a virtual cube projection. The blending weight for each face's texture is determined by the alignment of the mesh normal with the face. The transition_width parameter controls the amount of blending across faces, and the normal map is applied with the correct tangent for each cube face.
  9. Overview of DwaMetalMaterial

    DwaMetalMaterial is used to create metallic materials such as gold, copper, chrome, and steel. To achieve realistic results, use physical values for metallic_color and metallic_edge_color. The metallic_edge_color should generally be a brighter version of the metallic_color; together, these two parameters define the conductor Fresnel behavior specific to this material.