Code Monkey home page Code Monkey logo

raytracinginoneweekend's Introduction

RayTracingInOneWeekend

Introduce

《Ray tracing in one weekend》is a good book for ray tracing tutorial, and Peter Shirley implements a simple ray tracing engine by C++.

This is my Ray Tracing Tutorial of JAVA version.

  1. RayTracingInOneWeekend

  2. RayTracingTheNextWeek

  3. RayTracingTheRestOfYourLife

The output of my projects is a PPM(P3) file. You can use ImageMagick to transfer into a JPG file, or you can use other Image Viewer software(eg: XnView) to open it.

#ppm2jpg
import PythonMagick as PM
img = PM.Image(r"C:\Users\yh\Documents\CG\result\Chapter6_20_39_01.ppm")
img.write(r"C:\Users\yh\Documents\CG\result\Cp6.jpg")

All Images of Every Chapters are As follows:

Chapter 12: Where next?

Chapter 11: Defocus Blur

cp11

Chapter 10: Positionable camera

Chapter 9: Dielectrics

Chapter 8: Metal

cp8

Chapter 7: Diffuse Materials

Chapter 6: Antialiasing

Cp6

Chapter 5: Surface normals and multiple objects.

cp5-1

Chapter 4: Adding a sphere

CP4

Chapter 3: Rays, a simple camera, and background

Cp3

Chapter 2: The vec3 class

Chapter 1:Output an image

cp1

raytracinginoneweekend's People

Contributors

yhcheer avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.