A Flash Developer Resource Site

Results 1 to 9 of 9

Thread: A 3d engine in flash?

  1. #1
    Junior Member
    Join Date
    Dec 2005
    Posts
    18

    A 3d engine in flash?

    How can I make a 3d engine in flash? Bare in mind that I do want the camera to be moved and rotated. Any help will be appreciated.

  2. #2
    supervillain gerbick's Avatar
    Join Date
    Jul 2000
    Location
    undecided.
    Posts
    18,986
    It's going to take a lot of complicated math and ActionScript...

    3DFS is an establish 3D flash engine, and there's a few others that exist. But from scratch... how comfortable are you with AS?

    [ Hello ] | [ gerbick ] | [ Ω ]

  3. #3
    imagination through stupidity
    Join Date
    Apr 2001
    Location
    P3X-3113
    Posts
    1,238
    Quote Originally Posted by lemming77
    How can I make a 3d engine in flash? Bare in mind that I do want the camera to be moved and rotated. Any help will be appreciated.
    if you don't have a strong programing background you won't be able to make anything like that in any language from scratch. something like a 3d engine takes a lot of planning and thought, best wishes.

    i'm pretty sure there are some books on 3d engines in C or JAVA, check those out.
    Nothing to see here, move along.

  4. #4
    Junior Member
    Join Date
    Dec 2005
    Posts
    18
    To asnwer your question, Gerbick, I'm quite comfortable with AS. I've got a 3d engine going, now, but I do have one last question. Is there a way to deform a bitmap using AS? Like with the free transform tool?

  5. #5
    imagination through stupidity
    Join Date
    Apr 2001
    Location
    P3X-3113
    Posts
    1,238
    flash 8 gives us various bitmap filters and whatnot. check out BitmapData, BitmapFilter, BlurFilter and DisplacementMapFilter
    Nothing to see here, move along.

  6. #6
    Junior Member
    Join Date
    Dec 2005
    Posts
    18
    Well, although that sounds helpful, I'm still on flash MX 2004. Any other suggestions?

  7. #7
    Senior Member
    Join Date
    Nov 2003
    Posts
    524
    If you want something fast enough for a 3D engine then you are pretty much stuck with triangle patches or quad patches made from 2 triangles. This can be done with very basic 2D vector math pretty simple stuff if you've already built a 3D engine. If you hope to render any reasonable number of faces I would suggest that you use the standard actionscript used for a MovieClip perspective transform and adapt it to tri strips, otherwise your rendering engine will be performing about 30% more work.
    Also it pays to keep in mind while developing your transform function ...that ... creating a seamless meshes is almost impossible even using a dynamicly calculated masking coefficient, a RGBA lighting model works with tri's but has problems with quads due to the overlapping MovieClips. It really pays if you have built your engine with faces having indices into an objects vertice and line list otherwise optimizing Texture Mapping would be very difficult.

    Hope these thoughts save you some work

  8. #8
    imagination through stupidity
    Join Date
    Apr 2001
    Location
    P3X-3113
    Posts
    1,238
    wait for AS3 where we have access to DisplayList
    Nothing to see here, move along.

  9. #9
    Junior Member
    Join Date
    Dec 2005
    Posts
    18
    Alright, then. Thanks.

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