Page 1 of 10

PureBasic 6.20 is out !

Posted: Wed Dec 11, 2024 5:15 pm
by Fred
Hello everybody,

2025-02-12: the final version is out ! Thanks all for the feebacks !

2025-01-30: the beta 4 is out with a switch to enable Wayland support on Linux (not very tested, OpenGLGadget, Sprites and OGRE won't work) and some more fixes !

Code: Select all

- Added Wayland support for Linux (in Compiler Option in the IDE or using the "-wl" or "--wayland" commandline switch)
Bugfixes for this version:This list was created automatically. All updated bug threads from the date of the last final version have been determined.

2025-01-17: Happy New Year everyone ! The 6.20 beta 3 is available for testing and comes some new stuffs with more fixes:

Code: Select all

- Added QT based IDE on Linux (thanks Fr34k) ! It's still early stage and could be unstable, feedback is welcome. Another prefs file is used (purebasic_qt.prefs) as some saved values aren't compatiable with the GTK version.
- Added external colorscheme support for the IDE to easily share them (thanks Kenmo !)
- Added string above 2GB support for 64-bit versions of PureBasic. Such big strings will be probably slow to handle, but it could be useful for simple operations.

Bugfixes for this version:This list was created automatically. All updated bug threads from the date of the last final version have been determined.

2024-12-20: Happy Holidays ! Beta 2 is out with more fixes ! I forgot to thanks the IDE contributors for this version, so here we go !

Peter Dreisiebner for the nice multicolored procedure list (check the prefs as well to configure it)
Erlend for various dark mode fixes on Linux
ChrisR for tooltip rework
Kenmo for various improvements and fixes

Bugfixes for this version:This list was created automatically. All updated bug threads from the date of the last final version have been determined.

Christmas is near, so is the next major version of PureBasic ! This release is a major step to keep PureBasic updated and relevant for the future, with the big update of OGRE 3D (to the lastest version, including all its dependencies for all OS) and the new Windows arm64 support. It also features some highly expected commands like TLS sockets and native PureLibrary creation directly using PureBasic ! Changes:

Code: Select all

- Updated: OGRE 3D to lastest 14.3 version (big thanks for the help Pf Shadoko) !
- Added: Windows 11 arm64 support !
- Added: TLS support for Network library (Thanks Idle for the tips) !
- Added: PureLibrary creation in PureBasic (C Backend only) !
- Added: WebWiewProxy() to enable proxy support (Sponsored by Kukulkan)
- Added: #PB_Editor_TabNavigation support to EditorGadget() (Sponsored by Quin)
- Added: #PB_Entity_InheritScale support Get/SetEntityAttribute()
- Added: DLL support to UsePostgreSQL() (Sponsored by wayne-c)
- Added: Windows 10+ mode to link directly to UCRT.dll to have smaller executables and up-to-date CRT
- Added: IsPack()
- Added: PureBasic-CLI.cmd to easily open a commandline environment (Windows)

Ogre3D changes:

Code: Select all

- Added: Get/SetWorldAttribute() to control water and sky
- Optimized: BuildMeshLOD() now uses a much better algorithm for automatic lod creation
- Modified: SaveRenderTexture() -> only .png format is supported
- Modified: reworked SkyDome() and CreateWater() fonction to have better and faster rendering
- Modified: Add3DArchive() always needs to be after OpenScreen()
- Modified: filenames are now case-sensitive even on Windows and OS X
- Removed: Sun() has been removed -> replacement with CreateLight()
- Removed: LoadWord() which was based on old BSP tech
- Removed: WaterHeight()
- Removed: SwitchCamera() which makes no sense

Example to create a PureLibrary

Code: Select all

DisablePureLibrary Test ; Needed to avoid function conflict if the lib is already loaded

Global Test$
Global NewMap a()

Procedure InitPureLibrary()
  MessageRequester("Init","Init")
EndProcedure

Procedure FreePureLibrary()
  MessageRequester("End","End")
EndProcedure


;  QuickHelp  MyMax(Min [, Max [, Flags, Mode]]) - A standard min/max function
ProcedureDLL MyMax3(a, b, c, d)
  Static cc = 16
  Test$ = "Hello"
  ProcedureReturn OpenWindow(#PB_Any, 10, 10, 200, 200, "Test")
EndProcedure

ProcedureDLL MyMax2(a, b) ; version 2, 3, 4 .... allow to create optional parameter functions (PureBasic default values are not accepted)
  ProcedureReturn MyMax3(a, b, 0, 0)
EndProcedure

ProcedureDLL MyMax(a)
  ProcedureReturn MyMax2(15, 20)
EndProcedure

; QuickHelp GetTest() - Returns the test content
ProcedureDLL.s GetTest()
  ProcedureReturn Test$+Right(" World", 4)
EndProcedure

ProcedureDLL.s GetFloat(a.f, b.i, c.d)
  ProcedureReturn StrF(a) + ", "+ Str(b)+ ", "+StrD(c)
EndProcedure

ProcedureDLL.s GetString(a$, b$, c.d, d$)
  ; MessageRequester(a$ + b$ + c + d$, "")
  ProcedureReturn a$ + b$ + " " + c +" " + d$
EndProcedure


ProcedureDLL GetArray(Array myArray(1))
  ReDim myArray(20)
  a = myArray(3)
  ProcedureReturn ArraySize(myArray())
EndProcedure

ProcedureDLL GetList(List myList())
  AddElement(myList())
  AddElement(myList())
  ProcedureReturn ListSize(myList())
EndProcedure

ProcedureDLL GetMap(Map myMap())
  AddMapElement(myMap(), "Test")
  AddMapElement(myMap(), "Test2")
  AddMapElement(myMap(), "Test3")
  ProcedureReturn MapSize(myMap())
EndProcedure

ProcedureDLL.d GetDouble(a.d, b.d)
  b$ = "World"
  a$ = GetString("aaa", "bbb"+b$, 4545, b$+b$)
  
  ProcedureReturn a*b
EndProcedure
For now, it can only be compiled using the commandline, with the C backend.

On Windows, open PureBasic-CLI.cmd (On Windows arm64, use 'pbcompiler' instead of 'pbcompilerc'):

pbcompilerc LibTest.pb --purelibrary --output Test

On Linux/OSX/Raspberry, set the PUREBASIC_HOME variable to your PureBasic root installation and add $PUREBASIC_HOME/compilers to the PATH. On Linux x86 or Linux x64, use 'pbcompilerc' instead of 'pbcompiler'.

pbcompiler LibTest.pb --purelibrary --output Test

If all goes well, you should have your new library installed and after a compiler restart you should be able to test it.

There is some limitation for PureBasic purelibrary:
- No debugger support (in progress)
- All functions are compiled in the same object, which means the library will always includes all the functions in the final executable.
- No help support (in progress)


Don't hesitate to check the new 3D examples, there is some cool stuff from Pf Shadoko here !

Bugfixes for this version:This list was created automatically. All updated bug threads from the date of the last final version have been determined.


Have fun and enjoy the end of years parties !

The Fantaisie Software Team

Re: PureBasic 6.20 beta 1 is out !

Posted: Wed Dec 11, 2024 5:32 pm
by thyphoon
🥳🥳🥳 Thanks !

It's Christmas before time 🎁🎁🎁

Re: PureBasic 6.20 beta 1 is out !

Posted: Wed Dec 11, 2024 5:45 pm
by skinkairewalker
Man, only purebasic can make me emotional at this moment in my life. I'm in the worst moment of my life (due to financial instability and almost losing my job)

I was definitely expecting some improvement in OGRE... and voila!

How much I love Fred, along with the purebasic team and everyone who helped and sponsored. I am very grateful to everyone!

I consider TODAY the best day of this year for me!

Re: PureBasic 6.20 beta 1 is out !

Posted: Wed Dec 11, 2024 6:02 pm
by Caronte3D
Wow! :shock:
Thank you very much! :wink:

Re: PureBasic 6.20 beta 1 is out !

Posted: Wed Dec 11, 2024 6:17 pm
by Seymour Clufley
Thank you very much, Fred and the PB team, and merry Christmas!

Re: PureBasic 6.20 beta 1 is out !

Posted: Wed Dec 11, 2024 6:22 pm
by skywalk
Very Cool!
How do you invoke a user created lib?
Where do we place the lib?

Thanks for PureBasic!

Re: PureBasic 6.20 beta 1 is out !

Posted: Wed Dec 11, 2024 6:30 pm
by miso
Thank you Fred, Pf_Shadoko, Idle, Kukulkan, Quin, wayne-c, ;)
Time for me to upgrade ;)

