openGL

Discussions related to graphics (2D and 3D), animation and games programming
Ric
Posts: 200
Joined: Tue 17 Apr 2018, 21:03

openGL

Post by Ric »

Evening all
Could someone please explain why i dont get a mode 1 with a prompt after this small section of code?
I get nothing, just a blank white screen with flashing curser.
Thanks

Code: Select all

      ON CLOSE PROCcleanup : QUIT
      ON ERROR PROCcleanup : SYS "MessageBox", @hwnd%, REPORT$, 0, 48 : QUIT

      SYS "LoadLibrary", "OPENGL32.DLL" TO opengl%
      MODE 1
      END

**** Sorry, premature question.

I am using BBCSDL, and get No Such System Call if I omit the ON CLOSE and ON ERROR lines.
I assume a different SYS statement is needed? I am used to BB4W and am struggling to get to grips with BBCSDL
Kind Regards Ric.

6502 back in the day, BB4W 2017 onwards, BBCSDL from 2023
Ric
Posts: 200
Joined: Tue 17 Apr 2018, 21:03

Re: openGL

Post by Ric »

I have now tried SYS"SDL_LoadLibrary", SYS"SDL_GL_LoadLibrary" as well to no avail!
I have looked in the reference in BBCSDL reference and followed the link to the SDL APIs but non of them look like "Loadlibrary", I am really stumped.
Please can some one help
Kind Regards Ric
Kind Regards Ric.

6502 back in the day, BB4W 2017 onwards, BBCSDL from 2023
Ric
Posts: 200
Joined: Tue 17 Apr 2018, 21:03

Re: openGL

Post by Ric »

The code i am using to test openGL is taken from here

BBC BASIC for Windows Programmers' Reference
(also for BBC BASIC for SDL 2.0)

It works fine in BB4W but fails in BBCSDL, but the title suggests its fpor BBCSDL as well?
Kind Regards Ric.

6502 back in the day, BB4W 2017 onwards, BBCSDL from 2023
Ric
Posts: 200
Joined: Tue 17 Apr 2018, 21:03

Re: openGL

Post by Ric »

The code i am using to test openGL is taken from here

BBC BASIC for Windows Programmers' Reference
(also for BBC BASIC for SDL 2.0)

It works fine in BB4W but fails in BBCSDL, but the title suggests its fpor BBCSDL as well?
Kind Regards Ric.

6502 back in the day, BB4W 2017 onwards, BBCSDL from 2023
User avatar
JeremyNicoll
Posts: 72
Joined: Sun 26 Jul 2020, 22:22
Location: Edinburgh

Re: openGL

Post by JeremyNicoll »

Ric wrote: Mon 08 Apr 2024, 17:14 The code i am using to test openGL is taken from here

BBC BASIC for Windows Programmers' Reference
(also for BBC BASIC for SDL 2.0)

It works fine in BB4W but fails in BBCSDL, but the title suggests its fpor BBCSDL as well?
In general ... there's no point in telling us you took code from "somewhere big with many pages". You'd need to say precisely where.

However, I sent you two private messages earlier in the day - have you not read them?
User avatar
JeremyNicoll
Posts: 72
Joined: Sun 26 Jul 2020, 22:22
Location: Edinburgh

Re: openGL

Post by JeremyNicoll »

JeremyNicoll wrote: Mon 08 Apr 2024, 20:09 However, I sent you two private messages earlier in the day - have you not read them?
Why ask for help and then ignore my messages? Or, have you got PMs disabled in your forum profile?

The gist of the messages is:

- Richard will help you if you email him directly.

- He thinks you should look at the demo openGL program, in: examples\graphics\opengl.bbc
(in the BBCSDL set of files, not the BB4W ones, of course)

- apart from the "Differences" page at: https://www.bbcbasic.co.uk/bbcsdl/differences.html
have you also read: https://www.bbcbasic.co.uk/bbcsdl/manual/bbcsdle.html
Ric
Posts: 200
Joined: Tue 17 Apr 2018, 21:03

Re: openGL

Post by Ric »

Thank Jeremy, as you guessed, I had not seen the PMs. I will look in the opengl.bbc example and hopefully this will progress things.
Kind regards Ric
Kind Regards Ric.

6502 back in the day, BB4W 2017 onwards, BBCSDL from 2023