Page 1 of 3

PureBasic 4.40 beta2 released.

Posted: Tue Aug 18, 2009 12:11 am
by freak
Hello again,

The beta2 is out with a lot of beta1 bugs fixed (not all yet), and a few more changes too:

Code: Select all

 - Added UsePostgreSQLDatabase()
 - Changed FillMemory() to FillMemory(*Memory, Size [, Value [, Type]])
 - Removed the "UserData" parameter from CustomGradient() and its callback (to fit the other PB callbacks)
 - Added #PB_2DDrawing_CustomFilter drawing mode (ImageOutput  only)
 - Added CustomFilterCallback()
 - Added AlphaBlend(Color1, Color2) - blend two 32bit colors
If you missed the Beta1 announcement, read more here:
http://www.purebasic.fr/english/viewtop ... 524#295524

The #PB_2DDrawing_CustomFilter redirects drawing operations to a callback. It can decide how the source color is put over the target color for every pixel. This mode can be combined with #PB_2DDrawing_Gradient. The callback looks like this:

Code: Select all

Procedure FilterCallback(x, y, SourceColor, TargetColor)
  ProcedureReturn AlphaBlend(SourceColor, TargetColor) ; this would emulate the #PB_2DDrawing_AlphaBlend mode
EndProcedure
As usual, the beta can be found on your user account.

Have fun :)

Posted: Tue Aug 18, 2009 12:18 am
by Flype
first downloader...........
UsePostgreSQLDatabase()
it's christmast day :)

Posted: Tue Aug 18, 2009 12:55 am
by Rescator
Oh for crying out loud, you guys suck....
I just installed beta1 the other night. *sighs and goes to download beta 2* :lol:

Posted: Tue Aug 18, 2009 1:04 am
by byo
Thanks a lot. You guys are geniuses. :shock:

Posted: Tue Aug 18, 2009 1:05 am
by LCD
Thanks! Great!

Posted: Tue Aug 18, 2009 1:16 am
by Seymour Clufley
Fabulous! You implemented my idea! I thought you'd ignored it!

Damn I'm proud...

Posted: Tue Aug 18, 2009 1:31 am
by LCD
AlphaBlend looks useful for me and the Image bug (Library Viewer) has gone. Excellent!

Posted: Tue Aug 18, 2009 8:03 am
by Seymour Clufley
Freak, thankyou 100 times for adding the CustomFilter drawing mode. I think it will be very useful for a lot of programmers!

I don't know whether you added it because of my suggestion or not, but either way, the main reason I asked for it was for drawing text. Boxes and circles etc. could be drawn with procedures written by the programmer using Plot(), but drawing text and images really requires the CustomFilter system.

However, unfortunately, this can't be done unless the CustomFilter mode is combined with Transparent mode:

Code: Select all

DrawingMode(#PB_2DDrawing_CustomFilter|#PB_2DDrawing_Transparent)
Would that be possible?

Also, there seems to be a problem if the callback procedure takes in the x and y as floats. It only works if they're integers. Is that a bug? Haven't tried it with doubles yet.

Please see about combining CustomFilter and Transparent. But either way, thanks for all the work you've done. For me personally this has been a fantastic upgrade to PB. :)

Posted: Tue Aug 18, 2009 8:11 am
by Progi1984

Posted: Tue Aug 18, 2009 1:14 pm
by blueb

Code: Select all

 - Added UsePostgreSQLDatabase() 
WooHoo!
I thought this would take a while, becasue Fred was just talking a few weeks ago about the MySQL licensing disappointment!

Thanks Fred

Posted: Tue Aug 18, 2009 1:46 pm
by flaith
La classe internationale :D

Posted: Tue Aug 18, 2009 3:59 pm
by Xombie
How does UsePostgreSQLDatabase() connect and access information? ODBC or a native connection? Are there any database changes that go with it? Are we still stuck with limitations like not being able to get a row count and only being able to access rows and columns in order once from row/column 0 to the max?

Posted: Tue Aug 18, 2009 5:12 pm
by GeBonet
Tanks....

But i have this :

An Error has been detected in the IDE !
ERROR : Ivalid memory access
File : c:\svn\v4.40\Fr34k\PureBasaicIDE.addTools.pb
Line : 50


Sorry :(

Posted: Wed Aug 19, 2009 12:28 pm
by Num3
GeBonet wrote:Tanks....

But i have this :

An Error has been detected in the IDE !
ERROR : Ivalid memory access
File : c:\svn\v4.40\Fr34k\PureBasaicIDE.addTools.pb
Line : 50


Sorry :(
Same here...

You have to delete the Purebasic directory under "C:\Users\%yourusernamehere%\AppData\Roaming" then it works.

Posted: Wed Aug 19, 2009 2:04 pm
by GeBonet