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 .NET / Can I create a DBP window instead of Viewport?

Author
Message
RanQor
16
Years of Service
User Offline
Joined: 8th Jun 2007
Location:
Posted: 9th Feb 2009 01:47
I'm really confused by why GDK.NET uses a Component "Viewport" to render the DirectX to.

What I'm looking to do is create a window similar to GDK/DBP. The reason is because DirectX hooking applications like Fraps and iZ3D do not work when the directx is rendered inside a component/viewport of the form.

Does anyone know how to create a GDK/DBP type window? Is it even possible?
Niels Henriksen
19
Years of Service
User Offline
Joined: 27th Sep 2004
Location: Behind you breathing heavely
Posted: 9th Feb 2009 11:00
Yes its possible. I have done that by myself. I will later make a guide you can use.

Niels Henriksen
www.tales-of-the-realms.com
if Microsoft can sell software with bugs, so can I.
RanQor
16
Years of Service
User Offline
Joined: 8th Jun 2007
Location:
Posted: 9th Feb 2009 13:49 Edited at: 9th Feb 2009 13:54
Thank you that would be awesome!

Now if only we could get TGC to add a second GDK.NET Project Template that automatically does it when you start a new project.
veltro
User Banned
Posted: 9th Feb 2009 14:51
Quote: "Now if only we could get TGC to add a second GDK.NET Project Template that automatically does it when you start a new project."


Once you get it, I think you can save your template
Globbits
15
Years of Service
User Offline
Joined: 30th Jan 2009
Location: Cambridge
Posted: 9th Feb 2009 16:23
You can do this by calling DarkGDK.Engine.InitializeGDK();

e.g.

Hayer
18
Years of Service
User Offline
Joined: 4th Nov 2005
Location: Norway
Posted: 9th Feb 2009 18:23
Why not make a template for the community insted Niels Henriksen?

RanQor
16
Years of Service
User Offline
Joined: 8th Jun 2007
Location:
Posted: 10th Feb 2009 02:13
Just tried:



DirectX hooking still does not work , I dont think its exactly the same as a normal directx window that GDK/DBP uses.
Niels Henriksen
19
Years of Service
User Offline
Joined: 27th Sep 2004
Location: Behind you breathing heavely
Posted: 10th Feb 2009 12:06
Done....

http://forum.thegamecreators.com/?m=forum_view&t=145054&b=37&p=0

But only VB and VS2008

Niels Henriksen
www.tales-of-the-realms.com
if Microsoft can sell software with bugs, so can I.
RanQor
16
Years of Service
User Offline
Joined: 8th Jun 2007
Location:
Posted: 19th Feb 2009 03:54 Edited at: 19th Feb 2009 04:01
The window is still not allowing a normal DirectX Hooking application to hook into it. I wonder whats different about this application versus the GDK or DBP applications.

If DarkGDK.NET had the "set cameras to stereoscopic" function (reference) I wouldn't need to have a directX hook. I'm trying to get the iZ3D driver to hook into it.

O btw, is there anyway to get rid of that console window? If not, is it something that TGC can remove with an update or is it a limitation set by the visual/.net framework?
Niels Henriksen
19
Years of Service
User Offline
Joined: 27th Sep 2004
Location: Behind you breathing heavely
Posted: 19th Feb 2009 19:39
Console.Close?

Niels Henriksen
www.tales-of-the-realms.com
if Microsoft can sell software with bugs, so can I.
RanQor
16
Years of Service
User Offline
Joined: 8th Jun 2007
Location:
Posted: 20th Feb 2009 04:17 Edited at: 20th Feb 2009 04:26
There is no Console.close, and I think the console window has to stay open for the darkgdk app to run, so the only way was to Hide it.

The attached new template has:
No Viewport
Hidden Console Window
Vista 64-bit safe (x86 build)

To install this template place the zip file here:
[MyDocuments]\Visual Studio 2008\Templates\Project\Templates\Visual Basic\

Unfortunatly that still doesn't fix my DX hooking issue, maybe I'll just have to wait for the 7.2 update.

Attachments

Login to view attachments
Diggsey
17
Years of Service
User Offline
Joined: 24th Apr 2006
Location: On this web page.
Posted: 8th Mar 2009 23:06
Why not just create an empty project, and then set the start-up object in the project settings to 'sub Main'.

Then create a code file containting:


I don't have GDK.net so I can't test it, but running just that works and there is no console or form

[b]Yuor signutare was aresed by a deslyxic mud...
BOX2D V2 HAS HELP FILES! AND A WIKI!
APEXnow
Retired Moderator
21
Years of Service
User Offline
Joined: 15th Apr 2003
Location: On a park bench
Posted: 11th Mar 2009 03:50
Clearly, the problem is in documentation. It is possible to create a normal DGDK window without any component by changing the properties of the DarkGDK.NET viewport control. By default, the control creates an embedded window of the main form. If you go into your form's design mode and select the viewport control to see it's properties, there are four main properties that define how DarkGDK.NET starts up, these can be found under the DarkGDK property category:

Embedded (Boolean)
FullScreen (Boolean)
GraphicsMode (Video resolution)
SyncRate (Sync Frequency)

By changing the first two properties, this changes the behaviour on how the main window is created.

If Embedded is true, you will always get the Viewport control to override the form for displaying the 3D view of DarkGDK in a subwindow, i.e. the viewport control itself. (Note, the embedded flag overrides the Fullscreen flag)

If embedded is false, the fullscreen flag determines the initial behaviour of the window that DarkGDK.NET creates. If fullscreen is true, you will see the application flip into fullscreen mode based on the GraphicsMode property resolution. If fullscreen is set to false, the window will still be created, but fullscreen will not be activated, you will merely see the initial DarkGDK.NET window appear with the specified GraphicsMode resolution based

If Embedded is true, the fullscreen property is ignored.

Hope this helps for now.

Paul.

MoomanFL
18
Years of Service
User Offline
Joined: 12th Nov 2005
Location:
Posted: 11th Mar 2009 05:33
APEX,

I was aware of those properties, but have only tried to change one: Fullscreen.

Changing that to "True" did absolutely nothing. To actually make it fullscreen I had to put "DarkGDK.Display.Fullscreen = True" in the GameLoop function. Not sure if the other Viewport properties are bugged the same way.

Design documents?!? What design documents??? I thought we were just going to wing it!!!
Diggsey
17
Years of Service
User Offline
Joined: 24th Apr 2006
Location: On this web page.
Posted: 11th Mar 2009 20:12
@MoomanFL
As APEXnow just said, you have to change Embedded to false or it will override the full-screen setting.

[b]Yuor signutare was aresed by a deslyxic mud...
BOX2D V2 HAS HELP FILES! AND A WIKI!
MoomanFL
18
Years of Service
User Offline
Joined: 12th Nov 2005
Location:
Posted: 12th Mar 2009 00:02
Sorry, was stuck on stupid. I read the post and it just didn't register. I need to remember to sleep before posting.

Design documents?!? What design documents??? I thought we were just going to wing it!!!

Login to post a reply

Server time is: 2024-04-19 05:18:02
Your offset time is: 2024-04-19 05:18:02