Thread: DirectX Particles?

  1. #1
    I am he who is the man! Stan100's Avatar
    Join Date
    Sep 2002
    Posts
    361

    DirectX Particles?

    Without using bitmaps, can dx do particles. I say this with reference to GameTutorials' tutorial on OpenGL particles. REAL LOOKING PARTICLES! Not bitmaps, or nice looking pixel arrangements, but something professional looking.

    Which leads me to another question: How come there are so little DX tutorials, but OpenGL has some many. Is OGL really THAT much easier?
    Stan The Man. Beatles fan

    When I was a child,
    I spoke as a child,
    I thought as a child,
    I reasoned as a child.
    When I became a man,
    I put childish ways behind me"
    (the holy bible, Paul, in his first letter to the Cor. 13:11)

  2. #2
    using namespace Trooper; St0rmTroop3er's Avatar
    Join Date
    Sep 2003
    Posts
    77
    You can do particles with DX. I"m not sure how... yet.

    There a few tuts online. I suggest getting a book if you want to learn Direct X.



    ~Trooper
    Your mom is like a struct, she has no class

    How many C programmers does it take to screw in a light bulb? One to do it, 99 to tell him how to do it faster.

  3. #3
    Pursuing knowledge confuted's Avatar
    Join Date
    Jun 2002
    Posts
    1,916
    Yeah, sure. Just do small triangles (or quads) with a material property set specifying color.

    The DX SDK comes with documentation which is fairly good, and there are a couple good tutorials online. OpenGL is older and such, so there is more amature documentation. Check out the Two Kings DX tutorials, though; they're good. Steer clear of NeXe. Check the links in the sticky.
    Away.

  4. #4
    Registered User
    Join Date
    Apr 2002
    Posts
    1,571
    Try looking up:

    The ID3DXSprite Interface

    and

    Point Sprites

    This all depends on what version of DX you are using to. Make sure you check hardware capabilities for point sprites.
    "...the results are undefined, and we all know what "undefined" means: it means it works during development, it works during testing, and it blows up in your most important customers' faces." --Scott Meyers

  5. #5
    I am he who is the man! Stan100's Avatar
    Join Date
    Sep 2002
    Posts
    361
    so I'm assuming this is in all d3d.

    I'm not too good in dx right now. (i'm in dx, and I'm making a 2d scroller)

    sry for the bad typing, but I have to get off b4 the teacher sees me not doing the "project". (a stupid word doc on T.S. Eliot)
    Stan The Man. Beatles fan

    When I was a child,
    I spoke as a child,
    I thought as a child,
    I reasoned as a child.
    When I became a man,
    I put childish ways behind me"
    (the holy bible, Paul, in his first letter to the Cor. 13:11)

  6. #6
    Pursuing knowledge confuted's Avatar
    Join Date
    Jun 2002
    Posts
    1,916
    Are you using the old DirectDraw interface, or is D3D stuff okay?
    Away.

  7. #7
    Registered User VirtualAce's Avatar
    Join Date
    Aug 2001
    Posts
    9,607
    If you are doing a 2D scroller the having Direct3D texture quads for you would be ideal. Check out www.gamedev.net in their Articles and Resources->Isometric/Tile Based Games->Using Direct3D to Render 2D tiles.

    Point sprites really could not be used with this method since you are telling Direct3D that your vertex has already been transformed. None of the lighting functions will work either - you must manually create the lighting using the rhw coefficients, etc. Really everything boils down to being a textured quad thats always facing the viewer - cuz if they don't they look very ugly. They are not billboards per se in the fact that they do not need to be rotated to face the viewer, but they are based on the same principle.

    Mess around with gamedev's code for a bit and you will see what I mean. If you have problems with it I have a fully functional small tile engine (just needs tiles) that will illustrate what I'm trying to say.
    Still working on the lighting portion of the engine.

  8. #8
    Grammar Police HybridM's Avatar
    Join Date
    Jan 2003
    Posts
    355
    Start -> programs -> DirectX -> Sample browser -> C++/D3D/Samples scroll down to point sprites.
    Thor's self help tip:
    Maybe a neighbor is tossing leaf clippings on your lawn, looking at your woman, or harboring desires regarding your longboat. You enslave his children, set his house on fire. He shall not bother you again.

    OS: Windows XP
    Compiler: MSVC

  9. #9
    I am he who is the man! Stan100's Avatar
    Join Date
    Sep 2002
    Posts
    361
    I'm saving this post on my computer for future reference. Sadly, though, I'm using the old Dx interface. When I'm done this game, should I move onto d3d or d3d 2-d style?
    Stan The Man. Beatles fan

    When I was a child,
    I spoke as a child,
    I thought as a child,
    I reasoned as a child.
    When I became a man,
    I put childish ways behind me"
    (the holy bible, Paul, in his first letter to the Cor. 13:11)

  10. #10
    using namespace Trooper; St0rmTroop3er's Avatar
    Join Date
    Sep 2003
    Posts
    77
    in DX 8.0+ its Direct Graphix, both Dx3d and dx draw are combined in 1.8+.



    ~Trooper

    I have DX9.0 SDK if you need it.
    Your mom is like a struct, she has no class

    How many C programmers does it take to screw in a light bulb? One to do it, 99 to tell him how to do it faster.

  11. #11
    Pursuing knowledge confuted's Avatar
    Join Date
    Jun 2002
    Posts
    1,916
    The DX SDK is free from Microsoft... why would he need to get it from you?
    Away.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Isometric Tile Engine using DirectX
    By Wraithan in forum Game Programming
    Replies: 3
    Last Post: 07-17-2006, 12:16 PM
  2. DirectSound header issues
    By dxfoo in forum C++ Programming
    Replies: 0
    Last Post: 03-19-2006, 07:16 PM
  3. DirectX - Starting Guide?
    By Zeusbwr in forum Game Programming
    Replies: 13
    Last Post: 11-25-2004, 12:49 AM
  4. DirectX 8 with Borland
    By Tommaso in forum Game Programming
    Replies: 11
    Last Post: 08-12-2003, 09:30 AM
  5. Directx SDK Documentation
    By Zoalord in forum Game Programming
    Replies: 4
    Last Post: 05-08-2003, 06:07 AM