Rough transmission with dispersion is too dark under direct light (pdf differs between sample() and eval())

Abierto
#329 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
52/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
cpp

Línea de trabajo

Start by reading TransmissionCookTorranceBsdfLobe::sample() and eval() in lib/rendering/shading/bsdf/cook_torrance/BsdfTransmissionCookTorrance.cc, then trace how the integrator uses their PDFs for light and BSDF samples. Reproduce the reported rough glass setup with dispersion enabled and compare the combined result with each sampling mode alone. Done when both paths report consistent densities and the combined result agrees with the individual results.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

Summary. A rough refractive material with use_dispersion renders about 15% darker when light and BSDF samples are combined than with either alone. Without dispersion all three agree. Version 2026.29.1, scalar mode.

Reproduce. A rough glass sheet (DwaBaseMaterial, transmission 1, roughness 0.3, use_dispersion true, dispersion_abbe_number 20) lit by a disk light behind it, max_depth 1:

light_samples 4, bsdf_samples 0 0 / 4 2 / 2
no dispersion 0.1107 0.1112 0.1113
with dispersion 0.1107 0.1114 0.0942

Cause. TransmissionCookTorranceBsdfLobe::sample() (lib/rendering/shading/bsdf/cook_torrance/BsdfTransmissionCookTorrance.cc) picks a colour channel and multiplies the returned pdf by the channel probability:

Color result = eval(slice, wi, etaT, &pdf);
// Dispersion PDF
pdf *= spectralPDF;

eval(), which the integrator calls for light samples, returns the pdf at mEtaT without that factor. The integrator's power heuristic then sees 0.35 p on the BSDF-sample side and p on the light-sample side, and the two weights sum to less than one.

Suggestion. Have eval() and sample() report the same density for a given direction (for instance the mixture over the three channels in both).

Lenguaje dominante
CMake
Estrellas
4.7k
Forks
321
Merge medio
13 min
PR fusionados (30 d)
3

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de OpenMoonRay/openmoonray

Todos los issues de OpenMoonRay/openmoonray

Issues similares

Más issues de Computer Graphics

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.