Re: PureBasic 6.20 beta 1 is out !

Posted: Wed Dec 11, 2024 6:59 pm
by Quin
Weee! Thanks Fred! Time to test! :)

Re: PureBasic 6.20 beta 1 is out !

Posted: Wed Dec 11, 2024 7:05 pm
by Fred
skywalk wrote: Wed Dec 11, 2024 6:22 pm Very Cool!
How do you invoke a user created lib?
Where do we place the lib?

Thanks for PureBasic!
It's created in the purelibraries/userlibraries dir and loaded automatically

Re: PureBasic 6.20 beta 1 is out !

Posted: Wed Dec 11, 2024 7:10 pm
by STARGÅTE
Thank you very much.


I tried to create a user lib, but the output is:
C:\Program Files\PureBasic620>pbcompilerc Random.pb --purelibrary --output Random
PureBasic 6.20 Beta 1 - C Backend (Windows - x64)
Compiling Random.pb
Loading external libraries...
Starting compilation...
47 lines processed.
Creating threaded version of the PureLibrary...
Starting compilation...
47 lines processed.
Error: Linker
Error at line 22: Can't create the library file:
C:\Program Files\PureBasic620\purelibraries/userlibraries/Random
Probably because the program has no write permission in program files.

However, when I start it with admin mode, the message is:
C:\Program Files\PureBasic620>pbcompilerc Random.pb --purelibrary --output Random
--purelibrary: Unknown switch

Re: PureBasic 6.20 beta 1 is out !

Posted: Wed Dec 11, 2024 7:35 pm
by skywalk
Ok, that is why I do not install in "C:\Program Files" folder.
I install to "C:\PureBasic-x64\", "C:\PureBasic-x64-beta1\", etc.

Re: PureBasic 6.20 beta 1 is out !

Posted: Wed Dec 11, 2024 7:51 pm
by Drone
Hi !
Thank you very much, Fred and team... :D

Re: PureBasic 6.20 beta 1 is out !

Posted: Wed Dec 11, 2024 8:12 pm
by Fred
True, I will add a way to store the userlibs in appdata as well

Re: PureBasic 6.20 beta 1 is out !

Posted: Wed Dec 11, 2024 8:14 pm
by skywalk
Will portable installs still support userlibs in the existing parent folder?

Re: PureBasic 6.20 beta 1 is out !

Posted: Wed Dec 11, 2024 8:16 pm
by STARGÅTE
skywalk wrote: Wed Dec 11, 2024 7:35 pm Ok, that is why I do not install in "C:\Program Files" folder.
I install to "C:\PureBasic-x64\", "C:\PureBasic-x64-beta1\", etc.
Ok, in this way it worked.

Very nice feature.