Results 1 to 6 of 6

Thread: [VB6] Kyodai's Raytracer

  1. #1

    Joined
    Dec 2011
    Posts
    15
    Userbars
    0
    Thanks
    0
    Thanked
    47/11
    Mentioned
    17 times
    Time Online
    4h 11m
    Avg. Time Online
    N/A

    [VB6] Kyodai's Raytracer

    I always wanted to have my own raytracer. Not as cool as 3D studio max or Maya, but still cool from a VB6 point of view i guess.

    The core is from VB Lover of VBFrance forums. He made the basic raytracing math and rendering engine, so most props go to him. Well i started making it more usable, adding material/Light/Objects editors, Image handling, file handling and so on. Some other parts from various sources in the internet.

    I kinda lost interest after it was half done, so the basics work, but for example the material editor shows existing materials but will not let you edit or add any. Same for the lights/objects editors, but at least the mat editor already does a neat rendered preview of the material. The texture projection for spheres is not really highly realistic, it's a classic projection instead of a classic mapping. The mathematical model for this could be overhauled. Also bump/texture settings should become a property of the material class, bump settings are global (yuck).

    Oh yeah and i wanted to add least add some half-asses animation scripting or at least a camera animation. Well never did it though.

    Also added a cute preview rendering function, menus, easier controls and a basic function to save the scene. I kinda stopped at the scene loading mechanism as first the fixed picturebox textures/bumps (hidden to end user, doh!) should be replaced by a neat file loader, file references in the class and so on before it really makes sense to finish the loader/saver. I made a basic save file model that is neat to base on as it's quite easy to load (HTML Tag style).

    SO that's left to do, also some cosmetic stuff like when you click render while it is still rendering it screws up and so on.

    What's really cool in here is the jpeg function which does NOT use a dll, so all JPEG compression/encoding stuff is done in pure VB6, try to find that elsewhere. Also it features common dialogues but doe not require the comdlg runtime references in windows as it's all made completely in VB6. Image postwork effects use GDI library, i always wanted to add some GDI-less effects but been to lazy to do so. Besides that it really doesn't have dependencies. I originally wanted to make a completely dependency free raytracer and completely in VB6. Maybe imma get to it later on again, but for the moment i got bored with it.

    I kinda wanna dedicate it to Joe so i won't post the source anywhere else.

    So enjoy and lemme know if you make any improvements to it. Oh and yay free picture of me as a texture, print out for your dart board!



    (you need an account to see links)

  2. The Following 2 Users Say Thank You to Kyodai For This Useful Post:

    DarkByte (07-17-2012),j03 (07-17-2012)

  3. #2
    Saiyan Race
    j03's Avatar
    Joined
    Dec 2011
    Posts
    13,722
    Userbars
    166
    Thanks
    5,907
    Thanked
    33,078/6,609
    DL/UL
    23/36
    Mentioned
    3,867 times
    Time Online
    563d 5h 38m
    Avg. Time Online
    3h 13m
    This is really interesting to look at. So much about working with images and whatnot, I really enjoy tracing these kinds of projects. Much props on this Kyodai!
    (you need an account to see links)
    (you need an account to see links)(you need an account to see links)

    ------------------------
    [02/24/2013] Stealth CORE is made into the first standalone Neopets auto-player.
    ------------------------


  4. #3
    Zachafer's Avatar
    Joined
    Dec 2011
    Posts
    1,235
    Userbars
    11
    Thanks
    769
    Thanked
    1,466/678
    DL/UL
    98/0
    Mentioned
    512 times
    Time Online
    24d 13h 9m
    Avg. Time Online
    8m
    Would be a ton nicer in VBNet (just my two cents)

  5. #4

    Joined
    Dec 2011
    Posts
    15
    Userbars
    0
    Thanks
    0
    Thanked
    47/11
    Mentioned
    17 times
    Time Online
    4h 11m
    Avg. Time Online
    N/A
    Pfffff, vb.net. I wouldn't be surprised if there's a raytracing class in .net anyways. But feel free to port it if you're bored.

  6. The Following User Says Thank You to Kyodai For This Useful Post:

    DarkByte (07-17-2012)

  7. #5

    Joined
    Dec 2011
    Posts
    15
    Userbars
    0
    Thanks
    0
    Thanked
    47/11
    Mentioned
    17 times
    Time Online
    4h 11m
    Avg. Time Online
    N/A
    Well it's a strict anti-.net project as the original challenge was to make it dependency free (hence the jpeg and comdlg classes). Still feel bad about adding the GDI effects option but they just looked so neat. I should kick these and add pure VB6 effects instead. I know .net is nice but this just ain't the challenge, adding a 100 MB (More or less depending on version of .net) framework to run a 2 MB app (including textures). And besides the JPEG and comdlg handling this would not have saved me much work i fear. Heck if i was a better programmer I'd rather make a 16-bit Win 3.0 app running in real mode.

  8. #6

    Joined
    Dec 2011
    Posts
    15
    Userbars
    0
    Thanks
    0
    Thanked
    47/11
    Mentioned
    17 times
    Time Online
    4h 11m
    Avg. Time Online
    N/A
    I don't like just everything having the microsoft brand name but imho some stuff is quite good. I still like the original "rapid form development" approach in VB which does spoil a bit of the "art" of programming GUIs by hand but it admittedly shortens development of some less complex apps. I also think with Version 2 onwards .net became quite powerful, with 4+ you now have such a shitload of classes that work fine, you can basically just "click together" rather complex appz while not even attempting do make low level functions, api references or classes yourself. I also like the VB syntax style. If you're a kinda native c++/java developer you'll prolly never wanna touch anything that won't require a ; or { but I still consider the syntax one of the best object oriented ones because of the simplicity.

    The only reason why i won't use BasicForAndroid instead of eclipse is that it lacks mainstream support from google for obvious reasons. But yeah i guess while you can generally argue about my programming skills i think it's save to say that my java and c++ skills are exceptionally poor.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •