Skip to content

Comments

Experimental mesh light sampling improvements by caching the samples#2542

Draft
IntegratedQuantum wants to merge 1 commit intoPixelGuys:masterfrom
IntegratedQuantum:light_sample_caching
Draft

Experimental mesh light sampling improvements by caching the samples#2542
IntegratedQuantum wants to merge 1 commit intoPixelGuys:masterfrom
IntegratedQuantum:light_sample_caching

Conversation

@IntegratedQuantum
Copy link
Member

While it does reduce block placement lag significantly (9 ms → 7.5 ms) to the point where it only takes 20% of the remaining latency on the render thread (most of the work is distributed). The main bottleneck (when placing white glowcrystals) is now light propagation with around ²⁄₃ of the latency.

However this comes at a cost of increased complexity and decreased generation throughput.

  • It might make sense to switch between the old and new implementation based on the cache size to face count ratio to improve performance on LOD chunks.
  • Cleanup the code, use enum instead of bool for the light parameter, pass it in from further up to reduce code duplication.
  • Move the LOD switch to a separate PR, so we can check its impact independently of the cache changes.
  • Make a throughput (chunk generation) and latency (placing blocks) comparison in various environments

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant