5 ms·
Ray Tracing in One Weekend
- soegaard 2y agoIt's a fun tutorial to try out new languages. Here is the result of following the tutorial using Rhombus. https://github.com/soegaard/miniray https://github.com/soegaard/miniray
- pjmlp 2y agoYes, I used as experiment for C++20 modules, C# SIMD instructions and Rust.
- Y_Y 2y agoI strongly approve of this. Code snippets are nice, but with new languages⁰ it's rare to have an example of a self-contained but and complete application to get a holistic view. I think a raytracer (or its equivalent) should be a standard example. 0: Or is Rhombus a dialect? Or alternative writing system for an existing language? Or just an elaborate system of shrubs?
- manas96 2y agoWohoo, my name is in the contributors list! This helped me get in a computer graphics grad course at a top(?) school and certainly helped in further job applications. If anyone else is interested in a graduate degree in this field, I recommend doing something similar - I simply made a few reasonable PRs to fix some issues that I found when following along the books.
- kookamamie 2y ago> Program files will include rtweekend.h first, so all other header files (where the bulk of our code will reside) can implicitly assume that rtweekend.h has already been included. Not a great practice. Header files shouldn't assume anything from previous inclusions of other headers. Sure, this works as a weekend hack, but it would be nice if book (article) would promote good conventions.
- veltas 2y agoThis is a normal practice for applications, and allows you to pre-compile that header for performance. I don't think it's a bad enough practice to warrant complaining, but it's good for people to know the advantages or disadvantages.
- kookamamie 2y agoSee this: https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#Rs-contained https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines... Technically, headers are just copy-paste, obviously. However, there's value to keeping them as standalone as possible.
- on_the_train 2y agoHeaders should still be self contained, although precompiled headers are used. Those things are mostly orthogonal
- airstrike 2y agoPreviously: • Show HN: Ray Tracing in One Weekend v4.0.0 (July 2024) https://news.ycombinator.com/item?id=41082425 https://news.ycombinator.com/item?id=41082425 - 69 points, 5 comments • Raytracing in One Weekend (2016) https://news.ycombinator.com/item?id=25244301 https://news.ycombinator.com/item?id=25244301 - 316 points, 80 comments
- danielpettersso 2y agoI can also recommend this book when looking for something fun to implement while learning a new language. There is also the follow ups to this taking things a bit further: https://raytracing.github.io/books/RayTracingTheNextWeek.html https://raytracing.github.io/books/RayTracingTheNextWeek.htm... https://raytracing.github.io/books/RayTracingTheRestOfYourLife.html https://raytracing.github.io/books/RayTracingTheRestOfYourLi... I did this ray tracing library in Rust inspired by these books: https://github.com/DanielPettersson/solstrale-rust https://github.com/DanielPettersson/solstrale-rust And also a small UI using the lib: https://github.com/DanielPettersson/solstrale-desktop-rust https://github.com/DanielPettersson/solstrale-desktop-rust Kind of not maintained anymore.. But fun way learning Rust..
- deleted 2y ago[deleted]
- tuyguntn 2y agoIs there any similar content for ML/Deep learning?
- strangecasts 2y agoAndrej Karpathy's guide to Micrograd - https://www.youtube.com/watch?v=VMj-3S1tku0 https://www.youtube.com/watch?v=VMj-3S1tku0 - is probably the closest equivalent, in that it covers the basic ideas of backpropagation and autodiff frameworks like PyTorch, and ends with an implementation of a very basic framework (https://github.com/karpathy/micrograd https://github.com/karpathy/micrograd) you can train small neural networks in
- pdpi 2y agoOne thing that's not directly related to ray-tracing proper, so makes no sense in this book series, but is still a pretty natural (and fun!) next step (or detour) is embedding e.g. a Lua interpreter so you can use that as a scene description language separate from the rendering engine proper.
- alanjay 2y agoIf you'd like to see it unfold, step by step, there's a javascript version at https://github.com/MarquisdeGeek/six_hour_raytracer https://github.com/MarquisdeGeek/six_hour_raytracer Plus, it comes with a live demo on https://marquisdegeek.github.io/six_hour_raytracer/ https://marquisdegeek.github.io/six_hour_raytracer/