Results 1 to 4 of 4

Thread: The RIGHT way of doing DX

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Aug 2001
    Location
    Eldwick, UK
    Posts
    17

    Exclamation The RIGHT way of doing DX

    I've been playing with DirectX in VB. I've even got a few meshes rendered, simple transforms etc. then i looked at the stuff in this forum.

    I then realised two things. One: that there is a right way of doing things. Two: that I was using the wrong one. I need to know how to do things properly.

    My code so far (see attached) doesn't use any of the commands/properties that anybody else's does. So, can someone start off and give me a few basic lessons on how it works? I'm pretty good with VB6 but I don't get how DirectX works. Things that I don't get:

    Surface - how to create, use, point of them? and how to make one primary.

    Video card - how to use it.

    Anything else you notice I lack knowledge in (like all of it) that you thought you'd better point out after looking at my screwy code....

    Thanks.
    Attached Files Attached Files

  2. #2
    Good Ol' Platypus Sastraxi's Avatar
    Join Date
    Jan 2000
    Location
    Ontario, Canada
    Posts
    5,134
    Are you using DD or D3D? If you are using Directdraw (DD) then here are some pointers. It's very easy to set up. Look at the
    "drawing a bitmap on the screen" tutorial at http://rookscape.com/vbgaming/. It teaches you how to set up DD without any junk.
    All contents of the above post that aren't somebody elses are mine, not the property of some media corporation.
    (Just a heads-up)

  3. #3
    Zaei
    Guest
    Actually, He is using DirectAnimation. The way you have your code set up is pretty much ok, for a small project like you have, but it is recommended that you Split up your code into sections, like Initialization, loading, etc, etc. This way, when your code gets bigger and more complicated, you can extend it easier. Probably most of the code you see here, that deals with DDraw, or D3D, or probably most of the BitBlt stuff, wont really apply to you. For example, where most games, etc, would have a large main loop, you have a call to DA.Start() which takes care of all of that for you. Hope these little tips help you out a bit.

    Z.

  4. #4

    Thread Starter
    Junior Member
    Join Date
    Aug 2001
    Location
    Eldwick, UK
    Posts
    17

    Thanks

    Thanks guys. Think I was a bit confused with what I was actually using. Seems to be working OK now.

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