Fix critical logic errors in distributed path tracer - #6
Draft
vmanam0451 with Copilot wants to merge 4 commits into
Draft
Fix critical logic errors in distributed path tracer#6vmanam0451 with Copilot wants to merge 4 commits into
vmanam0451 with Copilot wants to merge 4 commits into
Conversation
…ssor Fixes: 1. Master resolution off-by-one: Added +1 to resolution calculation 2. Master bounds in preprocessor: Fixed max_x/max_y to use X-1/Y-1 3. ACCUMULATE stage routing: Changed from map_ray_stage_to_queue to m_batch_sender.enqueue_ray for master 4. Direct lighting results routing: Added proper owner check before routing (similar to object intersection results) 5. Batch sender flush: Removed early break to ensure final flush 6. Global resolution for NDC: Added image_width/image_height fields and global_resolution member for correct ray generation 7. Ray initialization: Added proper initialization for all cloud_ray fields Co-authored-by: vmanam0451 <25410102+vmanam0451@users.noreply.github.com>
…t fvec2) Co-authored-by: vmanam0451 <25410102+vmanam0451@users.noreply.github.com>
Co-authored-by: vmanam0451 <25410102+vmanam0451@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Review code for logic and AWS resource issues
Fix critical logic errors in distributed path tracer
Jan 14, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Code review identified several serious bugs preventing the distributed path tracer from functioning correctly: incorrect ray routing, off-by-one resolution errors, and NDC calculation using tile dimensions instead of global image dimensions.
Ray Routing Fixes
map_ray_stage_to_queuedoesn't handle ACCUMULATE—changed tom_batch_sender.enqueue_ray(ray, MASTER_ID)Resolution/Bounds Fixes
(max - min)→(max - min) + 1max_x: X→max_x: X - 1(inclusive bounds)image_width/image_heightfields toworker_infoConcurrency Fix
flush_loop()that skipped final flush whenm_terminatesetInitialization
cloud_rayfields (object_intersect_distance,alpha,type)uvec2declarations incorrectly usingfvec2constructorOriginal prompt
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.