Butachan Posted August 9, 2017 Share Posted August 9, 2017 Does mantra do not have a motion vector pass? If so how to render it? Every explanation I found on internet is quite old from 2009 I can only hope there are new methods to do this, right? Any help will be appreciated. Quote Link to comment Share on other sites More sharing options...
jamesr Posted August 9, 2017 Share Posted August 9, 2017 Hi! To make a motion vector pass in mantra, you'll need to make the image plane yourself by extracting the data from the geometry inside your shader. It's pretty straightforward. Drop down a materialbuilder node, or dive into whatever shader is attached to the geo. You need 2 "getblur P' nodes, one set to 0 (pblur0) and the other set to 1 (pblur1). Subtract pblur0 from pblur1. Next, pipe that into a vectortofloat, and connect that to a floattovector. The reason is because for it do work properly in nuke, the X and Y data need to be flipped (Z stays the same!), so make sure to hook it up that way. Lastly, bind that out as a vector "mv". In Mantra, add a custom image plane. VEX Type should be "vector", channel name "mv" (or whatever you named your attribute), Sample Filter set to "Closest Surface" with the pixel filter set to "Object with most coverage (min z value). Finally, make sure you DO have "allow motion blur" checked on! This will force mantra to calculate the motion blur, but at the bottom where it says "Allow image Motion Blur" turn it off, so that the actual output image remains unblurred. I can't upload a hipfile at the moment, but hopefully this explanation makes sense! Also, if you're looking for a more up-to-date quickstart guide on rendering in mantra, check out Adam Swaab's Lighting and Rendering in Mantra videos! 8 Quote Link to comment Share on other sites More sharing options...
Butachan Posted August 9, 2017 Author Share Posted August 9, 2017 11 minutes ago, jamesr said: Hi! To make a motion vector pass in mantra, you'll need to make the image plane yourself by extracting the data from the geometry inside your shader. It's pretty straightforward. Drop down a materialbuilder node, or dive into whatever shader is attached to the geo. You need 2 "getblur P' nodes, one set to 0 (pblur0) and the other set to 1 (pblur1). Subtract pblur0 from pblur1. Next, pipe that into a vectortofloat, and connect that to a floattovector. The reason is because for it do work properly in nuke, the X and Y data need to be flipped (Z stays the same!), so make sure to hook it up that way. Lastly, bind that out as a vector "mv". In Mantra, add a custom image plane. VEX Type should be "vector", channel name "mv" (or whatever you named your attribute), Sample Filter set to "Closest Surface" with the pixel filter set to "Object with most coverage (min z value). Finally, make sure you DO have "allow motion blur" checked on! This will force mantra to calculate the motion blur, but at the bottom where it says "Allow image Motion Blur" turn it off, so that the actual output image remains unblurred. I can't upload a hipfile at the moment, but hopefully this explanation makes sense! Also, if you're looking for a more up-to-date quickstart guide on rendering in mantra, check out Adam Swaab's Lighting and Rendering in Mantra videos! Thank you, this does help. I will try to put it to practice as soon as I can. But I must say I am surprised there is not an out of the box solution for this....after all motion vector are a staple in pretty much all other renderers I have used. Thanks. Quote Link to comment Share on other sites More sharing options...
trzanko Posted August 13, 2017 Share Posted August 13, 2017 you're also able to change the space the motion blur happens in using the transform vop. so if you want 3d moblur you should use world space and if you want 2d moblut transform to NDC space Quote Link to comment Share on other sites More sharing options...
Butachan Posted August 13, 2017 Author Share Posted August 13, 2017 I still can't believe there is not an out of the box motion vector pass... pretty much every other renderer I have used have it. I will make a Feature request, this should definitely be in the to do list in SideFX, or I hope it is.... Quote Link to comment Share on other sites More sharing options...
Butachan Posted August 14, 2017 Author Share Posted August 14, 2017 Ok, made the request feature RFE (ID=84421) Here is How I ask for it: Quote As the title says. Motion vectors are so widely use that I found it hard to believe there is no out of the box pass for it, as Pz for example.info on this:http://forums.odforce.net/topic/30843-motion-vector-pass/Also the new workflow from arnold seems very interesting if adaptable to mantra. Where all AOVs can be defined by a shader network rather individually in each material applied to an object. This actually would be very powerful in the new material interface of H16.info on this:https://vimeo.com/228367966Around 32.25 1 Quote Link to comment Share on other sites More sharing options...
Bob Chapin Posted April 5, 2021 Share Posted April 5, 2021 How can Houdini so consistently make hard things easy and easy things hard. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.