Weird GLBasic problem

Previous topic - Next topic

Hatonastick

#15
Edit: Never mind.

makis

Downloaded the newest Nvidia and OpenGL 3 drivers and also I've installed GLBasic on another PC with no luck!
Heeelp pleeease:(

MrTAToad

#17
The last thing to try is :

Find smalfont.png from one of the examples (there are plenty, and it doesn't matter which one is used), and copy it into the same place as the executable.  Then compile & run the program.

Are you still getting a black screen ?

In addition, can you try the Hello World program from : http://www.nicholaskingsley.co.uk/MiscThings/HelloWorld.zip

Kitty Hello

You're opening the gbap, not gbas file, right? gbap = project, gbas = source code.

Try DRAWRECT 0,0,320,320, RGB(255,0,0)
Does that do a red square?

makis

Ok i give up. I'll tried everything you said guys (copying the png file to the glbasic folder, typing the rectangle command) but no luck. A small screen is being displayed for a split second and then back to the IDE.

Moru

You tried activating the debug mode? If you enter the command DEBUG "test" between each line you can see where the program hangs, like this:

Code (glbasic) Select

DEBUG "line 1\n"
PRINT "Hello world", 50, 50
DEBUG "line 2\n"
KEYWAIT
DEBUG "line 3\n"
END


The "line 1" and so on should show up in the gray part of the window on the bottom. (the \n in the strings is to get a line-break for each line printed)

makis

i've activated the debug mode and nothing happens. When i run the example the text "Loading" comes up in the middle of the screen and disappears instanly.

Kosta

Have you tried the example of Moru?


Code (glbasic) Select
DEBUG "line 1\n"
PRINT "Hello world", 50, 50
DEBUG "line 2\n"
KEYWAIT
DEBUG "line 3\n"
END


(activate Debug-Mode), execute it, and then -> take a look in your IDE (the Output Area (bottom)).... if all Debug-Lines are printed.
Intel QuadCore, Geforce8600GT,512MB,4GB Ram, 26" TFT
HP nw8440 Schläppy
GP2X Mk2 (Firmware 3.0)

GLBASIC Blog:
http://www.glbasic.com/forum/index.php?blog=51.0

makis

I get the following error mesage using moru's code:
Start debug session.
C:\DOCUME~1\TestPC\LOCALS~1\Temp\glbasic\gpc_tempg.cpp:4: error: `DGStr' does not name a type
C:\DOCUME~1\TestPC\LOCALS~1\Temp\glbasic\gpc_tempg.cpp:8: error: `NULL' was not declared in this scope
success


mr_x

#24
How did you create your project and source files? I mean try this: File->Project->New->Create new project, and then type simple programm and compile. Maybe this will help.

Hatonastick

#25
One possible idea is that something has gotten messed up somehow when you installed GLB (assuming that you do indeed have the latest version installed).  Uninstall it, make sure the directory for it in your program files directory has been deleted ie. c:\Program Files\GLBasic.  Also make sure that after you've uninstalled that the samples directory is gone from your My Documents directory too.  Download from the GLBasic website again and reinstall.  When you installed on your other PC, was it the same copy you'd already downloaded and installed or was it a fresh download and install?

Quick question: If you run any of the example games etc. in the Showroom on the official website, do they work?
eg. http://www.glbasic.com/data/games/UfoOnTheRun.rar
If you can't unpack RAR files, there are other programs in the showroom you can try.  Anyway, if so I think we can probably rule out the hardware side of things that we were looking at earlier.

Sorry if any of us are running over old ground.  We just want you to be able to compile too!

I'm now downloading the official GLB SDK from the website on another PC which has never had GLB installed on it.  Going to see if I can replicate the given errors.

Edit: Unsurprisingly the download from the official site onto another PC worked fine and I couldn't replicate the given errors.  Did have a few minor issues, but again unsurprisingly they went away when I applied the latest update.

Mr TAToad might be right.

MrTAToad

#26
It sounds like there is a serious problem with your machine as the program is exiting even if the MOUSEWAIT/KEYWAIT is present - even more so if the same thing happens when running the executable through Explorer.

Make sure DirectX is installed.

The next thing would be to create a new profile and try running the executable with that.

What version of Windows are you using ?

mr_x

Actually, if I download some glbasic programm, and try to compile it from it's project file, I've got the same result, something apears on the screen for a while, and disappear. But all the samples, that comes with GLBasic works fine on my machine. I have solved this problem, like I wrote above. I create new project, copy the code from downloaded example, and run it. It works for me.

makis

I'm running Widows XP with Sercive Pack 2. The compiled downloaded game run fine. I've unistalled everything , deleted the glbasic folders, removed the registry entries but no luck. Even when i copy and paste the code in a new project nothing changes.

I've installed GLBasic on my Acer Aspire One laptop runninh XP with SP2 and the same story goes on.. What is going on here grrr:(

MrTAToad

#29
So the executable runs fine if not run from GLBasic ?

The only thing left is to make sure you are using the latest version of GLBasic, and run the executable through the command line to look and see if there are any errors.

You need to compile in debug mode, move to the correct place for the executable, and then use something like : HelloWorld > log.txt

You should just get something like :

Code (glbasic) Select
FBO
Viewport
GFX seem OK
FBO
Viewport
GFX seem OK


What graphics cards do these two machines have ?