A Flash Developer Resource Site

Results 1 to 17 of 17

Thread: Realtime 3d rendering pipeline

  1. #1
    Senior Member
    Join Date
    Sep 2001
    Location
    bleh
    Posts
    276

    Realtime 3d rendering pipeline

    hi
    i have just summarised a whole bunch of algorithms
    of 3d Graphics rendering pipelines.

    http://www.video-animation.com/flash3d_003.shtml

    steve

  2. #2
    Life Member
    Join Date
    Jan 2003
    Location
    Australia
    Posts
    87
    how far do u think u will go with your 3d engine?

  3. #3
    Senior Member
    Join Date
    Sep 2001
    Location
    bleh
    Posts
    276
    i really dont know..

    i have to implement a camera..
    fix the lighting..
    frustum culling..
    texture on faces..
    collision detection..

    that should keep me off the streets for a while..
    :-)
    steve

  4. #4
    Life Member
    Join Date
    Jan 2003
    Location
    Australia
    Posts
    87
    ahh.. well i guess once u work out your camera you will now the PointOfView..

    from thereu can use my method if u want (i think its pretty quick). It was from he last thread, you find the pov unit vector and the point of an object (so its a vector too), then u find the dot product (..scalar..i forget.. im lazy) to get and angle value and if the angle value is less than, say 50 then u include it. As i said before it doesnt cull whats behind (as its like 2 cones) so you need near cliping code as well.. and you'll need to make the angle a bit bigger than the FOV/2 becuase it has to include the whole window around the circle/cone projection.

    collision will be possible but a lota code.. will it slow things down at all though?

    texturing seems hard. how will u do that? through transforms?

  5. #5
    Senior Member
    Join Date
    Sep 2001
    Location
    bleh
    Posts
    276
    hi o
    thanks for the offer of the code..i will have a look at it..
    i have no idea about collision detection in 3d
    but i better learn fast.. and i think it probably will be expensive..
    but maybe if you use bounding boxes, then it might cut it down heaps..
    but again i dont know how to do them yet...
    and again for textures,, i have no idea how to do them..

    i cant do anything !!! LMAO...
    i guess i will tackle each hurdle as i come to it..
    i am porting a C engine to flash at the moment..
    and pulling it apart to see how it ticks and putting it
    back together in flash..
    i might learn the above questions in the process..
    i hope to..
    see ya
    steve

  6. #6
    Life Member
    Join Date
    Jan 2003
    Location
    Australia
    Posts
    87
    could you email me that c++ 3d engine please?

  7. #7
    free-webmaster-resource.com deamothul's Avatar
    Join Date
    Apr 2003
    Location
    Netherlands
    Posts
    1,475
    hiya F

  8. #8
    Senior Member
    Join Date
    Sep 2001
    Location
    bleh
    Posts
    276
    hey d:
    what ya up to?
    steve

  9. #9
    free-webmaster-resource.com deamothul's Avatar
    Join Date
    Apr 2003
    Location
    Netherlands
    Posts
    1,475
    hehe, same old same old

    i've been playing a bit with vectors and forces lately and still trying to understand the lighting pieces

    seeYa mate

  10. #10
    Senior Member
    Join Date
    Sep 2001
    Location
    bleh
    Posts
    276
    hi d:
    lighting is basically the angle between the plane normal and
    the line from the light to the plane..
    so if the angle is 90 degrees the lighting is max and if it is
    0 or 180 , then it is 0 or min ..
    everything else will be backface culled..
    the trick is how to make the colors brighter and darker..
    that is the part i havent got sussed yet..
    i think maybe
    have a base color say,, rgb(200,100,100)..
    then the remainder percent gets darkened or lightened...
    hmmm maybe... i dont get it either.. LOL..
    but then maybe just have the above in percentage of the brightness..

    e.g. 1.0 or 100% = 200 red etc..
    .5 or 50% might be rgb(100,50,50). ????
    that seems the best..
    still not right... you need to preserve the ratio between
    r, g, b....
    how do you do that ??
    bloody maths...
    seey a s
    teve

  11. #11
    free-webmaster-resource.com deamothul's Avatar
    Join Date
    Apr 2003
    Location
    Netherlands
    Posts
    1,475
    Originally posted by ferdymania
    hi d:
    lighting is basically the angle between the plane normal and
    the line from the light to the plane..
    so if the angle is 90 degrees the lighting is max and if it is
    0 or 180 , then it is 0 or min ..
    everything else will be backface culled..
    i see Steve, thanks mate, again a little piece closer to the real deal

    Originally posted by ferdymania

    the trick is how to make the colors brighter and darker..
    that is the part i havent got sussed yet..
    i think maybe
    have a base color say,, rgb(200,100,100)..
    then the remainder percent gets darkened or lightened...
    hmmm maybe... i dont get it either.. LOL..
    but then maybe just have the above in percentage of the brightness..
    e.g. 1.0 or 100% = 200 red etc..
    .5 or 50% might be rgb(100,50,50). ????
    that seems the best..
    still not right... you need to preserve the ratio between
    r, g, b....
    how do you do that ??
    bloody maths...
    true mate, thats still a great idea i'll also have a stare at the lighting again this evening(hehe just like everyday almost this week), but i doubt if i'll make any progress....i suck at this
    i keep going in circles, hehe, gotta love it
    like ya said .. bloody math bigtime.

    seeYa laterz mate

  12. #12
    Senior Member
    Join Date
    Sep 2001
    Location
    bleh
    Posts
    276
    sorry..
    the angle would be 0 degrees with the normal..
    or 90 degrees to the plane... doh !
    you know what i mean...
    doh !

  13. #13
    free-webmaster-resource.com deamothul's Avatar
    Join Date
    Apr 2003
    Location
    Netherlands
    Posts
    1,475
    hehe, i know what ya mean

  14. #14
    Life Member
    Join Date
    Jan 2003
    Location
    Australia
    Posts
    87
    did you look at my code for lighting?

    to make the colour brighter or darker i just * by the intensity of the light.

    like; red = red_face * intensity;
    and for green and blue..

    where intensity is 0->1;

    also.. for volumetric fade off.. i just calculate the new intensity with respect to the distance..

    u know.. the formula i = k/(d*d);

    i should be posting my newer code soon

  15. #15
    free-webmaster-resource.com deamothul's Avatar
    Join Date
    Apr 2003
    Location
    Netherlands
    Posts
    1,475
    you know your stuff mate

  16. #16
    Senior Member
    Join Date
    Sep 2001
    Location
    bleh
    Posts
    276
    hiya ross and d:
    yes the lighting is pretty similar to what i have..
    excepth for the distance .. i havent implemented that yet..
    i havent had a good look at your code yet..

    i am going to start a new thread and put up my requirements doc
    for a redesign of the engine..
    please add comments..

    should be fun..
    steve

  17. #17
    free-webmaster-resource.com deamothul's Avatar
    Join Date
    Apr 2003
    Location
    Netherlands
    Posts
    1,475
    good idea steve

Posting Permissions

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




Click Here to Expand Forum to Full Width

HTML5 Development Center