BloxPT Pathtracer [OPEN SOURCE]

bloxpt
Features
  • Camera settings including aperture, focal length, depth of field, etc.
  • BSDF nodes for mixing shaders, including roughness parameters.
  • Caustics, global illumination.
  • HDRI Skies
  • (SOON) Parallel Luau.
Preview

34 Likes

This is cool! How long dos it take to render an image? And also, is there a playable demo out yet?

3 Likes

Is this using raytracing to aid in the pathtracing?

1 Like

A crappy one takes about 20-30 seconds, an actual scene at higher resolution and samples can take upwards of like 12 hours, but i havent done parallel yet so this will be sped up

5 Likes

You should try comparing it to Cycles or Corona (NOT THE VIRUS, I mean the renderer)

1 Like

i don’t think it’d be very fair since it’s roblox lol

Not because it’s Roblox, this is a literal Ray Tracer, and it’s pretty impressive for one guy

yeah this is insane but compared to stuff like cycles, octane and corona, it’s deeply disadvantaged. The render engines can take advantage of your pc’s full power which allows them to be more complex, complicated and have a team of people behind them. It’d be a nice comparison but the results should be with a grain of salt

Yeah, I know, I just want a comparison to be honest…That’s all, lol

Put the Cycles comparison in the post as requested. Sorry it’s been a second!

6 Likes

nice…I think that is pretty close to good renderers to whatever algorithm you’re using.

This is awesome. I really wonder the tech behind this.

Should try to make a denoiser, then you don’t have to wait hours for 2000 samples.

Open sourced it! I included a simple renderer with it so you can tinker with it and maybe change some things. bloxpt/tracer.lua at main · PoptartNoahh/bloxpt · GitHub

9 Likes

Sorry to bump this, but it is an incredible creation. I was tinkering around with it briefly this afternoon and I couldn’t get any colours to appear (just black - rgb(0, 0, 0)). I’ve dug around a little and the problem appears to be part of the BSDF function in the tracer, the e and albedo variables are muliplied by 0 - which then means that tracer:trace() returns 0, causing the result variable to remain as a blank Vector3 which is then converted into a blank Color3 (see below). I was wondering if I’m doing something wrong? I’m using the original render.lua you provided (thanks!) although I have added a function to convert from vectors to colours and my output function is just a print:

-- render.lua (Script in Workspace)
local function vectorToColor3(Vector)
	assert(Vector.X < 256, "X too big") -- maybe >255 flips back to 0?
	assert(Vector.Y < 256, "Y too big")
	assert(Vector.Z < 256, "Z too big")
	return Color3.new(Vector.X, Vector.Y, Vector.Z)
end

local function output(X, Y, Colour)
	print(X, Y, Colour)
end

-- tracer.lua (ModuleScript in ReplicatedStorage - lines 59-62)
function tracer:bsdf(material, depth)
	if material == "Plastic" then
		return self.e + self.albedo * self:trace(Ray.new(self.x, self:monteCarlo(self.d, self.n) * params.ray_dist), depth) -- multiplying by the trace function seems to be the source
	elseif material == "Metal" then
1 Like

I’m gonna put the actual .rbxl file, I think there is indeed an issue with the render function I put in there . Thanks for pointing it out!

3 Likes

how u rendered that resolution? is that inside roblox?

Amazing job, well made pathtracer man!

1 Like

Best renderer I have ever seen inside Roblox, great job