Post

 Resources 

Console

Home | Profile | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 VBGamer
 VBGamer
 Problem with the DX4VB tutorial...
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

Trooper
Neophyte

6 Posts

Posted - Jul 03 2004 :  12:00:21 AM  Show Profile  Send Trooper an AOL message  Reply with Quote
I"m reading the DirectDraw tutorial on fullscreen.

In the first code he gives us...

  
Option Explicit 'DirectX likes all it's variables to be predefined  
  
Dim binit As Boolean 'A simple flag (true/false) that states whether we've initialised or not. If the initialisation is successful 'this changes to true, the program also checks before doing any drawing if this flag is true. If the initialisation failed and we 'try and draw things we'll get lots of errors...  
  
Dim dx As New DirectX7 'This is the root object. DirectDraw is created from this  
Dim dd As DirectDraw7 'This is DirectDraw, all things DirectDraw come from here  
Dim Mainsurf As DirectDrawSurface7 'This holds our bitmap  
Dim primary As DirectDrawSurface7 'This surface represents the screen - see earlier in the tutorial  
Dim backbuffer As DirectDrawSurface7 'This was mentioned earlier on...  
Dim ddsd1 As DDSURFACEDESC2 'this describes the primary surface  
Dim ddsd2 As DDSURFACEDESC2 'this describes the bitmap that we load  
Dim ddsd3 As DDSURFACEDESC2 'this describes the size of the screen  
  
Dim brunning As Boolean 'this is another flag that states whether or not the main game loop is running.  
Dim CurModeActiveStatus As Boolean 'This checks that we still have the correct display mode  
Dim bRestore As Boolean 'If we don't have the correct display mode then this flag states that we need to restore the display mode  
  


The part I"m having trouble with is the...

  
Dim ddsd1 As DDSURFACEDESC2 'this describes the primary surface  
Dim ddsd2 As DDSURFACEDESC2 'this describes the bitmap that we load  
Dim ddsd3 As DDSURFACEDESC2 'this describes the size of the screen  
  


I"m using DirectX7, but with VisualBasic.net 2003 Standard. Anyideas on how to accomplish this with .net?

Sr. Guapo
Swordmaster

USA
272 Posts

Posted - Jul 03 2004 :  12:22:45 AM  Show Profile  Reply with Quote
Have you added a reference to the directX7 for Visual Basic Library? You must do this in VB.NET (those tutorials are in VB6).

Go to Top of Page

Trooper
Neophyte

6 Posts

Posted - Jul 03 2004 :  12:49:59 AM  Show Profile  Send Trooper an AOL message  Reply with Quote
yes, i did
Go to Top of Page

Eric Coleman
Gladiator

USA
811 Posts

Posted - Jul 03 2004 :  01:35:19 AM  Show Profile  Visit Eric Coleman's Homepage  Reply with Quote
Are you getting some error message or something? The article won't list all of the code needed to make the program function properly. Only specific things are highlighted in the article, so you should probably look at the sample application to what you are missing. You should convert the sample application and not the article.
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
VBGamer © Go To Top Of Page
This page was generated in 0.11 seconds. Snitz Forums 2000

Copyright © 2002 - 2004 Eric Coleman, Peter Kuchnio , et. al.