Page 1 of 1
Started to code a SDL2 wrapper :)
Posted: Sat Oct 21, 2017 9:48 pm
by Mijikai
I started to code a wrapper (sort of) for SDL2
If someone wants to help me that would be great
How it looks so far:
No issues yet (i already can rotate/flip/transform/blend sprites~)

However im a bit worried about some datatypes like -> UInt32...
Re: Started to code a SDL2 wrapper :)
Posted: Sun Oct 22, 2017 1:44 am
by Lunasole
Oh good luck with that. I was trying somehow to code SDL wrapper but dropped it on 50% due to large size of library itself.
But well that was secondary reason, just except it I've realized that I can do what I need with built-in PB stuff.
> However im a bit worried about some datatypes like -> UInt32...
You can code for those unsigned types few simple functions in C, and embed them directly into SDL lib/dll. There was even topic on forum where it's already done, just add and export it:
http://www.purebasic.fr/english/viewtop ... 12&t=66217
Also somewhere was ASM stuff to deal with those types directly in PB.
Re: Started to code a SDL2 wrapper :)
Posted: Mon Oct 23, 2017 7:25 pm
by Fig
I wish it will work.
Hopefully, we will get rid of Pb's bugged sprite library that way...

Re: Started to code a SDL2 wrapper :)
Posted: Wed Oct 25, 2017 9:23 pm
by Mijikai
Lunasole wrote:Oh good luck with that. I was trying somehow to code SDL wrapper but dropped it on 50% due to large size of library itself.
...
...
You can code for those unsigned types few simple functions in C, and embed them directly into SDL lib/dll. There was even topic on forum where it's already done, just add and export it:
http://www.purebasic.fr/english/viewtop ... 12&t=66217
Also somewhere was ASM stuff to deal with those types directly in PB.
Thx, those links are helpful im @15% so it could take a while... its a shame that we even have to work around datatypes...
Re: Started to code a SDL2 wrapper :)
Posted: Wed Oct 25, 2017 9:54 pm
by Mijikai
Fig wrote:I wish it will work.
Hopefully, we will get rid of Pb's bugged sprite library that way...

I hope so...
There are pretty much no games (im not talking about card or board games) out there made with/in PB.
And its pretty obvious why...
Im not going to start a full rant...
however PB supports SDL... so pls at least give us direct access...
Re: Started to code a SDL2 wrapper :)
Posted: Thu Oct 26, 2017 7:54 am
by IceSoft
Maybe you can have a look on the SDL (v1.2.11) wrapper developed by Progi1984 found on
http://www.purearea.net:
RWSDL
v0.1 (Wrapper)
17.07.2007
Progi1984
Wrapper für die v1.2.11 der 'SDL' (Simple DirectMedia Layer) DLL.
http://www.purearea.net/pb/download/dll ... 1.2.11.zip
Re: Started to code a SDL2 wrapper :)
Posted: Wed Nov 22, 2017 3:08 pm
by IceSoft
any news?
Re: Started to code a SDL2 wrapper :)
Posted: Wed Jan 17, 2018 8:53 pm
by Poshu
Still no news I guess?
Anyway, I tried Progi1984's wrapper and...
WOW 2007!
Re: Started to code a SDL2 wrapper :)
Posted: Wed Mar 28, 2018 1:49 pm
by IceSoft
Account "Mijikai" seems to be no longer exsisting.
Re: Started to code a SDL2 wrapper :)
Posted: Wed Mar 28, 2018 6:46 pm
by Mijikai
IceSoft wrote:Account "Mijikai" seems to be no longer exsisting.
Im still here but this is no longer on my priority list.