6 ms·
My adventures getting Disney’s Moana island scene to render well with Pbrt
- aorth 8y agoWow, this actually makes me want to go watch Moana. Great to see collaboration between big animation studios and the open-source software community. Also, Matt's analysis of his own code is unabashed and honest. In the end he managed to make some solid performance wins for pbrt!
- KaiserPro 8y agoyou _should_ watch Moana, its a great movie with fun music. then watch it a second time for the animation and rendering....
- Angostura 8y agoThen watch it with the Director's commentary, which has fun nuggets like Maui spends a lot of time in the film with his hair tied up, because his unencumbered hair proved very expensive to render.
- laken 8y agoThey also originally made Maui bald (for that same reason: cost), but their cultural consultants said it may be offensive to native Polynesians, as Maui was known for his long hair.
- red75prime 8y agoEach triangle is an object with two v-tables? That's gross indeed.
- barrkel 8y agoOO is not the approach I'd use for fast and memory efficient manipulations of lots of geometric primitives, indeed. Although I don't know the specifics.
- magicalhippo 8y agoPbrt was made to teach how to write a physically-based ray tracer. As such it is not focused on raw speed, and the ability to extend it easily is important. Implementing better mesh handling is an excellent exercise for the reader. As an aside, the book "Physically Based Rendering", which is the source of pbrt, is _by far_ the best programming book I've ever read. So many books spend a lot of time on trivial stuff, while others dive into the difficult theory and math but doesn't show how to translate it into code. PBR goes through the difficult theory and math in detail while also showing how to implement it in code, explaining potential pitfalls and tricks along the way. And it does so in an elegant and easy to understand way. And if you got some questions, the authors answers questions in a Google Group.
- weavie 8y agoTurns out Matt Pharr, the author of this article, is also the author of this book.
- magicalhippo 8y agoYes, thanks for pointing that out. I so easily forget to mention things that seem obvious to me :(
- Micoloth 8y agoAhah, not good for a programmer :D I'm joking, thanks for suggesting that book, I don't know much about this stuff but i might actually read it!
- magicalhippo 8y agoTell me about it :P Since a physically-based ray tracer involves a lot of different theory and math, it can be quite interesting even if your not in it for the actual ray tracing. For example there's sampling low-discrepancy sequences, kd-trees and other bounding volumes, color representation and conversion etc.
- 8y ago
- ur-whale 8y agoEven one would be gross.
- Smerity 8y agoI love these stories of engineering and science from the trenches. Prefacing the story with "the early Pixar renderer was stupidly slow for silly archaic (and at the time sensible reason) X" followed by "luckily no-one is that silly anymore - except me, as an expert, did Y, which geez looks a lot like X" is a perfect start :) Not only is it an adventure you can join an expert in their field on but when told honestly it's a lovely reminder that everyone stumbles and drops the proverbial hammer on their foot occasionally. It's also a loving testament to our era of content generation that a frequent task in creating a children's film is solving complex scientific or engineering problems. They recreate so many of the strange nuances and hidden beauty of our world (anisotropic rendering, Navier–Stokes equations, subsurface scattering, caustics, flocking, dendritic growth of snowflakes, global illumination, ...) just so they can render the purest representation of it for us. I genuinely am so glad for the time I spent in art[1] and computer graphics, though neither have much relevance to my career now, simply as it changed the way I look at the world. When you want to try to recreate a real life scene from scratch you realize just how much happens in the real world without you ever appreciating it[1]. [1]: Even after the physics and science above: Do people frequently travel down this path? Might it become a holloway[2]? Does the roof guttering drain out here? There'll likely be moss or wearing paint. Old stone steps of an ancient tavern? The stone will likely be worn away at the center or on either side of the door. The background scenery in a modern computer graphics film has dozens or hundreds of hours in them and will be filled with nuance and/or in-jokes. If you need to create a background world in any appreciable detail, why not use it as a canvas to keep telling a story? [2]: https://en.wikipedia.org/wiki/Sunken_lane https://en.wikipedia.org/wiki/Sunken_lane
- yoodenvranx 8y ago> I love these stories of engineering and science from the trenches. I wish there was a website collecting all these stories and articles. They could also ask the authors for permission and offer epub/pdf downloads of these stories. That would be a nice read while traveling
- theoh 8y ago"all these stories and articles"? There are millions of people working in software, the number of interesting war stories just within computer science is (conservatively) in the thousands. A distributed system of blogs is the only efficient way to publish that breadth of material, bearing in mind that each reader's interests are different, you can't curate a feed to suit everyone. With all due respect, one convenient website aggregating all that material is not a practical idea. It's like asking for one huge magazine to exist which contains everything worth reading about a huge field like CS. Edit: I mean, it would be convenient, but there's no royal road to finding stuff that's worth reading. https://queue.acm.org https://queue.acm.org is pretty good, for example
- erikbye 8y agoIf you'd like to learn more about pbrt (the renderer), I can recommend his comprehensive book Physically Based Rendering. It's used as a textbook in a lot of courses and doesn't assume CG knowledge above an introductory level.
- mhd 8y agoI wonder whether someone converted that scene to PovRay…
- jugg1es 8y agoThis made me chuckle. "However, some earlier phase of the production pipeline used a fixed-size buffer for storing object names and would shorten any longer names, keeping only the end and helpfully adding a few periods to show that something had been lost: “…year/LeftArm/Hand/IndexFinger/Knuckle2”. Thence, all of the object names the renderer saw were of that form, the hash function hashed all of them to the bucket for ‘.’, and the hash table was actually a big linked list. Good times. "
- appslure 8y agoWe are among the leading mobile app development companies in India. Expertise in developing apps for handheld devices - Android, iOS, Hybrid. http://www.appslure.com/mobile-apps-development/ http://www.appslure.com/mobile-apps-development/
- bpicolo 8y agoHow close are the renders to movie-accurate (that is, what's missing?)? Looking at e.g. [0], it seems to be missing a lot vs what is seen in the film. Are features missing compared to the original, were things missing from the scene description, or something else? The shorelines from screen stills in particular seem much more sophisticated [1]. [0] http://pharr.org/matt/blog/images/pbrt-moana-beach.jpg http://pharr.org/matt/blog/images/pbrt-moana-beach.jpg [1] https://vignette.wikia.nocookie.net/moana/images/e/e3/How_Far_I%27ll_Go.jpg/revision/latest?cb=20161128042412 https://vignette.wikia.nocookie.net/moana/images/e/e3/How_Fa...
- sophistication 8y agoThe shorelines were likely rendered by in-house fluid dynamics simulation, and, likewise, the surface structures of the stones, sand and barks likely use in-house shaders which are far more advanced than what's implemented in non-commercial, non-in-house renderers. The Pbrt render also lacks aerial perspective: https://en.wikipedia.org/wiki/Aerial_perspective https://en.wikipedia.org/wiki/Aerial_perspective
- trishume 8y agoThe documentation Disney posted about the data set has an explanation: https://www.disneyanimation.com/technology/datasets https://www.disneyanimation.com/technology/datasets Basically they have a few different techniques that couldn't be directly translated into PBRT, like lights that only hit certain objects, so the lighting is not as good in the PBRT renders, along with a few other things. Nothing super advanced, just some things that were added to their renderer for artistic control reasons that PBRT doesn't have.
- dahart 8y agoI’ve looked at the data, and one of the main things missing is texture & orientation of the curves in the data set. The documentation mentions this is due to the curve data being expression based. That’s why the PBRT images have constant-color palms, for example, and might be the thing you couldn’t put your finger on that seems less accurate than Disney’s renders.
- electricslpnsld 8y ago> It was a huge amount of work on Disney’s side to extract the scene from their internal scene representation and convert it to a format that’s generally accessible Is this something that Pixar's USD [1] format would help with? [1] https://github.com/PixarAnimationStudios/USD https://github.com/PixarAnimationStudios/USD
- angus-g 8y agoFrom their readme, USD was considered but OBJ was chosen "for expediency."
- taeric 8y agoFor those that don't know, pbrt is worth checking out. One of the go to examples for Literate Programming and something I hope to someday read. http://www.pbrt.org/ http://www.pbrt.org/ :) If folks around here have experience with it, I'd love to see a discussion on that.
- iforgotpassword 8y agoWe used it (as primarily intended) for teaching in class, extending it etc. Didn't actually read the book but worked along the slides from the lecture, the structure of pbrt makes it really easy to dive in and get your hands dirty.
- electricslpnsld 8y ago> Looking at the profile, roughly 60% of rendering time is spent in ray–object intersections (most of it in BVH traversal), and 25% is spent in ptex texture lookups. Did Disney release these stats for their Hyperion renderer? I would be curious where they spend all their time.
- floatboth 8y agoHas anyone tried that scene with Blender Cycles?
- thedaemon 8y agoI have yet to attempt it in Cycles or Non-Commercial RenderMan for Blender yet. It's on my to do list. If I do it or find someone else that has.. I will make a new post.
- de_watcher 8y agoOk, Part 4 confirmed that I'm not insane and most of these std::shared_ptr should go.