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

Đang mở
#329 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
52/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
cpp
Lĩnh vực
computer-graphics

Hướng nghiên cứu

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.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

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).

Ngôn ngữ chính
CMake
Star
4.7k
Fork
321
Merge trung bình
13 phút
Pull request đã merge (30 ngày)
3

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của OpenMoonRay/openmoonray

Tất cả issue của OpenMoonRay/openmoonray

Issue tương tự

Thêm issue về Computer Graphics

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.