PDA

View Full Version : Raytracing in ZBrush (ZScript Included)



WingedOne
07-12-02, 06:22 AM
I was working on a ZScript Raytracer. This is only a preliminary experiment and as a result it runs butt-ugly slow right now. This image took about 2.5 hours to render for me. All it does is cast rays and perform a ray-sphere intersection test. The shadow and lights in this image have nothing to do with the raytracer, those were just the standard ZBrush lighting and shadows native to ZBrush.

In the future I hope to optimize the code using proper vector maths as well as add shadows, reflections and phong-highlighting as well as more primitives. Also I need to figure out what to do about the aliasing artifacts.

But the most interesting thing I hope to do is I also hope to extend this so the ray-tracing routines would be able to interact with pre-existing information on the canvas.

Keep in mind that this is just a preliminary experiment and its usefulness is just purely academic right now. :rolleyes:

RayTracer.txt (http://www2.zbrushcentral.com/zbc_uploads/user_file-1026480115hzy.txt)

http://www2.zbrushcentral.com/zbc_uploads/user_image-1026480142hox.jpg

Frenchy Pilou
07-12-02, 07:44 AM
Zbrush can't considered like a raytracer in the best Render option ?
Pilou

WingedOne
07-12-02, 07:47 AM
Not really, I believe it currently uses other types of rendering routines.

aurick
07-12-02, 09:16 AM
Version 1.5 will have ambient lighting and soft shadows. Which means that there will be raytracing. :)

Those are really neat results, though! I would never have imagined that a ZScript could do such a thing.

WingedOne
07-12-02, 09:57 AM
I'll keep working on it though. Mostly for my own education and to get a better understanding of ZScripting. Plus, it may still evolve into something actually useful.

Muvlo
07-12-02, 11:34 AM
Super job WingedOne! Really amazing use of ZScripts. :)

Flycatcher
07-12-02, 04:08 PM
I think I'll wait for the optimised script before trying this one out! ;) But full marks for being brave enough to try implementing this process in ZScript - I am in awe. Good luck with the next stages of the experiment. :tu:

Grub
07-12-02, 06:08 PM
I've done a bit of 'c' programming, coding a ray tracer is not an easy task. I'm amazed that you can do complex stuff like this with zscripts, very interesting WingedOne, good luck with the vector maths!

enter
04-24-03, 11:39 AM
How to use Ray Traycing in Zbrush 1.55b?
I really like this feature when I saw it in Amorphium 3. Any tutorial in Zbrush?

Thanks

aurick
04-24-03, 11:47 AM
ZBrush does not have true raytracing. However, there are several things that simulate it or take partial advantage of raytracing.

Please see Pixolator's Post (http://www.pixolator.com/zbc-bin/ultimatebb.cgi?ubb=get_topic&f=1&t=010194&p=3) on reflections (along with some beautiful examples of it in use).

Also, check out the Lighting and Rendering page of the Quick Reference Guide (http://www.pixolator.com/zbc-bin/ultimatebb.cgi?ubb=get_topic&f=1&t=010737) for info on how to use Global Shadows (which are raytraced).

Frenchy Pilou
04-24-03, 02:47 PM
Hi Winged the one
Very abnegation way :cool:
After that are you project the radiosity ?
Pilou