<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">This is my patch for faster volume mesh generation:<div class=""><a href="https://developer.blender.org/P756" class="">https://developer.blender.org/P756</a></div><div class=""><br class=""></div><div class="">-Stefan<br class=""><div><br class=""><blockquote type="cite" class=""><div class="">On 23. Jul 2018, at 14:25, Stefan Werner <<a href="mailto:stewreo@gmail.com" class="">stewreo@gmail.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html; charset=utf-8" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">Hi Geraldine!<br class=""><div class=""><br class=""><blockquote type="cite" class=""><div class="">On 20. Jul 2018, at 18:01, Geraldine Chua <<a href="mailto:chua.gsk@gmail.com" class="">chua.gsk@gmail.com</a>> wrote:</div><div class=""><div dir="ltr" class=""><br class="">There appears to be a bug where VDB textures are rendered with artifacts and solid shadows, but only if a volume mesh is created. I have attempted to debug the issue but cannot figure out the reason so far. In addition to this, generating a mesh takes a considerable amount of time compared to built-in smoke. A simple fix to these issues would be disabling volume mesh construction for VDB grids, but it would be nice to figure out the cause of this bug. </div></div></blockquote><div class=""><br class=""></div>The volume mesh generation uses a vertex deduplication routine with O(n^2) runtime, that’s probably what you’re seeing. I should have a potential fix for that around somewhere, it’s possible to do this without creating duplicate vertices to begin with.</div><div class=""><br class=""><blockquote type="cite" class=""><div class=""><div dir="ltr" class="">With reference to the Stephen's previous work on volume motion blur (<a href="https://github.com/tangent-animation/blender278/pull/103" class="">https://github.com/tangent-animation/blender278/pull/103</a>), I wrote a minor patch with promising results. I am uploading the diff instead of committing since it's pretty hacky and there may be more efficient ways of going about implementing it (<a href="https://developer.blender.org/P755" class="">https://developer.blender.org/P755</a>).<br class=""></div></div></blockquote></div><div class=""><br class=""></div><div class="">Your patch works under the assumption that the motion vectors stored in the grid are in world coordinates, which they may not necessarily be. You probably need to apply the inverse scale and rotation matrix of the volume objects to the values read from the volume.</div><div class=""><br class=""></div><div class="">-Stefan</div></div></div></blockquote></div><br class=""></div></body></html>