Search Tools Links Login

Semi-realtime Raytracer 2: Primitives!

Complete rebuild of my previous port of the C++ raytracer. This supports: Spheres, Triangles, Planes, Cylinders. Also supports shadows(!), reflections(!!), and multiple _colored_ light sources. Hence why it is so slow. You can now turn on/off options, so you can see everything nicely. Note that you MUST compile to get a bit decent framerate. With triangle support, it's in theory possible to load 3D models and raytrace them.
I might optimize the code later (it's become a bit messy), but it really depends on your votes.
Note that the rendered scene might look a bit chaotic. This is more because of the large "gaps" between every frame.
Note that Raytracers are known for their slowness. That's why there aren't (m)any real-time raytraced programs yet.

Original Author: Almar Joling

API Declarations

Public Declare Function SetDIBits Lib "gdi32" (ByVal hdc As Long, ByVal hBitmap As Long, ByVal nStartScan As Long, ByVal nNumScans As Long, lpBits As Any, lpBI As BITMAPINFO, ByVal wUsage As Long) As Long
Private Declare Function timeGetTime Lib "winmm.dll" () As Long
Private Declare Function GetTickCount Lib "kernel32" () As Long

About this post

Posted: 2002-06-01
By: ArchiveBot
Viewed: 91 times


Visual Basic 6

Posted: 9/3/2020 3:45:00 PM
Size: 14,357 bytes

Loading Comments ...


No comments have been added for this post.

You must be logged in to make a comment.