TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Sculpting the moon in R: Subdivision surfaces and displacement mapping

144 pointsby tylermw11 months ago

11 comments

CliffStoll11 months ago
In the 1970&#x27;s, I had the honor of working with Bill Hartmann, Bob Strom, Gerard Kuiper, Clark Chapman and Ewen Whittaker, at Tucson&#x27;s Lunar &amp; Planetary Labs. They used large earthbased telescopes to photograph the moon&#x27;s surface at many illumination angles and libation angles. The images were captured on glass plates.<p>They physically projected these images onto a large plaster sphere; in turn, they rephotographed the images from different angles, to remove foreshortening and show the lunar surface as seen from directly above a crater.<p>One result of this is the Rectified Lunar Atlas -- one of the guiding maps of the Apollo missions: <a href="https:&#x2F;&#x2F;sic.lpl.arizona.edu&#x2F;collection&#x2F;rectified-lunar-atlas" rel="nofollow">https:&#x2F;&#x2F;sic.lpl.arizona.edu&#x2F;collection&#x2F;rectified-lunar-atlas</a>
评论 #40723051 未加载
malshe11 months ago
Looking forward to reading this post but just wanted to say that the work Tyler has done on ray tracing in R is phenomenal. I highly recommend checking out this package website: <a href="https:&#x2F;&#x2F;www.rayshader.com" rel="nofollow">https:&#x2F;&#x2F;www.rayshader.com</a>
评论 #40719326 未加载
pneumic11 months ago
Nice post. R&#x27;s quirks seem to put some people off but I&#x27;ve found that it&#x27;s a relative joy for exploratory analysis and visualization like this, especially within RStudio.<p>Recently I was tasked with grouping a large number of DNA oligonucleotides, and exploring the criteria by which to group them was a lot of fun using various R libraries. In the span of a few days I learned how to use k-means clustering, how to employ an UpSet plot, and how to build a phylogenetic tree.
评论 #40719609 未加载
Blahah11 months ago
Absolutely beautiful - both the clear explanation and the idiomatic (tidyverse style) R packages and code walkthrough. The combination of the two allowed me to read through and understand in one go. And I have immediate uses for the packages. Thanks!
评论 #40734039 未加载
evilturnip11 months ago
In planetary rendering circles, the cubified sphere is a great method and I&#x27;m glad he went over that here.<p>I should say you do get distortion where the cube faces meet at the edges. May or may not be a problem depending on how your texturing.
评论 #40720386 未加载
washedup11 months ago
Amazing work. Simple, easy-to-use code. This must have been quite the effort. It&#x27;s honestly stunning work. Also, good to see R is still alive and well!
评论 #40734034 未加载
pixelpoet11 months ago
I would just directly ray trace it, no subdivision. Then it becomes something like 100 lines of code total, and is probably still faster than the subdiv approach.<p>BTW I like to call that singularity at the pole god, because I often notice it in env maps as an arsehole in the sky :P
condwanaland11 months ago
Tyler, your work in R is always incredible! I love reading about what you&#x27;ve been creating - a lot goes over my head but it&#x27;s always a blast to read
评论 #40734028 未加载
zippyman5511 months ago
Nice! Love R!
评论 #40718413 未加载
phkahler11 months ago
Opensubdiv should be able to do this too. I wonder how much work it would be to glue that on. Maybe there&#x27;s no benefit at this point? ;-)
评论 #40722151 未加载
kaeptnkrunch11 months ago
Nice