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 / Difference betweem GDK and GDK.NET

Author
Message
Niels Henriksen
21
Years of Service
User Offline
Joined: 27th Sep 2004
Location: Behind you breathing heavely
Posted: 21st Nov 2007 12:12
I have just been trying GDK and was stuck because I coundnt print out ScreenFPS . I dont know how to convert int to char in C++

But another thing:

1) When moving the window of the application in GDK.NET the objects will dissapear and come back when the window is released... with GDK they are still visible...

2) Are there a cap in ScreenFPS with GDK? I know that there are in GDK.NET..

Niels Henriksen
Working on a (MMO)RPG right now in LightEngine
http://noggs.netopcom.dk/forum/default.asp - Forum for the game
HeavyAmp
19
Years of Service
User Offline
Joined: 25th Oct 2006
Location: Castle in the Sky!
Posted: 22nd Nov 2007 01:44
I had troubles with the FPS thing as well. Heres what I did. The Print Function doesn't like integers for some reason.



Better to be dead, than to live your life afraid.
CattleRustler
Retired Moderator
22
Years of Service
User Offline
Joined: 8th Aug 2003
Location: case modding at overclock.net
Posted: 22nd Nov 2007 02:27
dbPrint(FPS);

make FPS a string by wrapping it in a string function that converts a float to a string

My DBP plugins page is now hosted [href]here[/href]
Niels Henriksen
21
Years of Service
User Offline
Joined: 27th Sep 2004
Location: Behind you breathing heavely
Posted: 22nd Nov 2007 08:35
Quote: "make FPS a string by wrapping it in a string function that converts a float to a string"


I was trying to find out how to do that .. In .NET its so easy "ScreenFPS.ToString"

Niels Henriksen
Working on a (MMO)RPG right now in LightEngine
http://noggs.netopcom.dk/forum/default.asp - Forum for the game
Morcilla
23
Years of Service
User Offline
Joined: 1st Dec 2002
Location: Spain
Posted: 22nd Nov 2007 11:13
This also works for me:



To convert int to char, you could always use 'dbStr'...
RPDan
19
Years of Service
User Offline
Joined: 29th Apr 2007
Location:
Posted: 22nd Nov 2007 18:06
dbPrint is not overloaded to use an integer as a parameter. I think it accepts char*, double and LONGLONG (don't quote me on that). Because integers can automatically be converted to doubles or floats, you need to explicitly state which conversion operator you want to use.
Twisted Steel Software
19
Years of Service
User Offline
Joined: 21st May 2007
Location: Teh Interwebs
Posted: 23rd Nov 2007 05:55
try the DB way of doing it... dbStr(dbScreenFPS())

Intel Pentium 4 3.40 Ghz HT, 1.5 GB RAM, Nvidia Geforce 6800, 19" Dell CRT Monitor ... I need to upgrade ^-^

Login to post a reply

Server time is: 2026-07-25 16:50:09
Your offset time is: 2026-07-25 16:50:09