Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / using directX API commands in dark gdk?

Author
Message
tomba12
16
Years of Service
User Offline
Joined: 18th Dec 2007
Location:
Posted: 18th Dec 2007 21:45
how do i use the acutal directX GDK with DarkGDK? i want to know how i can create like 3d box, sphere , etc. using NORMAL direct X? anytime u draw, u need the "Ditect X Device"(pDevice) to connect to the program. how do u get this with dark gdk? i know u can do most things with dark gdk. but there are times where u need to create your own things... so is it possible for me to draw stuff from acutal direct X API commands? any sample code would be helpful. thank you for your time.
Lover of games
19
Years of Service
User Offline
Joined: 17th Apr 2005
Location:
Posted: 19th Dec 2007 07:19
To answer your question: Yes, it is possible. Just include this header

<globStruct.h>

theb use

dbGetDirect3DDevice();

then you call the function as normal like



and pick what ever command you want.

"Originally I was going to have a BS on it but you know how that would be. I can't walk around with the letters BS on me." More or less a qoute by Syndrome from Jack, Jack, attack
Try
20
Years of Service
User Offline
Joined: 16th Aug 2004
Location:
Posted: 19th Dec 2007 14:30 Edited at: 19th Dec 2007 14:32
All,
Does anybody know how to reset the device properly?

T.I.A
-Try
tempicek
16
Years of Service
User Offline
Joined: 27th Nov 2007
Location: Prague
Posted: 28th Dec 2007 14:04
Quote: "Does anybody know how to reset the device properly?"


If you want to do that using DirectX directly, you should do this:

1) Release all resources created in "DEFAULT_POOL", which basically means all render targets, depth buffers, swap chains and textures or buffers created in mentioned pool.

2) Call IDirect3DDevice9::Reset method (or dbGetDirect3DDevice()->Reset() to be precise)

3) Recreate all resources released in (1)
jason p sage
17
Years of Service
User Offline
Joined: 10th Jun 2007
Location: Ellington, CT USA
Posted: 28th Dec 2007 14:51
Wow - this is GREAT stuff! Now maybe I can try that DirectX snippet for texture blending with a pixel shader - it tells directx to render it backwards somehow... must revisit!

Pharoseer
17
Years of Service
User Offline
Joined: 21st Feb 2007
Location: Right behind you
Posted: 1st Jan 2008 04:23
Jason,

Check out this post that Visigoth just made! This'll make our terrain creation efforts a little smoother.

-Frank

http://forum.thegamecreators.com/?m=forum_view&t=114114&b=1
jason p sage
17
Years of Service
User Offline
Joined: 10th Jun 2007
Location: Ellington, CT USA
Posted: 1st Jan 2008 05:00
Wow. Hmm... Sahder, No Shader... AHHHH Beautiful Shots!

Login to post a reply

Server time is: 2024-11-19 23:18:53
Your offset time is: 2024-11-19 23:18:53