Worklog for Brucey

More Modules

Return to Worklogs

Websockets(Posted 2013-07-25)
Added a new websockets module using this cross-platform library.

Because you can never have too many tools in your toolbox.

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Serial(Posted 2013-07-08)
Added a new serial communications module to the collection, using this cross-platform library.

Appears to work very well, and is easy to use.

Now BlitzMax is talking nicely to a C7042 :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

wxMax ... MaxGUI(Posted 2013-06-22)
Just need to implement menus, and then we'll try a first-time MaxIDE build and see what disasters ensue...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

MaxGUI ... wxMax(Posted 2013-03-20)
… wxMaxGUI … ooer…

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

All quiet on the western front(Posted 2009-07-12)
Not much going on in the world of Modules at the moment.

I'm currently knee-deep in a side-project which is going quite well.

I got excited by wxWebConnect today, but alas it isn't going to play on Mac for the foreseeable future given the minor issue of Gecko being Cocoa-based, and wxWidgets not. (which is a bummer, as I have a module and sample in-place).. ho hum.
Of course, it might work fine on Win32 and Linux, but it can wait now...

:o)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

BlitzMax + Live Tilemaps = ...(Posted 2009-03-15)


Yes, another little experiment for the weekend.

This time, we have an interface very similar to Google Maps, where you can drag the map around with the mouse, and zoom in and out with the scroll wheel.
Images are cached locally on the harddrive, and reloaded when required.
An SQLite database is used to remember what's available from the cache.
When a new image is required from the server, it is queued and downloaded in the background. When it is available locally, it is displayed on the screen.

It uses the following modules :
BaH.libcurl - background downloading of multiple images
BaH.DBSQLite - the database
BaH.FreeImage - to load images (I was using BRL.PNGLoader, but if there's an error with one of the PNGs, the app aborts).

It actually feels very much like Google Maps, in the way that the 256x256 images appear on-screen as they are downloaded.

Another part of the world...


-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Fun with SID(Posted 2009-03-08)
I've been getting into the Retro mood of late - what with my recent work on BaH.libtcod and the release of BaH.GME.

So it was only fair that I took a look at playing SID tunes...

I spent about 3 hours getting an initial version working with BaH.BASS, as I used some of the GME wrapper as a base to get started - Code re-use : I highly recommend it whenever you can!!
I'm happy to say that it all appears to be working pretty well so far.

Here's what an example app might look like (well, the important commands anyway!):
Framework BaH.SID

Local sid:TSID = TSID.Load("Ocean_Loader_1.sid")

sid.Play()

While Not KeyDown(KEY_ESCAPE)

	sid.Update()

Wend

Simple enough :-)

Actually, the call to Update() is not really required for BASS, since the audio runs in a separate thread. But, for others, like OpenAL or FMOD, you'd probably need to update the engine routinely.

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Getting a Boost(Posted 2009-02-23)
A nice chap recently asked me what my BaH.Boost module was for, since there's not actually any BlitzMax code implemented in it. (call it a very thin wrapper, if you like!)

Well, it's a base module that we can use to construct other modules. Like BaH.DateTime.
Which was about all I was using it for until I was asked the question ;-)

So, I thought perhaps I should investigate some of the other parts of Boost to see what else I might be able to find a use for in BlitzMax.
It turns out that there is a *lot* of functionality that we might find useful.

As is usual, I started off with something small... rational numbers. Basically these are Fractions, and the arithmetic works on fractions rather than floats or doubles. Therefore, 1/3 is 1/3 and not some approximation.
Handy for something, I suppose... :-)

Next up. BaH.Interprocess.
This allows applications running on the same machine to safely access shared memory. It includes "thread"-like functionality like mutexes and semaphores, which enable you to lock and unlock parts of the shared memory when you want synchronized access to a resource.

Google's Chrome browser is using a process-per-tab design to speed up page creation, so there may be some mileage in this technique.
Certainly, it gets around the "threaded GC is slow in BlitzMax"... but we'll need some proper testing to see how effective it is in comparison.


Exciting times :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Unicode Unicode...(Posted 2009-02-09)
Yes, I'm about done with Unicode now...

The recently released BaH.RTL module adds right-to-left text support for Strings, enabling commands such as DrawText to output Arabic and Hebrew text properly. It was a fun day's work, that one. A bit tricky getting a Win32 DLL built though, but got there in the end...

That and the Unicode file support that we now have in BlitzMax (SVN) about covers everything - concerning Unicode.

At last!


So, I guess it's back to the grind-stone, and working on the completion of the other modules such as BaH.RakNet (and supporting modules (Voice, Rooms, Lobby2, etc)).

The fun never ends...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Problem.... continued(Posted 2009-01-03)
The BlitzMax-to-<insert source type here> converter is coming along... okay...
It's one of those things you come back to now and again.

This evening I've got primitives Select/Case working. Not for "other types"/methods yet, which will require it to go into IF mode, rather than say, a pretty switch() statement. One thing at a time :-)

Turns out my regression unit test framework is ultra handy... because when you change the wrong bit of code... some of the previously working tests break :-)
My string-compare needs some work so that it highlights better the actual bit of the string that is different - rather than everything.

Fun fun !

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Stuff for 2009(Posted 2009-01-01)
Time flies when you're having fun, eh? ;-)

First things first, I'm happy to say that I've finished what I believe to be ALL the work for making BlitzMax native IO and dialogs unicode friendly. Hopefully this, or something based on this, will find its way into the official code-base :-)

During the course of the day and a bit work on the above, I uncovered some issues with some of my own modules. For example RequestFile on gtkmaxgui was broken. Fix has been committed :-)
I also need to revisit the Volumes module to ensure everything there is working as intended. I think there are some things to change - but unfortunately some of this will still require my Unicode modifications in order to work properly - no point me returning you some unicode folders when you can't actually use them :-p


I'm still busy tinkering with the "unreleased" modules, of which I must admit to there being more than there should be. I'll get them sorted out.
I think one of the biggest issues there, is that some of these more recent modules are VERY LARGE INDEED. For example, CEGUI is a bit of a monster - It has about 1000 methods so far, and isn't quite complete yet! We're getting there though. I had a look at the docs for Flow's implementation of CEGUI, and it looks about 1/3 the size of mine. I guess they must be using a really old version?? Shame, as they appear to be missing out a lot of the really good stuff.

wxMax - the biggest module ever - is due to be updated to wxWidgets 2.8.9. Once that is done, I'll likely do a new full release of it.
Since the original release there has been a LOT of work. The biggest addition is surely the XRC framework (where you can use XML files to describe window layout, rather than hard-code everything). Handy for that all-important flexibility.

BaH.Magick - is progressing well. I've stubbed all the TMImage methods, and just need to go through and implement/document them. It's another fairly large module. But I think, as far as image manipulation goes, it's certainly feature-filled!

wxMaxIDE - Yes, I think I shall be working on this again. I'm going to rewrite the core stuff to us the document/view framework that wxWidgets provides. This looks after "documents" for you, file history, undo/redo, menus, and lots more. It's much like a typical MVC. The idea is you worry less about implementing all the fiddly doc/editor/menu/load/save bits, and more concern yourself with programming the IDE... watch this space.

BaH.GTKMaxGUI - I haven't forgotten about it. Yes, it needs some updating, but I'm still using it on Linux to run the IDE, of which is does a splendid job I might add.

More Modules - I'm sure there will be some new modules appearing in 2009. I have my eye on one or two already. But if anyone has any other ideas, mail me :-)

RadioBaH, my "bloated" internet radio player is pretty much finished now. Does exactly what I wanted - stream streamcast and icecast, as well as not sucking up resources (when minimized). Multi-platform too, which is most important, since I work on multi-platforms ;-)
But... I can understand how showing the current track names as they change might be considered "bloat"... :-p


BlitzMax is my favourite programming language :-)

Ever!

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Curses !!!(Posted 2008-12-20)
I've decided to add my BaH.Curses module to SVN, finally.

It is in need of a lot of TLC, and will hopefully get some work on it now that it is part of maxmods - rather than hiding away on my HDD.

What is it?
Well, it essentially gives you a nice GUI environment (like windows, popups and events) in a terminal/shell/console.

If you want to play... remember to compile the examples in NON-GUI mode... AND, they won't run in the IDE, as the IDE console is not a real console.

:o)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Problem...(Posted 2008-12-17)
You use BlitzMax to prototype ideas/code, which you intend eventually running on a platform not supported by BlitzMax.

What do you do?

You write a BlitzMax-to-<insert source type here> converter :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Tech Demo!(Posted 2008-12-07)
This is a screenshot of a small internet radio app showcasing the use of several of my BlitzMax modules :



And the modules :
* wxMax - cross-platform UI (MaxGUI is completely out of its depth for serious apps)
* BaH.Bass - streaming audio
* BaH.Cairo - vector graphics
* BaH.Libcurl - internet client
* BaH.Libxml - xml processor

Demo (for Windows and Mac) is available from here. ( Quick Instructions ).

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

A bit of everything...(Posted 2008-12-03)
Bit of a Jack-Of-All-Trades this week...

Managed to re-engineer the Cairo module to not use fontconfig. Yeah, it's a big hack as far as commenting out large chunks of the code goes, but it appears to actually be working. So for now, I'm not complaining... (at least until someone else comes along and says it doesn't work for them... haw).


Had a tinker (over 15 mins) with Bass to see if I could get Sync callbacks working.
The tricky part is trying to get it to work within the non-existent thread-safe nature of BlitzMax's standard GC. So I used a bit of sneak, added a touch of cunning, and I think I have a mostly working solution. Yay ;-)

Here's an example of running a META sync callback, which is called each time there's a new track playing on a shoutcast stream :
Building example06
Executing:example06.debug
DebugLog:ICY 200 OK
DebugLog:icy-notice1:<BR>This stream requires <a href="http://www.winamp.com/">Winamp</a><BR>
DebugLog:icy-notice2:SHOUTcast Distributed Network Audio Server/Linux v1.9.8<BR>
DebugLog:icy-name:PulsRadio - www.pulsradio.com - Live From France
DebugLog:icy-genre:Dance Trance Techno House
DebugLog:icy-url:http://www.pulsradio.com
DebugLog:icy-pub:1
DebugLog:icy-metaint:32768
DebugLog:icy-br:192
bmx_sync_callback
DebugLog:checking meta
DebugLog:meta : StreamTitle='DJ Ross - Emotion (Raindropz Remix)';StreamUrl='';
bmx_sync_callback
DebugLog:checking meta
DebugLog:meta : StreamTitle='DJ Shog - The 2nd Dimension (Original Radio Edit)';StreamUrl='';

Note how we get access to new track names as time goes by.

Pretty neat :-)

When I play internet radio on my iPod, I get images too, but I've no idea where they come from. I'm guessing that shoutcast doesn't give out that much info... ?

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Just for fun...(Posted 2008-12-01)
... here's a BaH.Magick generated list of supported image formats...
Executing:example_04.debug
3FR: (Hasselblad Photo RAW) : Readable = true, Writable = false, Multiframe = true
8BIM: (Photoshop resource format) : Readable = true, Writable = true, Multiframe = false
8BIMTEXT: (Photoshop resource text format) : Readable = true, Writable = true, Multiframe = false
8BIMWTEXT: (Photoshop resource wide text format) : Readable = true, Writable = true, Multiframe = false
APP1: (Raw application information) : Readable = true, Writable = true, Multiframe = false
APP1JPEG: (Raw JPEG binary data) : Readable = true, Writable = true, Multiframe = false
ART: (PFS: 1st Publisher) : Readable = true, Writable = true, Multiframe = true
ARW: (Sony Alpha DSLR RAW) : Readable = true, Writable = false, Multiframe = true
AVI: (Microsoft Audio/Visual Interleaved) : Readable = true, Writable = false, Multiframe = true
AVS: (AVS X image) : Readable = true, Writable = true, Multiframe = true
BMP: (Microsoft Windows bitmap image) : Readable = true, Writable = true, Multiframe = false
BMP2: (Microsoft Windows bitmap image v2) : Readable = false, Writable = true, Multiframe = false
BMP3: (Microsoft Windows bitmap image v3) : Readable = false, Writable = true, Multiframe = false
CACHE: (Magick Persistent Cache image format) : Readable = false, Writable = false, Multiframe = true
CAPTION: (Image caption) : Readable = true, Writable = false, Multiframe = false
CIN: (Cineon Image File) : Readable = true, Writable = true, Multiframe = true
CMYK: (Raw cyan, magenta, yellow, and black samples) : Readable = true, Writable = true, Multiframe = true
CMYKA: (Raw cyan, magenta, yellow, black, and opacity samples) : Readable = true, Writable = true, Multiframe = true
CR2: (Canon Photo RAW) : Readable = true, Writable = false, Multiframe = true
CRW: (Canon Photo RAW) : Readable = true, Writable = false, Multiframe = true
CUR: (Microsoft Cursor Icon) : Readable = true, Writable = false, Multiframe = false
CUT: (DR Halo) : Readable = true, Writable = false, Multiframe = true
DCM: (Digital Imaging and Communications in Medicine image) : Readable = true, Writable = false, Multiframe = false
DCR: (Kodak Photo RAW) : Readable = true, Writable = false, Multiframe = true
DCX: (ZSoft IBM PC multi-page Paintbrush) : Readable = true, Writable = true, Multiframe = true
DNG: (Adobe Digital Negative) : Readable = true, Writable = false, Multiframe = true
DPS: (Display Postscript Interpreter) : Readable = true, Writable = false, Multiframe = true
DPX: (SMPTE 268M-2003 (DPX 2.0)) : Readable = true, Writable = true, Multiframe = false
EPDF: (Encapsulated Portable Document Format) : Readable = true, Writable = true, Multiframe = false
EPI: (Adobe Encapsulated PostScript Interchange format) : Readable = true, Writable = true, Multiframe = false
EPS: (Adobe Encapsulated PostScript) : Readable = true, Writable = true, Multiframe = false
EPS2: (Adobe Level II Encapsulated PostScript) : Readable = false, Writable = true, Multiframe = false
EPS3: (Adobe Level III Encapsulated PostScript) : Readable = false, Writable = true, Multiframe = true
EPSF: (Adobe Encapsulated PostScript) : Readable = true, Writable = true, Multiframe = false
EPSI: (Adobe Encapsulated PostScript Interchange format) : Readable = true, Writable = true, Multiframe = false
EPT: (Adobe Encapsulated PostScript with MS-DOS TIFF preview) : Readable = true, Writable = true, Multiframe = false
EPT2: (Adobe Level II Encapsulated PostScript with MS-DOS TIFF preview) : Readable = true, Writable = true, Multiframe = false
EPT3: (Adobe Level III Encapsulated PostScript with MS-DOS TIFF preview) : Readable = true, Writable = true, Multiframe = false
ERF: (Epson RAW Format) : Readable = true, Writable = false, Multiframe = true
EXIF: (Exif digital camera binary data) : Readable = true, Writable = true, Multiframe = false
FAX: (Group 3 FAX (Not TIFF Group3 FAX!)) : Readable = true, Writable = true, Multiframe = true
FITS: (Flexible Image Transport System) : Readable = true, Writable = true, Multiframe = false
FRACTAL: (Plasma fractal image) : Readable = true, Writable = false, Multiframe = false
GIF: (CompuServe graphics interchange format) : Readable = true, Writable = true, Multiframe = true
GIF87: (CompuServe graphics interchange format) : Readable = true, Writable = true, Multiframe = false
GRADIENT: (Gradual passing from one shade to another) : Readable = true, Writable = false, Multiframe = false
GRAY: (Raw gray samples) : Readable = true, Writable = true, Multiframe = true
HISTOGRAM: (Histogram of the image) : Readable = false, Writable = true, Multiframe = false
HTML: (Hypertext Markup Language and a client-side image map) : Readable = false, Writable = true, Multiframe = false
ICB: (Truevision Targa image) : Readable = true, Writable = true, Multiframe = true
ICC: (ICC Color Profile) : Readable = true, Writable = true, Multiframe = false
ICM: (ICC Color Profile) : Readable = true, Writable = true, Multiframe = false
ICO: (Microsoft Icon) : Readable = true, Writable = false, Multiframe = false
ICON: (Microsoft Icon) : Readable = true, Writable = false, Multiframe = false
IMAGE: (GraphicsMagick Embedded Image) : Readable = true, Writable = false, Multiframe = false
IPTC: (IPTC Newsphoto) : Readable = true, Writable = true, Multiframe = false
IPTCTEXT: (IPTC Newsphoto text format) : Readable = true, Writable = true, Multiframe = false
IPTCWTEXT: (IPTC Newsphoto text format) : Readable = true, Writable = true, Multiframe = false
JNG: (JPEG Network Graphics) : Readable = true, Writable = true, Multiframe = false
JP2: (JPEG-2000 JP2 File Format Syntax) : Readable = true, Writable = true, Multiframe = false
JPC: (JPEG-2000 Code Stream Syntax) : Readable = true, Writable = true, Multiframe = false
JPEG: (Joint Photographic Experts Group JFIF format) : Readable = true, Writable = true, Multiframe = false
JPG: (Joint Photographic Experts Group JFIF format) : Readable = true, Writable = true, Multiframe = false
K25: (Kodak Photo RAW) : Readable = true, Writable = false, Multiframe = true
KDC: (Kodak Photo RAW) : Readable = true, Writable = false, Multiframe = true
LABEL: (Image label) : Readable = true, Writable = false, Multiframe = false
M2V: (MPEG Video Stream) : Readable = false, Writable = true, Multiframe = true
MAP: (Colormap intensities and indices) : Readable = true, Writable = true, Multiframe = false
MAT: (MATLAB image format) : Readable = true, Writable = true, Multiframe = true
MATTE: (MATTE raw opacity format) : Readable = false, Writable = true, Multiframe = true
MIFF: (Magick Image File Format) : Readable = true, Writable = true, Multiframe = true
MNG: (Multiple-image Network Graphics) : Readable = true, Writable = true, Multiframe = true
MONO: (Bi-level bitmap in least-significant-byte first order) : Readable = true, Writable = true, Multiframe = false
MPC: (Magick Persistent Cache image format) : Readable = true, Writable = true, Multiframe = true
MPEG: (MPEG Video Stream) : Readable = false, Writable = true, Multiframe = true
MPG: (MPEG Video Stream) : Readable = false, Writable = true, Multiframe = true
MRW: (Minolta Photo Raw) : Readable = true, Writable = false, Multiframe = true
MSL: (Magick Scripting Language) : Readable = true, Writable = true, Multiframe = true
MTV: (MTV Raytracing image format) : Readable = true, Writable = true, Multiframe = true
MVG: (Magick Vector Graphics) : Readable = true, Writable = true, Multiframe = false
NEF: (Nikon Electronic Format) : Readable = true, Writable = false, Multiframe = true
NULL: (Constant image of uniform color) : Readable = true, Writable = true, Multiframe = false
ORF: (Olympus Photo RAW) : Readable = true, Writable = false, Multiframe = true
OTB: (On-the-air bitmap) : Readable = true, Writable = true, Multiframe = false
P7: (Xv thumbnail format) : Readable = true, Writable = true, Multiframe = true
PAL: (16bit/pixel interleaved YUV) : Readable = true, Writable = true, Multiframe = false
PALM: (Palm pixmap) : Readable = true, Writable = true, Multiframe = false
PBM: (Portable bitmap format (black/white)) : Readable = true, Writable = true, Multiframe = true
PCD: (Photo CD) : Readable = true, Writable = true, Multiframe = false
PCDS: (Photo CD) : Readable = true, Writable = true, Multiframe = false
PCL: (Page Control Language) : Readable = false, Writable = true, Multiframe = false
PCT: (Apple Macintosh QuickDraw/PICT) : Readable = true, Writable = true, Multiframe = false
PCX: (ZSoft IBM PC Paintbrush) : Readable = true, Writable = true, Multiframe = false
PDB: (Palm Database ImageViewer Format) : Readable = true, Writable = true, Multiframe = true
PDF: (Portable Document Format) : Readable = true, Writable = true, Multiframe = true
PEF: (Pentax Electronic File) : Readable = true, Writable = false, Multiframe = true
PFA: (Postscript Type 1 font (ASCII)) : Readable = true, Writable = false, Multiframe = false
PFB: (Postscript Type 1 font (binary)) : Readable = true, Writable = false, Multiframe = false
PGM: (Portable graymap format (gray scale)) : Readable = true, Writable = true, Multiframe = true
PGX: (JPEG-2000 VM Format) : Readable = true, Writable = false, Multiframe = false
PICON: (Personal Icon) : Readable = true, Writable = true, Multiframe = false
PICT: (Apple Macintosh QuickDraw/PICT) : Readable = true, Writable = true, Multiframe = false
PIX: (Alias/Wavefront RLE image format) : Readable = true, Writable = false, Multiframe = true
PLASMA: (Plasma fractal image) : Readable = true, Writable = false, Multiframe = false
PNG: (Portable Network Graphics) : Readable = true, Writable = true, Multiframe = false
PNG24: (24-bit RGB PNG, opaque only) : Readable = true, Writable = true, Multiframe = false
PNG32: (32-bit RGBA PNG, semitransparency OK) : Readable = true, Writable = true, Multiframe = false
PNG8: (8-bit indexed PNG, binary transparency only) : Readable = true, Writable = true, Multiframe = false
PNM: (Portable anymap) : Readable = true, Writable = true, Multiframe = true
PPM: (Portable pixmap format (color)) : Readable = true, Writable = true, Multiframe = true
PREVIEW: (Show a preview an image enhancement, effect, or f/x) : Readable = false, Writable = true, Multiframe = false
PS: (Adobe PostScript) : Readable = true, Writable = true, Multiframe = true
PS2: (Adobe Level II PostScript) : Readable = false, Writable = true, Multiframe = true
PS3: (Adobe Level III PostScript) : Readable = false, Writable = true, Multiframe = true
PSD: (Adobe Photoshop bitmap) : Readable = true, Writable = true, Multiframe = true
PTIF: (Pyramid encoded TIFF) : Readable = true, Writable = true, Multiframe = false
PWP: (Seattle Film Works) : Readable = true, Writable = false, Multiframe = true
RAF: (Fuji Photo RAW) : Readable = true, Writable = false, Multiframe = true
RAS: (SUN Rasterfile) : Readable = true, Writable = true, Multiframe = true
RGB: (Raw red, green, and blue samples) : Readable = true, Writable = true, Multiframe = true
RGBA: (Raw red, green, blue, and matte samples) : Readable = true, Writable = true, Multiframe = true
RLA: (Alias/Wavefront image) : Readable = true, Writable = false, Multiframe = false
RLE: (Utah Run length encoded image) : Readable = true, Writable = false, Multiframe = false
SCT: (Scitex HandShake) : Readable = true, Writable = false, Multiframe = false
SFW: (Seattle Film Works) : Readable = true, Writable = false, Multiframe = false
SGI: (Irix RGB image) : Readable = true, Writable = true, Multiframe = true
SHTML: (Hypertext Markup Language and a client-side image map) : Readable = false, Writable = true, Multiframe = false
SR2: (Sony Photo RAW) : Readable = true, Writable = false, Multiframe = true
SRF: (Sony Photo RAW) : Readable = true, Writable = false, Multiframe = true
STEGANO: (Steganographic image) : Readable = true, Writable = false, Multiframe = true
SUN: (SUN Rasterfile) : Readable = true, Writable = true, Multiframe = true
SVG: (Scalable Vector Graphics) : Readable = true, Writable = true, Multiframe = true
SVGZ: (Scalable Vector Graphics (ZIP compressed)) : Readable = true, Writable = true, Multiframe = true
TEXT: (Text) : Readable = true, Writable = true, Multiframe = true
TGA: (Truevision Targa image) : Readable = true, Writable = true, Multiframe = true
TIFF: (Tagged Image File Format) : Readable = true, Writable = true, Multiframe = true
TILE: (Tile image with a texture) : Readable = true, Writable = false, Multiframe = true
TIM: (PSX TIM) : Readable = true, Writable = false, Multiframe = true
TOPOL: (TOPOL X Image) : Readable = true, Writable = false, Multiframe = true
TTF: (TrueType font) : Readable = true, Writable = false, Multiframe = false
TXT: (Text) : Readable = true, Writable = true, Multiframe = true
UIL: (X-Motif UIL table) : Readable = false, Writable = true, Multiframe = false
UYVY: (16bit/pixel interleaved YUV) : Readable = true, Writable = true, Multiframe = false
VDA: (Truevision Targa image) : Readable = true, Writable = true, Multiframe = true
VICAR: (VICAR rasterfile format) : Readable = true, Writable = true, Multiframe = false
VID: (Visual Image Directory) : Readable = true, Writable = true, Multiframe = true
VIFF: (Khoros Visualization image) : Readable = true, Writable = true, Multiframe = true
VST: (Truevision Targa image) : Readable = true, Writable = true, Multiframe = true
WBMP: (Wireless Bitmap (level 0) image) : Readable = true, Writable = true, Multiframe = false
WPG: (Word Perfect Graphics) : Readable = true, Writable = false, Multiframe = true
X3F: (Foveon X3 (Sigma/Polaroid) RAW) : Readable = true, Writable = false, Multiframe = true
XBM: (X Windows system bitmap (black/white)) : Readable = true, Writable = true, Multiframe = false
XC: (Constant image uniform color) : Readable = true, Writable = false, Multiframe = false
XCF: (GIMP image) : Readable = true, Writable = false, Multiframe = true
XMP: (Adobe XML metadata) : Readable = true, Writable = true, Multiframe = false
XPM: (X Windows system pixmap (color)) : Readable = true, Writable = true, Multiframe = false
XV: (Khoros Visualization image) : Readable = true, Writable = true, Multiframe = true
YUV: (CCIR 601 4:1:1 or 4:2:2 (8-bit only)) : Readable = true, Writable = true, Multiframe = false


Most of which I've never heard of...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

What's going on?!?(Posted 2008-12-01)
It's been a little quiet here of late... but I've been pottering away as usual.

BaH.CEGUI is progressing well. Most of the functionality is now implemented, and it seems to run well. Yay!

I've also been dabbling with BaH.flickcurl, an API for communicating with flickr, giving direct access to searches, images, groups, tags, to name but a few. It's nice that one can search for and download an image "inside" BlitzMax.

Another recently committed WIP module is BaH.Magick. This is a wrapper for GraphicsMagick. It's a bit like FreeImage, supporting a vast set of image formats, but has many more image manipulation functions.
Just another tool for the toolkit...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

CEGUI - WIP(Posted 2008-09-27)
After the successful mini-test of the win32 version of CEGUI, I've dived right in and got some more stuff working with it.
Most notably, events and keyboard input :

In this example, clicking on the "close" button of the window hides it. Clicking on the "Show" button shows the window again. The editbox can be... edited...

Overall, progress appears to be going well so far. It looks like it's going to be relatively easy to use - although I haven't tried a multi-column listbox nor tree yet.

It feels fast too.

Hmmm... some example code :-p

Attaching to the close-button click :
...
Local window:TCEWindow = TCEWindowManager.getWindow("HelloWorldWindow")
window.subscribeEvent(TCEFrameWindow.EventCloseClicked, closed)
...

Function closed:Int(args:TCEEventArgs)
	TCEWindow(args.owner).hide()
	Return True
End Function

in CEGUI, you "subscribe" to events. You tell it which event you are interested in, and a callback function.
The initial window reference comes from the loaded "layout"/xml.

In this example, we create our own button, in code :
Local button:TCEWindow = TCEWindowManager.CreateWindow("WindowsLook/Button", "button")
root.addChildWindow(button)

button.setText("Show")
button.setPosition(40, 100)
button.setSize(90, 20)
button.subscribeEvent(TCEPushButton.EventClicked, clicked)

"root" is a reference to the "GUISheet"/desktop window.

I'm considering add some functions which will take a set of params for building up a widget - like x, y, w, h, etc. Rather than having to make several individual calls.
Although, I expect most screens will be created in XML - probably.

:-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

wxMax v1.00 !(Posted 2008-08-05)
We've (almost) finally reached a proper full release!

Currently it's dipping it's toes in the water to see that it generally works before I go final - a couple of little tweaks so far, but it's looking not bad til now.

Thanks to everyone's support over the last 10 months :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

The generator app(Posted 2008-07-11)
This is the code to generate all the C++, glue and BlitzMax code.

I'll probably hide this somewhere and have a default function build the required code given a proto as parameter...
SuperStrict

Framework BaH.Protobuf

Local opts:String[] = [ "--cpp_out", ".", "--bmx_out", ".", "addressbook.proto" ]

ProtobufCLI.Run(opts)


It's not rocket science :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

The Story so far...(Posted 2008-07-11)
It's all coming together.

Using the addressbook.proto from the tutorial, and generating some BlitzMax code, we write a small app to use it :
SuperStrict

Import "addressbook.pb.bmx"

Local p:Person = New Person.Create()
p.SetId(1)
p.SetName("Brucey")

Local number:Person_PhoneNumber = p.AddPhone()
number.SetType(Person_PhoneType_HOME)
number.SetNumber("555-123-456")

Print TTextFormat.PrintToString(p)

...just building and outputting a Person :
Executing:main.debug

name: "Brucey"
id: 1
phone {
  number: "555-123-456"
  type: HOME
}


Process complete

It's magic ;-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

We can compile!!!(Posted 2008-07-10)
The protobuf module is now able to generate compile-able BlitzMax code :-)

No, it's not an empty file :-p


Next stop... adding some glue.

A dab here, a dab there, and hopefully not too much framework to fit into the module after that.


Alas, the project requires a tweak to both bmk and bcc - but not to worry about that for now ;-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Protobuf(Posted 2008-07-10)
...is a cool serialization library developed in-house at Google, and now made open source.

Now, if only BlitzMax supported it...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

FMOD callbacks and BlitzMax(Posted 2008-06-14)
I've come across several posts on the forums about callbacks not working in FMOD with BlitzMax...

...funny that, since they worked for me first time.

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

New Audio Drivers!!!(Posted 2008-04-20)
I've asked BRL if they can make a tweak to BRL.Audio in order to make implementing other audio drivers much easier. The change itself is about 4 lines of code, so I'm reasonably confident that it is a non-issue.

Once that's done, I can introduce you to BaH.FMODAudio.
It is a new Audio Driver module for BlitzMax which lets you use FMOD with the standard BRL.Audio command-set. (like LoadSound and PlaySound etc).

It uses BaH.FMOD to drive the core FMOD sound engine, and, if you need, you can always plug into that directly to gain access to any extra effects/utils.

It currently supports loading sounds both with String filenames and the use of "incbin:: ..." filenames. Once I've added TStream support to the FMOD module, you will also be able to LoadSound(stream), which might be nice for some :-)

The only caveat with this Audio Driver is that somewhere in your main-loop, PollSystem is required to be called. This triggers the event-hook which calls FMOD system Update().
Fortunately, if you have KeyDown, MouseDown, etc commands that automatically does a PollSystem for you, in which case you most likely have code that works as is! ;-)

Here's a very small example using the audio driver :
SuperStrict

Framework BaH.FMODAudio
Import BRL.StandardIO

SetAudioDriver("FMOD")

Local sound:TSound = LoadSound("drumloop.wav")

PlaySound(sound)

Local i:Int

While i < 30

	PollSystem

	Delay(100)
	i:+ 1
Wend


Since it uses FMOD, you can apply FMOD flags as part of the LoadSound call, allowing you to load the sound as a stream, for example, rather than loading it all into memory first. Handy for those large background music tracks.

:o)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

More FMOD(Posted 2008-04-15)
Well, that's FMOD running now on both Mac and Win32.
Still working through the API, but the 3 examples that are complete so far are working great :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Audio and Boxes(Posted 2008-04-13)
While I'm without most of my hardware for the time being, I thought it would be a nice change to delve into something a little different.

So, I've been working on building some nice bindings (wrappers) for BASS and FMOD.
Rather than simply expose the C API, which tends to happen with wrappers in these parts, I prefer to Maxify the API as much as possible, in order to remove from the user the need to keep track and use pointers etc.

Obviously, some people would rather plug into a raw API. Good for them! There are a few nice wrappers already available for them to get their teeth into.

Currently developing on PPC Mac, but BASS should be up to a point where it will build/run on Win32 and OS X. FMOD will still need some tweaks for Win32/Linux, but is running good on OS X for now.

FMOD...
Local system:TFMODSystem = New TFMODSystem.Create()
system.Init(32)

Local sound1:TFMODSound = system.CreateSoundURL("media/drumloop.wav", FMOD_SOFTWARE)
sound1.SetMode(FMOD_LOOP_OFF)

while ...

If KeyHit(KEY_1) Then
	channel = system.PlaySound(FMOD_CHANNEL_FREE, sound1)
End If

...

system.Update()

wend


BASS...
TBass.Init(-1,44100,0,Null,Null)

Local channel:TBassChannel = New TBassMusic.FileLoad("resources/HarbourBizarre.mod", 0, 0, BASS_SAMPLE_LOOP |..
	 BASS_MUSIC_RAMPS | BASS_MUSIC_PRESCAN, 0)

channel.Play(False)

while channel.IsActive()

...

wend


Interestingly, the FMOD dylib won't work with bundles out-of-the-box, but I'll be including a "fix" as well as a fixed version of the dylib with the module.

In both cases, on Mac, if you are building with GUI enabled, you will need to copy the dylib into the application bundle (or somewhere on the system if you really want to).
Other platforms will probably work with the shared-object/dll in the app folder.

Audio is fun ;-)


On another note, I've also started work on Box2D, but am having trouble with the demo, where, unlike with Chipmunk, 1 pixel doesn't equal one engine unit. So, some kind of scaling is required to make things draw properly using the built-in debug draw stuff. Otherwise, it appears to be working.

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Currently playing with...(Posted 2008-03-15)
... BaH.Persistence

an Object serializer which handle circular refs with ease :-)

... BaH.XLWriter

an xlsx creator. (that's SpreadsheetML / Office Open XML / Excel 2007)
works a bit like this:
		Local doc:TXLDocument = New TXLDocument.Create()
		
		Local sheet:TXLWorksheet = doc.Workbook().AddWorksheet("July 06")
		
		sheet.Cell(7, 1).SetValue("Alpha Hydroxy Toner Mild")
		sheet.Cell(8, 1).SetValue("Alpha Hydroxy Toner Mild")
		sheet.Cell(9, 1).SetValue("Aquatrol")
		
		
		doc.Save("example1")

Requires wxMax for the Zip file support, and BaH.libxml (SVN) for xml generation.
No other external libs used, as it's been written in BlitzMax from scratch.

:-p

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Editing in Colour(Posted 2008-02-27)
Finally worked out how to get wxScintilla to syntax highlight, and I must say, I'm very impressed! :-)


SQL anyone?

Basically, you tell it what lexer to use, give it a list of keywords for the lexer to understand, set some colours for different token types, and that's it.

and it's faaast :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

PDF-alicious(Posted 2008-01-27)
*phew*

Well, that's the PDF add-on to wxMax about done now. All the core code is in. Some of the "other" types still need some implementing, and of course, the documentation is um... lacking :-p
But hey... that's 200+ new methods for wxMax. Take a look at the pdfdocument.bmx sample for some ideas of its capabilities.

Takes me back to the days when I used to hand-code PDF file generators... ahhh.... you'd be surprised how much you can learn about a document format when you need to write a generator from scratch! :-)

Anyhoo, let's see what's next...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

wx and a half(Posted 2008-01-23)
It's all go here at wxMax central.

Spent a day (during breaks and whatnot) churning out wxMidi, which is almost complete, and, I might add, it compiled first time on OS X ;-)

Sat back down with wxPropGrid. I had originally thought to use the current 1.2.x release, but in SVN they have a 1.3 which is quite different in places, and I didn't really fancy re-coding things in a later move to a 1.3 release.
So, some of the stuff I've had to rewrite *now*, which is a lot less work, given it's not nearly complete, but I feel this was a good move to make. It's going to take a while tho to get it done, since I'm using a combination of doxygen and source to get the API sorted out... haw.

Any votes for this? : http://wxcode.sourceforge.net/components/wxpdfdoc/

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

To Gen or Not to Gen, that is the quesiton.(Posted 2008-01-14)
Whether 'tis nobler in the mind to suffer
The time and effort of hand-coding,
Or to take arms against a sea of forms,
And by generating, succeed!

Anyways... as we all know, hand-coding any GUI form takes time and far too much effort. Which is why I've been working on a code-generator.
Over the weekend I had the core generator make me a GUI which I could then use for the code generator itself :-)
It's now working rather well, and is part of wxMax (in the tools folder!).
The next step is to have it auto-generate when you save a wxFormBuilder project, which I hope shouldn't be too difficult.

Another useful feature of testing code generation is that you tend to have to add *all* of the controls/events to see that things come out the way they should, and which shows up holes in the code. So the mod gets better as a result.

So, it's all shaping up to be a very useful addition to BlitzMax.

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Crossing the finishing line...(Posted 2008-01-05)
Woohoo :-)

GLMax2D is playing nice in wxMax now.

Code committed, and the two "samples" are in also (glcube, and glmax2d)

Not bad for a day's work, if I do say so myself...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

GL and wxMax : The story so far(Posted 2008-01-05)
Well... it's taken me ALL DAY.. but I finally have the glcube demo running.

I don't think there is anything MacOs specific in there, so it might actually run on all platforms.
It's all a bit hacky, but since this is the first stage, it doesn't matter too much.
The fact that the cube is spinning happily in wxMax is a good thing :-)

Right... what about GLMax2D ? ...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

GlGraphics and wxMax(Posted 2008-01-05)
Today, I'm going to attempt to integrate BRL.GLGraphics and wxMax...

wish me luck... :-p

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

wxCodeGen....(Posted 2008-01-03)
Making progress with the code-generator.

It now generates event code :

a button...
m_button1 = new wxButton.Create(m_panel1, TAG_ADD, "Add")

its connect code ...
Connect(TAG_ADD, wxEVT_COMMAND_BUTTON_CLICKED, _OnAddTag)

and the generated function/method pair
Function _OnAddTag(event:wxEvent)
	MyFrame1Base(event.parent).OnAddTag(wxCommandEvent(event))
End Function

Method OnAddTag(event:wxCommandEvent)
	DebugLog "Please override MyFrame1.OnAddTag()"
	event.Skip()
End Method

Extend the base type, and override the event methods...

The code is designed in such a way that the generated code is in its own file, which you simply Import. That way you don't have to worry about making sure you only change the parts of a file you are meant to. (some generators will create inlined comments which are parsed at generation time in order to replace only parts of a file - messy).

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

wxFormBuilder and wxMax(Posted 2008-01-02)
I've been looking around for ideas for making a wxMax-based GUI/form designer, but rather than sit and try to write something from scratch, I thought I would see how easy it would be to get something generating from a form-builder that is already written.

The usual problem with these, is that they generate code for C++. However, if you find a way to read a Project file, that should be enough information to generate BlitzMax code (since the form-builder itself uses the project file to do the same!).

I've found I like DialogBlocks, because it is quite intuitive. However, it's not free.

wxFormBuilder is actually not too bad, if you don't mind it being a bit flaky on OS X (ie. careful what you do, or it might self-destruct). But, given that they've only recently started building for Mac, I'll give them a break.

Anyhoo, I've knocked together a small app which generates Max code from a wxFormBuilder project file. With a form-builder, you can spend 5 minutes knocking together a form. Save the project, run my basic app, add the output to the basic wxApp code, and it just works ;-)

The form in wxFormBuilder.


The app running from BlitzMax.


This is the code I added to run the generated form code :


Cool huh?

If I get enough feedback (either mail me here, or post on the wxMax google group), perhaps we can make this into a proper app that integrates nicely with the normal development cycle.

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

What do you get if you cross...(Posted 2007-12-29)
... BaH.Graphviz, BaH.Cairo, and the wxMax source.. ?

http://brucey.net/programming/blitz/misc/stuff/wxMax_classdiagram.pdf (91kb)


This is why I like wrapping so many different kinds of libraries - you can throw them together to create interesting images :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

MaxUnit and Reflection(Posted 2007-12-28)
My oh my, oh my, oh my.... :-)

Honestly, I'd not even looked at the new Reflection stuff at all until now. I assumed it would allow me access to the things I would expect from Reflection, so I left it well alone since I had no use for it.

Until now ...

When I first wrote MaxUnit, I was rather disappointed with having to define test Functions and inform MaxUnit of each test that required to be run.
The whole idea with testing is that you concentrate on the *test*, rather than remembering that the new Function needs to be added to the list of tests to run. Which is a schlep and a half!

But now that Reflection has come along, we can let *it* take the strain. Writing unit tests in BlitzMax now almost becomes a pleasure, since there's so much *less* to do!

But what makes it so great?

In one word, Metadata! (but I prefer to call them "tags", and you might want to call them "annotations").

Previously, to define a test, you would create a Function, and add that function to a list. (the test would call the function pointer).

Now we simply create a Method, and tag it to say it is a "test" method :
	Method testAdd() { test }
		Local result:Int = value1 + value2
		assertTrue(result = 5)
	End Method

...notice the curly brackets with the word "test" in there.
This has another advantage in that we can use Fields and whatnot in our test types, rather than Type-variables (Globals).

Because our Type extends TTest, this method is *automatically* run during the test. Nothing to add anywhere. Nothing extra to do at all.

To run test tests you call this somewhere in the program :
New TTestSuite.run()

You don't even have to tell it what Types you want to test! It will find all sub-types of TTest, and test those types.

Here's a complete example :

the "setup" tagged Method is called before each test method, in order to set-up required data, etc.
You can also define a similarly tagged "teardown" method.

Reflection in BlitzMax is pretty awesome, and now MaxUnit works much more like JUnit, in the way it utilises annotations to define code to run.

...available now from my Google Code Repository :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Print-tastic ! ! ! !(Posted 2007-12-26)
:o)

How's about some proper printing support in BlitzMax?
Here's an example of a printout saved as a PDF : wx_print_demo.pdf (25kb)
as ported directly from the wxWidgets C++ sample.

Still a fair few loose ends to tie up with regards that part of the framework, but all-in-all, it's not bad.
The output is actually drawn via a method which draws onto a wxDC. The "printout" uses the same method to draw as that which is displayed on-screen before-hand.
The PDF output is built-in to OS X before you ask if you can create PDFs with it too. You would otherwise need some kind of PDF-driver to do that on the other platforms. But this makes it easy to test with, since I don't actually need a printer attached.

Full printer support on its own makes wxMax quite useful :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Graphviz(Posted 2007-12-24)
I tried to update to the latest Graphviz source, but alas they've completely changed the event-handling code which breaks the interactivity... looks like I'll be sticking to 1.12 for the time being - unfortunately.

Two "plugins" are working - Max2D and Cairo - more or less ;-)

Need to now go over the docs, and see if I need to add any more examples/tuts for it.

However, this might be the most niche module I've done, so other than myself, I not expecting much feedback :-p

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

FreeImage-tastic!(Posted 2007-12-21)
Yay!!! I got FreeImage compiling under MinGW :-)

Farewell, FreeImage.DLL ........

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Or is it?(Posted 2007-12-20)
...Except that the wxLocale stuff doesn't seem to work properly on Win32 (go figure!). I've a nagging feeling that it's something to do with >ASCII character strings, so I'll have to have a play with that. Does work great on OS X tho :-p

The Graphviz refactoring is coming on excellently!!
Having abstracted out the rendering, I managed to get a working Cairo renderer for it last night. Pretty much plug-and-play too. The Cairo renderer was happy (if not slow) to interact with on-screen (like the Max2D renderer), and also outputted to PDF ;-)
Next up, I want to get a wxDC-based renderer for wxMax, although as it stands, it's probably good enough for a release - after some documentation checks.

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

wx localisations(Posted 2007-12-17)
Well, it took most of the day to sort out - *phew* - but I've implemented wxLocale :-)

It uses GNU's gettext to create the localisation files which one can then edit to add the locale-specific translations. I've also ported most of the "internat" sample, and it actually works!! ;-)

Anyways... something else for the wxMax mixing pot...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Still here :-)(Posted 2007-12-14)
Been a busy old time of late... which has kept me off the radar for a while.

Haven't been working much on wxMax recently, but I'm hoping to get back into the fray this month. I think I need to go through the code we have already and fill in the gaps, which should help beef things up a lot.

I've also stumbled onto http://wxpropgrid.sourceforge.net/cgi-bin/index
which looks pretty excellent - rather than hand-crafting your own. Need to give it a tryout on Mac first though before leaping in, as the notes say it may not be up to Win/Linux standards yet. If it does work, it'll be very useful.

In other news, I've abstracted away the rendering for Graphviz into a separate module, (eg. BaH.GraphvizMax2D ), which should allow the creation of other "backends" for the likes of Cairo and wxMax.
I've also been playing with a tool I knocked together over the weekend which parses BlitzMax code and generates class-diagrams. wxMax looks cool in diagram form ;-)

And I also now have a way to build Max modules that can integrate with MSVC-built C++ libraries (of which the ABI's are not compatible with MinGW). Works very well, and uses the same source for both Win32 and the other platforms ;-)

That may lead me back to finishing off my Subversion module, which I couldn't get running properly under MinGW.

:o)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

It's been a while..(Posted 2007-10-17)
But you know how it is... I've been busy working on getting the wxScintilla widget up and running.
There are around 500 methods in the API of this widget alone, but fortunately the author has seen fit to include a file that one can parse and generate stubs, etc from.
So much so, that I have been able to put a python script together which generates the methods (including docs), the extern section, and all the glue code!! It even compiles! ;-)
Now it's a case of filling in the non-generated stuff and work on getting a sample put together, as well as work out how to use it...
But, here's my first run of the widget on Linux :

It only opens a frame with the widget filling it, but it's a good start :-)

Line numbering, folding, lexing to come...

In other news, I've got a good amount of Chipmunk working, and have also spent some time setting up a repository on googlecode for it, as well as my other modules - the idea being that it will be easier for me to work on my modules if they are all available on a good repository. It even has its own issue tracker :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Forget multi-column lists...(Posted 2007-09-30)
... bring on spreadsheet style grids ;-)


No, it's not finished, or much useable yet, but I just *had* to post its first ever run!
Yes, it's BlitzMax... no, it doesn't use a canvas :-p

wxSheet is a beast of a control (along with all its related types, events and controls), but it's looking good so far :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Timewasting for dummies...(Posted 2007-09-30)
spent 4 hours or so yesterday debugging wxWidgets... yes, the actual library!... trying to work out why something wasn't doing what I thought it should be.

Still haven't gotten to the bottom of that particular problem, so rather than spend any more time chasing my tail for even more hours, I'm back to the usual stuff of wrapping. yay!

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Reasons for change...(Posted 2007-09-26)
I thought I should put the new wxMax module to some use, so I've decided to port my BLFBuilder app (the util that comes with my locale module) from MaxGUI to wxMax.

Have you ever tried using the "check" menus in MaxGUI? It's a nightmare to get it working cross-platform. On wxMax, we have RADIO menus, as well as normal and check menus. Sorted!

Here's my old event handler:
		Case MENU_VIEW_NATIVE
			If nativeLanguages Then
				' make sure the menu stays checked...
				CheckMenu(TGadget(submenus.ValueForKey("menuviewnat")))
			Else
				CheckMenu(TGadget(submenus.ValueForKey("menuviewnat")))
				UncheckMenu(TGadget(submenus.ValueForKey("menuvieweng")))
				
				UpdateWindowMenu window
				
				nativeLanguages = True
				
				setLanguageTexts()
			End If

I wanted it to work like a radio group, where you select one, the other de-selects. There were issues where you clicked on one that was already checked, it would uncheck it... *sigh*

Here's my new handler:
	Function OnViewNative(event:wxEvent)
		Local frame:TBLFBuilder = TBLFBuilder(event.parent)
		
		If Not frame.nativeLanguages Then
			frame.nativeLanguages = True
			
			frame.setLanguageTexts()
		End If
	End Function

Since I can let the UI handle the UI side of things, I only have to concern myself with the data/model.

Breath of fresh air ;-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Event loops(Posted 2007-09-25)
I had a whole-hearted attempt today to override the MainLoop of wxApp, in order to be able to drive an app that way - for those that may need that kind of control (e.g. have a render/update process that can give control over to UI events when required, rather than the other way around).

Anyhoo... it didn't work... so back to the drawing board.

To cheer myself up a bit, I finished a couple more controls - the small ones only take 20 mins to wrap.

:-/

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Streams for the masses(Posted 2007-09-22)
Been busy over the last day or so with getting stream support working for things like wxImage and wxBitmap.

I've pretty much got it sorted out now, which means you can in essence do something like :
...
Incbin "media/rotate/duck.png"
...

bitmap = wxBitmap.CreateFromFile("incbin::media/rotate/duck.png", wxBITMAP_TYPE_PNG)

...

or you pass in a TStream, etc.

Of course, everywhere that something "loads", I'll need to implement the underlying code, but that's not something any of the users will ever need to know about ;-)

Now that I know that works, back to wrapping more widgets...

:o)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Rows and columns(Posted 2007-09-18)
Quick quiz...

Q. What do you get if you add two columns together?
A. Multi-column lists...



;-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Sampling the widgets(Posted 2007-09-15)
At least one can say that the samples that come with wxWidgets are pretty darn thorough!

It feels like it has taken me half my life just to get everything that needed to be done in order to get the Menu sample working. But it's done now! *phew*

The Menu sample covers your basic menu events, adding, removing, relabeling, menu popups (and positioning!), accelerators, menu item specifics, custom event handlers (which is rather cool), and logging.

As far as I can tell, the BlitzMax sample does all that the original C++ one does. (which is what you want really).

Next !!

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Getting Committed(Posted 2007-09-12)
Having a central repository makes coding much easier... or at least, less hassle.
Especially when I'm at work, and I want to do some more during lunch... svn update... code ... commit.
Then I can update again when I get home - saves having to copy files onto flash drives and whatnot.

Struggled today getting the logger to work, but it's all sorted now. 3rd time lucky, in this case. (if at first you don't succeed, try, try again!)

Had a look at the wxRichTextCtrl sample this evening. I think that is going to be very nice to have. I especially liked the Print Preview screen... Cross-platform printing support anyone?

:-)

Oh, and thanks to David of Gibbon Games, for volunteering to work on some samples porting. The feedback helps get things done more quickly.

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

The grunt work...(Posted 2007-09-08)
Now that I've got a proper repository/issue-tracker/group setup for it, I can get back into churning out all the code.

...of which there is a lot to do.

Fear not... no mountain is too high... no ocean too deep... etc :-p

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

AUI on Mac(Posted 2007-09-03)
Same BlitzMax aui-framework sample app, this time compiled on OS X (PPC) :


Been having some problems with Application focus on the Mac.
It turns out that having Appstub do some Cocoa magic at the start, it throws wxWidgets (Carbon!) in several places. The important one is when you focus away from the app and focus back the main app Window doesn't come to the front - it's as if the app doesn't realise it has become active again.
So, another hack to appstub to not call NSApplication (ie. don't tell OS X we are a cocoa app), and it works properly.
However... *that* means that when you launch the app from the IDE, it doesn't jump to front by itself - this I believe could be considered a bug with the IDE, where it should probably be telling the app in question to be active. (this isn't an issue when you double-click the app icon from finder).

So, a couple of Mac related issues which aren't the end of the world, and hopefully will be resolved in time :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

C++ objects...(Posted 2007-09-02)
Finally getting to grips with this c++ object life-time malarky.

On Linux, an object will expire as soon as it loses scope. On Windows, it appears to hang around.

So, when a function returns an instance of something (not a pointer), how do we hang onto it when we leave the cozy confines of a C++ wrapper function and head on back to BlitzMax?

An example:
wxBitmap.ConvertToImage() returns a wxImage

But we can't really return a wxImage object, as it will go out of scope and be gone... so I've implemented a wrapper class which holds a copy of the wxImage object, and then I can chuck around a MaxImage* without having to worry about anything.
MaxImage creates a copy of the wxImage, and holds onto it throughout its lifetime. When it is deleted, the wxImage goes with it (or at least, its internal reference count is decreased).

The same issues apply to wxBitmap and others too, which are all being wrapped.

classes such as wxFrame are always new'd, so we don't have to worry about those.

:-p

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Happy September !!(Posted 2007-09-01)
Crivens!! Is it September already??

To celebrate, here's how the framework has been coming on...

The image represents an almost feature-complete port of the C++ auidemo app that comes with wxWidgets.
Panes can be dragged around and floated. The notebook pane (the one with the tabbed pages) is very flexible. Tabs can be re-ordered by dragging, as well as pulled out and given their own area (essentially creating new sets of tabs). The look/feel is quite customizable - the demo lets you mess around with lots of settings - live.

Trust me to pick a sample app that appears to use *most* of the bloody wxWidgets features...

And of course, the app is pure BlitzMax :-)
Code snippet...
....
    Method CreateNotebook:wxAuiNotebook()
        ' create the notebook off-window to avoid flicker
        Local width:Int, height:Int
        GetClientSize(width, height)

        Local ctrl:wxAuiNotebook = New wxAuiNotebook.Create(Self, wxID_ANY, width, height, 430, 200, notebookStyle)
		
        Local pagebmp:wxBitmap = wxArtProvider.GetBitmap(wxART_NORMAL_FILE, wxART_OTHER, 16, 16)
                                    
        ctrl.AddPage(CreateHTMLCtrl(ctrl), "Welcome to wxAUI" , False, pagebmp)
.....


Anyhoo... almost up to the 60 module mark with this little project now... many still acting as stubs, and probably more to come later. There's a hell of a lot of code in wxWidgets...

But, you have to admit... it is a bit more useful than MaxGUI ;-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

More WIP ;-)(Posted 2007-08-29)
Here's a little sneak preview of things as they are progressing...



This is part of the fully customizable, draggable, resizable panes, etc AUI part of the framework.
Any control (like a text control, or grid, or note book, etc) can be contained inside a pane. Even, I imagine, a scintilla editor window...

Things are getting interesting :-)

Oh.... did I mention it's all fully cross-platform? :-p

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Refactoring(Posted 2007-08-27)
Decided to do some moving around in order to make it easier to use the framework.

Apps need to implement OnInit:int(). This is where you put your application initialization stuff... (like creating a window) :
Type MyApp Extends wxApp

	Field frame:wxFrame

	Method OnInit:Int()

		frame = wxFrame.CreateFrame("Hello World", 100, 100)
		frame.show()
	
		Return True
	
	End Method

End Type


If you want to extend wxFrame (ie. to put your callbacks and such into it, declare controls, etc), you should also implement an OnInit().
There you can create your controls etc before the window is displayed :
Type MyFrame Extends wxFrame

	Field notebook:wxNotebook
	Field listbox:wxListBox
	Field textlog:wxTextCtrl
	
	Method OnInit()

		Local fileMenu:wxMenu = wxMenu.CreateMenu()
		Local helpMenu:wxMenu = wxMenu.CreateMenu()
		Local menuBar:wxMenuBar = wxMenuBar.CreateMenuBar()
... etc


which I think is reasonably clear.

It's certainly a step (or four) away from MaxGUI, and hopefully, will be very much easier to code.

For example, you use Connect() to attach an event handler:
Connect(BUTTON1, wxEVT_COMMAND_BUTTON_CLICKED, OnButton1)

where BUTTON1 is a unique id for the event.

Your callback would look like:
	Function OnButton1(event:wxEvent)
		wxMessageBox("Click1", "Click", wxOK | wxICON_INFORMATION, wxWindow(event.parent))
	End Function


Back to work... :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

How many....(Posted 2007-08-25)
...modules does it take to wrap wxWidgets ?

Counting 41 at the moment - with more surely to be added over time.

Okay, so a lot of them are just stubs for now, cuz there is a mind-numbingly large number of them to do.
Some of which have a brain-mushing large number of methods - wxWindow has 150+ of them!! And I can only do so many at a time before I want to jump out of my study window :-p

Still, progress is going well, considering. I can only type so fast... ;-)

I was also pondering whether this should go "community", but I can't see anyone wanting to spend much time on building this beast - Otherwise someone would have done it already.

But who knows. Maybe somewhere like google code would be a great place to host this (I have *no* idea how to set one of those up, tho).

Anyways... back to wxTextCtrl...

:-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Checkable list boxes(Posted 2007-08-24)
Here's a nice fully-working BlitzMax checkable list box demo :



As well as checkable list boxes, this example demonstrates the event model, as well as sizers (the controls aren't fixed to a specific place, and move about as the window is resized).

Thanks to Mr Sibly for the array conversion code. I had a hacky Max version of it. Now it's tucked away under the hood :-)

I rewrote the event stuff when I realized that in order to have different controls in different modules, their events would have to sit with them, rather than in the core.
So I copied the Pixmap Loader style of auto-loading the event factories. Works a treat, and means the core doesn't need to care about what events are available - as it should be :-)

Had a proper look at the grid control last night. It's quite scary :-p

I'm going to have to get clever with callbacks to get all the functionality out of it...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

New namespace....(Posted 2007-08-23)
Okay.. I give up...

I'm going to use a new namespace, and split out the controls and stuff into separate modules. This means you get more say in what exactly gets compiled into your app - rather than *everything*.

eg.
Framework wx.wx
Import wx.wxTextCtrl
Import wx.wxListBox
Import wx.wxNotebook

which says I want to use text controls, list boxes, notebooks, as well as the core features.

the wx.mod namespace just makes it easier to work with - rather than adding X amount of new modules to bah.mod (which is already fairly busy!).

:o)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Better events....(Posted 2007-08-23)
I've been tweaking the event model...

    Connect(LISTBOX1, wxEVT_COMMAND_LISTBOX_DOUBLECLICKED, OnListBoxDoubleClick)

would call...
Function OnListBoxDoubleClick(event:wxEvent)

    MyFrame(event.parent).textlog.AppendText("ListBox Double click String is: ~n" + ..
        wxCommandEvent(event).GetString() + "~n")

End Function


I would have preferred my callback to be xxx(event:wxCommandEvent), but it seems BlitzMax doesn't allow us to use a function pointer with a sub-type as a parameter.

Not a great loss... just something the user will need to be aware of.
Other than that, I love the way events work. Much less verbose than the MaxGUI way.

:o)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Why oh why does Blitzmax...(Posted 2007-08-22)
...insist on linking *everything* once I create a function which calls it.

Example :

* Library has a.c file with function A().
* Module wraps with an Extern Function A() ...
* App X Imports Module but doesn't use the function call.

But App X has the a.o object embedded inside it because of the wrapper.


Therefore, you get 100% of the library included in your app, even if you use 1% of its functionality.

No way around this Mark?? :-(

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Eventful...(Posted 2007-08-21)
Still playing with the event model... but it's working :-)

..........
		Connect(wxID_EXIT, wxEVT_COMMAND_MENU_SELECTED, wxMenuEventHandler, OnQuit)
		Connect(wxID_ABOUT, wxEVT_COMMAND_MENU_SELECTED, wxMenuEventHandler, OnAbout)
		
	End Method

	Function OnQuit(event:wxEvent)
		' true is to force the frame to close
		wxWindow(event.handler).Close(True)
	End Function
	
	Function OnAbout(event:wxEvent)
		
		wxMessageBox("Welcome to " + wxVERSION_STRING + "!~n" + ..
                    "~n" + ..
                    "This is the minimal wxWidgets sample~n" + ..
                    "running under " + wxGetOsDescription() + ".", ..
                 "About wxWidgets minimal sample", ..
                 wxOK | wxICON_INFORMATION, wxWindow(event.handler))
		
	End Function
......


Not *too* messy...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Expensive taste?(Posted 2007-08-21)
Almost straight duplicates of the wx "samples"...

The object extend creation is a bit crappy, but I don't see Max having a less verbose way to do it than this....

The other option is not to extend the wxFrame and do things like frame.SetMenuBar()... but it's neater (cleaner) to have everything "inside" the type itself...



Win32 requires static libs at link-time rather than shared objects (dlls). Nicer in that your .exe is not relying on external dlls. Worser, in that it makes *bigger* exes.


Anyhoo... not too bad for < 24 hours (wall-clock time, not hours worked on)....

Oh well.. I should probably get back to something more useful now.

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Cheap Thrills....(Posted 2007-08-20)
What to do on your day off...

SuperStrict

Framework BaH.wx

Type MyApp Extends wxApp

	Field frame:wxFrame

	Method init:Int()

		frame = wxFrame.CreateFrame("Hello World", 100, 100)
		frame.show()
	
		Return True
	
	End Method

End Type


New MyApp.run()



Definitely *not* MAXGUI....

:-p

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Multi-page images !(Posted 2007-08-19)
Thought it was time to add multi-page image support to the FreeImage module. FreeImage currently handles GIF, ICO and TIFF multi-page formats (by multi-page, read multi-frame),

Introduced a new type TMultiFreeImage to control manipulation of these. You can modify, append, insert, remove pages from an image.
Also added helpful functions like :
Local image:TImage = LoadAnimFreeImage("anim.gif")

... which create a multi-frame TImage from a multi-page image. Perhaps useful to someone.

It turns out, alas, that FreeImage doesn't actually support multi-page MNG files. Apparently, there are deficiencies with the libmng library that it uses... Using my fix of the previous entry below, we can at least see the first image of a mng...

Will need to check the new code on OS X and Win32 before this release goes public.

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Ming, (the merciless)(Posted 2007-08-18)
Funny that the FreeImage states that .mng files can't be determined by their file header, which turns out to be the reason why .mng images don't load.

So, I rummaged around the mng spec and found this :
The MNG datastream begins with an 8-byte signature containing

    138  77  78  71  13  10  26  10  (decimal)
     8a  4d  4e  47  0d  0a  1a  0a  (hexadecimal)
   \212   M   N   G  \r  \n \032 \n  (ASCII C notation)

which is similar to the PNG signature with "\212 M N G" instead of "\211 P N G" in bytes 0-3.

so I ripped the validation code for PNG and used it for validating the MNG, and guess what? It loads .mng files now :-)

But... it doesn't appear to support multi-page mng files - which seems kind of pointless....

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

SSL !!!(Posted 2007-08-17)
The bah.libcurlSSL module is up on the site now, at last. Everything appears to be working at it should :-)

Also posted an update to bah.libcurl, which adds the previously mentioned c-ares support :-)

And, last but not least, an update to bah.DBSQlite, bringing it in line with the current SQLite 3.4.2 release.


...and for my next trick...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Libcurl - the next version(Posted 2007-08-16)
Hot off the back of the initial libcurl release I'm already looking at the next version, which will include the c-ares library as part of the module.
c-ares does DNS requests and name resolving asynchronously, which makes for *faster* page-loading, as it isn't hanging around waiting for things to happen. (obviously only the name resolution bit is faster!)

Anyhoo, I dropped the code into the module changed the config.h, and as if by magic it compiled and worked first time. (On Linux :-p)
And, it *appears* to connect to the server much more quickly than before - but perhaps I'm imagining things...

Looking forward to the next version (7.17) of libcurl to come out, as it will mean I can remove a lot of the memory-handling code I had to implement for strings. I've tried the latest cvs-snapshot and it works well, but I think I will rather wait til it goes gold before using it proper.


As for the libcurlSSL module. Have been testing it quite extensively and it feels about ready for primetime. I just need to add some documentation (for the SSL-specific stuff), and that should be that.
Kind of gives you a warm, cozy feeling inside, when you enable verbose and watch as your little BlitzMax app negotiates with the webserver, passing certificates, and generally being secure ;-)

Hopefully it'll be out over the weekend, all going well...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

At last !!!!!!(Posted 2007-08-13)
Well... having the day off work helped me plod through all the documentation that needed done. Hopefully that's it - I've been through it three times now, which is enough to drive anyone insane.

Spent 10 mins building (for the first time) on OS X, with only a couple of config options to tweak. All the examples worked as expected :-)

So here is the first release of the libcurl module.

Yay! :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Niggles(Posted 2007-08-12)
It's all the niggly last little bits that tend to drag a person down. The things I tend to leave til the end, cuz it requires a big load of effort/debugging/crashing until it all gets working.

Things like returning a String array from a method, of which internally the data is stored in a c-struct linked list, which may, or may not, be null.
And *then* realising, after much testing and trying to work out why it was always returning nothing, that in fact, had I read the documentation properly in the first place, I would have known to call something else first, in order for it to populate the array :-p

Still, it's all a lot of fun really. Another String array thingme to do, and hopefully that'll be it for the main libcurl coding effort. Then it needs some more examples, and a whiz through the docs.


On another note, we see a new libxml release, which adds improved error reporting, by allowing you to add a callback which will be called for each error found while the library parses the xml.
I've also made the TxmlError type a bit better with much more exposure to the information it contains... like line number, column numbers, extra text info etc...

The freeimage mod needs some more work too... It's on my list of things todo :-p

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

SSH support(Posted 2007-08-10)
Have built a libssh2 module for ssh support with the libcurlssl module.
All compiled up on Linux for now.

libssh2 requires openSSL, which is also required by libcurl. libcurl requires libssh2 for SFTP/SSH supprt. So it all kind of goes hand in hand :-)

Windows users will have to download an openSSL binary to add that support (you also get the DLLs with things like subversion clients). openSSL is usually pre-installed on Linux and Mac systems (although for compiling on Linux one will probably need the openSSL dev package)

However, as usual I'm getting ahead of myself. *Really* need to finish the vanilla libcurl first before I start fiddling with all this crypto wonderment that is SSL...


*sigh*... anyone at all interested in putting together some insightful examples?

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Has it been so long...(Posted 2007-08-10)
...since I updated here?

Did a wee update to the database/mysql mods yesterday, making the object GC a bit stronger in places. Funny how you can spend half-an-hour trying to work out why something isn't being GC'd when it should... :-p

Have got the "multi" interface for curl running. It's cool :-)
Basically, you give it a list of URLs to process, and off it goes, transferring them all at the same time... in a non-blocking way, no less!!
(the easy interface blocks, which ties you up until the transfer finishes - which is okay for some situations, but not for others)

With the multi-interface, you have control of when to let curl do another chunk of data. Something you can put into a loop somewhere, perhaps.

Also added another "helper", which lets you write data into a String, rather than having to set up a stream/callback. Possibly not the most efficient way to do it, but as a quick hack to get a String of info from the internet, it's as easy as...
    curl.setOptString(CURLOPT_URL, "http://some.site.com")
    curl.setWriteString()

    curl.perform()

    Print curl.toString()


Still a few array structs to sort out, but it's looking good.

:o)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Wrapping takes time...(Posted 2007-08-06)
And don't I believe it !?!?!

As anyone who's used any of my modules before will know, I tend to wrap things up in a way that makes it easy use in a "BlitzMax way". That is, doing all the Byte-Ptr / C-struct conversions behind the scenes, so that you don't have to. (Even, I might add, crafting C++ classes to make that integration easier - Yeah, I'd never have imagined that I would have used another language to help me learn C++.. but there you are!).

Of course, all this in-between stuff takes time, and kind of drags out the development of new modules somewhat. The curses module is a case in point. I trawl through docs and code (library examples and source/headers) to get a widget together and eventually have a nice working version of it running in Max.
Then I get distracted ;-) , and find something else todo (so my brain doesn't go into meltdown) until I feel up to tackling another widget.

That, and I find lots of enthusiasm for tackling a new module every so often. Like the libcurl one. It's really very cool. I had looked at it once before when someone on the forums was looking to do SSL, but it wasn't much of interest to me at that time.
But times change :-)

The non-SSL module is coming together nicely. Mostly done now. Just some structs I still need to sort through, but the examples are working well. That said, I've only been testing HTTP and FTP... but I assume the other protocols will work as well.

Internet access anyone? ;-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Utils R Us(Posted 2007-08-04)
Been working on some examples for the libcurl module.

Accessing the internet doesn't get much easier than this ;-)

In the process, I've hacked together yet another new module, called FTPParser. It parsers FTP directory listings, and gives you special file objects that hold details such as file type, size, timestamp etc.
The module uses my RegEx module to parse the listings. (see, they all come together after a while!)
It supports 8 different kinds of FTP server output, and should be useful for those wanting to do stuff with FTP.

It's actually stand-alone - that is, it doesn't require libcurl - but unless you know how to get a directory listing another way, it might not be very useful otherwise :-)


So, I've been testing HTTP and FTP through the libcurl module, and I'm reasonably happy with it so far.
There are going to be TWO APIs for write/read callbacks. One that uses a Stream, and one you get full access to the Byte Ptr/size - as I'm sure someone will want to play with it at that level.
But the stream integration appears to work well enough.

Once the non-SSL libcurl is working on all three platforms (currently running on Linux/Win32), I'll tidy up the docs, finish the examples and release that. Then I can play with the SSL version... though that's likely a whole 'nother ball game...

;-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Two versions(Posted 2007-08-03)
I've decided to build two different versions of the libcurl module. One with SSL support, and one without.
Why oh why?

Well, once SSL is included, it requires a whole load of other libraries, and if you don't intend using HTTPS etc, then why do you need to install libs that you won't want?

Hence, I'll do two version... libcurl.mod and libcurlssl.mod, then the user can decide which is best for them :-)

Other than extra library requirements, the modules will work in the same way.

Now to work out how to use Streams with it :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

More distractions....(Posted 2007-08-02)
A couple of hours later...
SuperStrict

Framework BaH.libcurl
Import BRL.StandardIO

Local curl:TCurlEasy = TCurlEasy.Create()

curl.setOptInt(CURLOPT_VERBOSE, 1)
curl.setOptInt(CURLOPT_FOLLOWLOCATION, 1)
curl.setOptString(CURLOPT_URL, "blitzmax.com")

Local res:Int = curl.perform()

curl.cleanup()

....
Executing:ex_01.debug
* About to connect() to blitzmax.com port 80 (#0)
*   Trying 66.103.20.95... * connected
* Connected to blitzmax.com (66.103.20.95) port 80 (#0)
 GET / HTTP/1.1
Host: blitzmax.com
Accept: */*
< HTTP/1.1 200 OK
< Transfer-Encoding: chunked
< Date: Thu, 02 Aug 2007 19:21:02 GMT
< Content-Type: text/html
.......


This would be nice with SSL and SSH2 support, me thinks.
Supports all kinds of callbacks for Stream handling and progress.... ooer...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Curses!(Posted 2007-08-01)
Back on the console GUI module at last!!

Easing myself into it by implementing an Alphalist widget, which allows a user to select from a list of words, with the ability to narrow the search list by typing in a few characters of the desired word.
The example also required the use of function (F) key bindings, so I've added a transparent mapping of F-keycodes to curses function keys. This makes things like pressing F1 for help while in the middle of using a widget, possible.

Still a large number of widgets to do... as well as implement some of the more low-level curses functionality (although the UI stuff is top of the list for now).

Some of the widgets I haven't even tried yet, so it's going to be fun finding out what they can do :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Finally....(Posted 2007-07-31)
....released the DateTime module, which seems to have taken me a good part of forever to complete. It's a bloody massive beast, and I think there is still some stuff I will have to implement at a later date.

But for now, the module covers most of the functionality provided by the library.

There are dates, date durations, date periods, times, time durations, time periods, date iterators, local times, time zones, and localization via date facets.

What's taken me so long is writing the docs, compiling examples, and putting together the localization for month and weekday names (both long and short format). I've included 74 language translations using the .blf format of my Locale module. That covers most of the major languages, I think. But you can always add your own too, if you need to. It's just a case of passing the required strings into the date facet, and setting that facet as the default... after which all month/weekday output will reflect the new texts.

The module lets you do all kind of maths on dates and times, and ranges of them, and I doubt there is much you would want to do with date/times that isn't covered by the module.

Thorough ;-)


....I need a rest...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Round 2(Posted 2007-06-30)
Currently working on the second beta of the graphviz module. A few bug-fixes to sort out font fallback, and a problem with the graph drawing doing strange things after so many refreshes.

I've also implemented dot/dash line styles, available if you supply the appropriate driver implementation. At the moment, I've only coded an OpenGL one. I don't even think line stipple is supported by DX7 on Windows...

Have optimized bezier drawing to 10 parts per curve. It was doing way too many before.

The biggest addition is the currentObject() method, which gives you access to details of the object currently under the mouse. There is already a selectedObject() method which does the same for the selected object. Both of these methods should (hopefully) give more than enough information on objects in the graph.
Although, I'm wondering whether or not a kind of Map lookup for a specific attribute value would be useful.

...still got the documentation to sort out...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Better Text(Posted 2007-06-28)
So... image fonts don't scale. End of story.

Therefore, I've implemented a workaround. Fonts are cached at x3 scale, and then scaled down for a normal x1 graph view. This way, when you zoom in, the graph looks nice for a long way before you can start to see jaggies appearing around the glyphs. And by the time you get to that level of zoom, there's not much of the graph visible.

Essentially I'm scaling text by 0.33, 0.33. Seems to work okay in my tests... although I'm not sure how much of a speed hit there would be if there was a *lot* of text being rescaled like this...

Looking better :-)

.. Oh... and text display now supports UTF8 properly too.. yay!

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Documentation(Posted 2007-06-27)
You know a module is progressing well when its zipped up doc folder weighs in at a hefty 196k.

I've been adding all the Graphviz documentation, tweaking where required. It covers creation of .dot files and more attributes than you can throw a stick at. All available from the IDE - which is the whole point, really.

Some module makers would have you go off to look at the original C-API documentation in order to try to understand what to do with whatever it is they've thrown together in a couple of hours.

I try and keep the average Max user away from having to deal with Byte Ptr and its friends. Because I can.
In theory, that makes both of our lives easier, since 1) Bugs are likely to be mine - in regards the interface to the real API, 2) I don't have to try to explain that you can't do X with Y() because you haven't yet created a Z...

At the end of the day, I build modules that *I* would want to use. I certainly don't want to be coding BlitzMax using Byte Ptrs everywhere...

(yes, I know that last sentence kind of contradicts what I seem to do most of the time... ;-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

---censored---(Posted 2007-06-26)
..so.. remind me again why I do this??

no.. me neither.

Just spent the last two hours debugging the Mac port of the graphviz module.
It used to work... then I did all that refactoring etc.. in Linux...
And I thought it was about time to try it again on Mac.

So... two hours of hair-pulling later (it shouldn't core-dump on strlen!!!!!)... I eventually ran ./configure on a proper graphviz distro, and went thru the config.h file, making sure everything was set properly.
Then I deleted all the .bmx folders, and rebuilt the ***** thing... ;-)

Anyways... it's working perfectly now on Mac... :-p

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

BlitzMax isn't just for games!(Posted 2007-06-26)
Back again, with another update...

I've been pottering away with the API graph building, and I must say, it's bloomin easy to use :-)
Here's a small example snippet:
Local graph:TGVGraph = TGVGraph.Create()

' create some nodes
Local node1:TGVNode = graph.addNode("node1")
Local node2:TGVNode = graph.addNode("node2")
Local node3:TGVNode = graph.addNode("node3")

node2.setAttr(ATTR_NODE_FONTCOLOR, "red")
node3.setAttr(ATTR_NODE_SHAPE, "diamond")

' join the nodes together
graph.addEdge(node2, node1)
graph.addEdge(node3, node1)

' now to construct the graph..
renderer.buildGraph(graph)

I've left out the drawy stuff, cuz that's just the same as for all of them. This just highlights how little work is involved in creating a directed graph.

Oh, you want to see what it looks like?

Notice, if you will, the setting of attributes. I've configured a couple of useful ones as Constants, but there are tons of them available to play with - all of which I hope to have available in the documentation.

I think the Graph/SubGraph/Node/Edge API for creating your own graphs on the fly is about as simple as it gets. If anyone has any other ideas, I'm always open to them...

Still lots to tidy up.
I also need to add a way define default colorings - there's a number of "global" variables that can be set in the library to define default colors of node/edge parts etc...

I also need to make sure I get the structures cleaning up properly, once they're finished with. That and support for creating one graph, then another using the same base object (ie. multiple calls to buildGraph().)

fun fun fun ;-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Even better graphs....(Posted 2007-06-25)
Graphviz has the ability to support a subset of HTML instead of a plain label string.
So, rather than a plain looking label, you can give your graphs a whole new dimension :


The one caveat is that this support requires the expat library (for the processing of the HTML), and thus I've had to add a BaH.Expat module for this. I think it's well worth it though...

I'm currently working on an implementation of creating an in-memory graph (or model), which you then feed into the renderer, which constructs a real graph.

I've also posted a bug fix with the graphviz guys while I was getting my code to not crash ;-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Toasty(Posted 2007-06-24)
It's all coming together now....

Opened up access to graph attributes, which may, or may not, be useful :

accessing it with something like :
Local obj:TGVObject = renderer.selectedObject()

The object can be the Graph, a node or an edge.

I've also added support for custom Origin and "Viewport" size, so that you can, for instance, have the graph displaying in a specific location on the screen. It also, in theory, supports resizing of the draw area (if you happened to be using it in a canvas, for example).

There's also a url/href field that I'll expose which might be useful for something... ;-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Algebra(Posted 2007-06-23)
Given the equation :
x1 = zoom * (x - offset) + xorigin

...find x.
Which turned out was all I needed to do to fix my zoom/selection problems.

Of course, it took me long enough to get it down to this simple form. I guess I thought it was a much more complicated problem than it actually was.
But that's one less problem to worry about now :-)

Having way too much fun with this module for my own good, I think.
I'm even hoping the Graphviz guys will have some ideas for the "drag an object" code - assuming it's not a massive job to implement. If it's not, I may well have a go at it myself...

But for now... back to the attributes... ;-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Tooltips(Posted 2007-06-22)
Busy busy today.

Decided it was time to re-factor everything. Usually, when I'm building something like this, I tend to add code here, try this, try that, and generally hack around with API calls until I get it to a point where things are working in a way I can use.
Up til now everything has been done in a Type, but globally - using Functions and Globals instead of Fields and Methods. This makes it easier to change things as I go.
So the big rewrite commenced. Turned out not to be too bad, as I had the vision in my head of how it would work, and just the tiniest thought in the back of my mind that if it didn't work out I'd have to go through it all putting everything back... :-)
The crucial bit was finding somewhere in the API that I could attach a reference to my Type. That is, a "void *" attribute in a struct that the library didn't use itself. Once that was sorted, it was just a case of attaching my Type object to the graph - in theory allowing multiple graphs at a time - no I haven't tried it yet :-p

With everything set now, it was time to start playing again... going into the API and adding features - always the best bit, I think.

How's about tooltips ?


(the image shows a tooltip for the highlighted node - just under the mouse pointer which doesn't appear in the screenshot)

In the graph, as well as labels, you can define a tooltip - I guess for a graph that you might output as an imagemap (HTML). Fortunately it's easy to access this information, and there it goes... when you mouse-over something with a tooltip, you can ask it to display it.
' redraw the graph
renderer.refresh()

' show the tooltip if there is one.
renderer.tooltip(x, y)

the tooltip() method also has an optional Style parameter, that lets you customize the look - font, size, pen/fill/font color.

Talking of colours, did you know that Graphviz supports several hundred named colours, as well as your choice of RGBA and HSV notations.

I'm planning on including all the graphviz docs with the module - as usual.

Next on the list is access to the object's attribute data. It's all there, I just need to figure out the best way to present it to a BlitzMax user...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Graph - Icks!(Posted 2007-06-21)
I'm not entirely sure Graphviz was meant to be used the way I'm bending it to be... but so far it's looking pretty good.

The graph now detects when you mouse over something - yes, the graph does. Be it a node or a connecting line. You can even click on a node and it becomes "selected". This, in theory opens up information that the node contains, but I haven't exposed that part of the API yet.

It's been a task in itself just getting everything scaling properly. Aye... if you scroll the scrolly wheel on the mouse, the graph zooms in or out, based on the position of the mouse on the graph.
The main problem I'm having at the moment is that once you zoom past 1.0, the coordinates between the mouse and the graph go off. Graphviz tries to map the mouse back to it's scaled graph size, but there's something off somewhere.
However, I'm going to leave that small issue aside and concentrate on the rest of the engine.
If you right-mouse-button hold and drag, the graph pans with the mouse. So, all in all, it's quite a sweet set of controls.

I'm going to look into the rest of the object API next, to see what nice things I can add. There's "tooltips" which might be nice to have as you move the mouse around the graph.
There's also default colouring of mouse-over, selection, selected, visited - all of which I believe can be set at run-time.

Of course, the bestest thing would be to be able to click and drag a node around - perhaps saving the new layout for later. Alas, delving into the Graphviz source we see this :
    case 1: /* drag with button 1 - drag object */
	/* FIXME - to be implemented */
	break;

which implies that they never got around to building that piece of magic...

:o)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Oh dear.... and other ramblings(Posted 2007-06-14)
...there I go again, being distracted by yet another library.

I've used Graphviz on and off for a long time. Even integrated it (webdot) into our MoinMoin wiki at work (which was an experience!).
Never thought about making a module out of it until the other day, when it dawned on me that it would be something really cool if it could be done properly.
I first dug around looking for a way to get Graphviz to do GL, but the only apparent route open was by way of Cairo and Glitz. But I've had a look at Glitz and haven't as yet figured out how one might hack that into BlitzMax - given it seems to want to use its own context.

Then, after reading more of the API, it turned out that you can write your own "renderer" for Graphviz, which lets you take control of how lines, shapes and text is output. So I thought, "hey, wouldn't it be kinda cool to be able use Max's own drawing routines to render the graph to the screen/window!?".
Not having non-fill shapes was a bit of a minus, but some digging through the forum brought me some examples. (note - Max isn't very extensible here, I feel, as I'd like a built-in function to draw a set of non-poly lines in one go. Haven't figured out how to do this using the "current" driver).

Luckily Graphviz comes with lots of plugins / renderers from which to learn how to make your own. After a few false starts it's finally coming together. Text is rendering nicely, colours seem to be working, and the graph is drawing the right way up now too ;-)

My next trick is going to be to try and build a "device" plugin, which I believe will let me control the rendering better, and let me resize the graph at will, along with a host of other things. Not sure how long this will take... :-p
I have this image in the back of my mind whereby you can click and drag a node around the graph... but I may have had too much Irn-Bru this evening. (yes, you can even get it here in SA!)

Someone has asked me to do a libpsd module. Hacked a compilable module out of it earlier this evening (this will also require a libexif module which I'll have to do too). So, it's now a module ;-)
Well, there's no BlitzMax interface for it yet.. and there seems very little in the way of API documentation. I guess the next part will take a little longer to do - ie. working out how you are meant to use it, and fit it into a BlitzMax context. Still, another two imaging modules for the masses :-)

Console and DateTime are not forgotten... but you know how it is by now.. I get distracted for a while with a new toy, and come back to work on the old ones again in time. So, stay tuned for more exciting details...

:o)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Time is money !(Posted 2007-06-11)
..well, not when you are giving everything away for free...

But anyhoo, I've started work on the date/time formatting functionality, as well as trying to get localization in.

March 1st, 2007 in German...
2007-Mrz-01


The difficult bit I think will be to find a nice way to do the locale name in a cross-platform way. Alas Windows does "German-Germany" whereas the rest do "de_DE"
As usual, Windows has it's "I'm dumb" hat on...

Still, it seems to work - if you use the correct locale text - so I guess it'll do for now.

I'll also allow the user to customize their own texts, just in case they don't have the locale available on their system...

Looking good so far... :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Taking time...(Posted 2007-06-09)
Okay, so maybe there's more to do than I thought, with the DateTime module.

I've currently implemented TDate, which has a whole pile of functionality for adding, subtracting, and doing various things to a date.
Extending from this are TDateIterator, of which there are three kinds - TDateDayIterator, TDateMonthIterator and TDateYearIterator. These let you move forward or backward by a defined step size from the initial date.

Also there's TDatePeriod, which defines a range between two dates, and has some methods for doing contains, intersection, length, etc.

..which is all I've done so far.

Next up is the Time stuff.
Looking at this, we'll likely end up with a TTime, TTimePeriod, TTimeDuration and probably some TTimeIterators.

The there's "local" time, which represents locale/time zone calculations and the like. I believe this is quite flexible, and should be a challenge to get working in Max.

And finally, there's a whole load of stuff on date/time formatting (of strings). It looks like this is the biggest section... but it will give a lot of options for making the date/times look pretty...

:o)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

I've got a date !(Posted 2007-06-08)
Yeah... I'm finally doing the DateTime module...

It's coming together really quickly.
We'll have dates, periods, intervals, times, and other stuff too I imagine.
Perhaps even localized support for day/month names... but we'll see how easy it is to do that in Max...

Max rocks! Go Mark ;-)


<rant>
Good for Mr Armstrong and helpers getting the SDK out of the door... :-)

But... what's with all the forum flaming/cattiness... good grief... Is this what Indie developing is all about? Scratching at eyes, pulling hair, and biting ?
Meaow.... grrrr....
</rant>

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Onwards....(Posted 2007-06-05)
Plodding along adding more of the widgets.

Apparently there are 21 in all, from labels to complex cell-based matrices (don't ask.. I haven't looked at that one yet).
I imagine a lot of them aren't likely to be too useful - like the graphs and histograms - but probably just as well having them all in.

And *then* there's low-level curses command-set which is huge. I'll probably expose some of it to Max, but who really wants to do that kind of curses coding?
I suppose it's handy for games and things - where you don't need things done on a "window" scale.
We'll see how it goes anyways.

Documentation is coming on a treat too. This stuff is excellently documented, so I have lots to put into the module docs! (If only BlitzMax were so nicely documented ;-)

Still nice to see all the examples running the same across all the platforms - it's the little things ... :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Console Events !!!!!(Posted 2007-06-03)
It's taken me bloody ages to get this working, but take a look here :


Not very exciting, perhaps, on initial inspection. However, you may notice in the top-right corner, the time, whilst in the middle is a text entry field.

What this static image fails to show is that the time is ticking away while the entry field is "active" !!!
This opens up all kinds of interesting possibilities for using the console in BlitzMax. In fact, it's almost like using a "normal" GUI... to an extent.

Normally, what happens is that you activate a particular widget, and the event loop is locked into there until you press enter/escape etc. But this ties you down to a mostly sequential event execution - you need to wait for A before you can do B.

Today I've been re-writing the core "driver" to allow you to "SetFocus()" on a particular widget, which will then accept key presses.
Under the hood it runs off BRL.Event etc, generating events and injecting the widgets with the keys.
It also means that you can add a While WaitEvent() Wend loop, or plug in EventHooks.
The timer example creates a timer to set a label widget with the current time.

Okay, so perhaps it's only me who's excited by this... but it seems pretty cool.

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Curses!!(Posted 2007-05-31)
Now that the module is working again on Win32... here's some more fun :
SuperStrict

Framework BaH.Curses

Local file:String = RequestFile("Select a file")



Not sure how easy the RequestDir() will be, but it's another thing off the list.

:o)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Released(Posted 2007-05-28)
Oh well, there goes another one. I've released the Portmidi module out into the wild.
Dunno what I'm going to do about supporting it, considering it was mostly guesswork getting it running in the first place... heh.. maybe it won't need any ;-)

Had a play today with custom Mouse Pointers / Cursors on Windows and Mac. turned out to be much easier than I thought to implement. (see HERE for details.)
It could do with doing properly, and some research on Linux (ie. GTK). Then we'd have a proper set of code for people to play with. Still.. something is better than nothing.

Back to my console module tomorrow, I hope...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Grounded(Posted 2007-05-27)
Had another go at building a small flight demo using minib3d yesterday, but came apart at the seams when I tried to use Klepto's Terrain stuff.
It appeared to just hang when it tried to load a terrain, but after some debugging I narrowed the problem down to an Normalize Mesh function, which, for each call, sucked up almost half a second on my box. Apparently this code was even optimized by Mr Sibly, but it's still incredibly slow. Surely there must be a better way to do it than to use a TMap.......

Rather than be too dejected, I added the "altitude above ground level" callback stuff that JSBSim uses. Essentially, it asks, for certain location and altitude above sea level, how high am I above the ground.
The only issue I have here is that x/y are reported in longitude/latitude, but I suppose it's easy enough to work around.

Perhaps I'm aiming too high with my "first" 3D example... and I should stick with making a block "fly" around the screen instead... :-p

Looks like I'll be hosting the current incarnation of the Portmidi module then. Thanks Nigel ;-)
Just working on the docs for it at the moment. Nothing too intense.

Hmm.. just had a thought. Might be fun to try a wee demo whereby Max plays a note when you press a key on the (midi) keyboard. (lookout GarageBand.... :-p )

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Just when you think it's safe to...(Posted 2007-05-26)
...upload your latest module, you realise while going through the API docs again that there's a whole bunch of stuff that you still need to do.

Callbacks of all things. There goes another few hours then...
But, it's done now so what's to mumble about, huh? ;-)

I have to say, that ClearSilver is one tidy piece of kit.
I've been messing around running an app as a CGI on the Mac, and the CGI-kit part of ClearSilver makes writing them very easy indeed. But I guess that's what it's there for!

My main interest in ClearSilver is code-generation really, but I'm sure it will be useful for all kinds of projects.


It looks like the PortMidi module is working now too, which is pretty cool. It arrived in my mailbox on the 11th, and after a couple of false starts, Nigel reported on the 25th that it looked to be doing what it is supposed to, without nuking. Not bad for not having a clue about midi ;-)
I also, in the meantime, appear to have acquired ownership of the project... like I don't have anything else to support :-p

But hey... I've learned all about midi and sysex in the process. :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Busy busy...(Posted 2007-05-25)
Been a bit hectic at work lately... I suppose that's what I get for having my pet project turned into the new company roadmap... sigh...

Anyhoo... been messing around with SFMT (random number generator), and decided I may as well build a module out of it too. I've done it in such a way as it can replace the BRL.Random module by simply importing BaH.Random instead.
My tests show it's faster too, on x86. For PPC, I've got it using SIMD (altivec), which speeds it up a bit.

Why do we need another Random module? Well, this one creates the same random number sequences for a given seed on all platforms - of which the official Random module has issues in that respect. (and it's faster ;-)

Still finishing off the ClearSilver module. I've been going through the rest of the CGI-kit methods, so that the module will cover all the nice features, like redirection.

Will endeavour to release both of these over the weekend. Then I should definitely get back into the flight dynamics module.

Oh yeah, and there are new releases of Libxml and Cairo on the website - no syncmods version as yet.

;-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Broken windows(Posted 2007-05-21)
Why is it that Windows takes the most effort to get libraries running on them?

Does everything compile right out of the box, like on Linux/OS X ? Not usually.
Do you have to tinker and tweak things until all the build errors go away? Normally.

I suppose this is what I get for trying to be nice to the Win32 brigade... *pah*...


Anyhoo, the ClearSilver module is now running great on all platforms. Yes, including Win32 :-p

I was messing around last night running an app as a CGI. Not bad... has a lot of built in handling of forms, uploads, etc, which saves a lot of hassles if you want to do CGI in Max.

I think it will be a handy module for things like code generation too. I've used Velocity extensively for that in Java, so it's nice to now have a templating system "built into" BlitzMax :-)

Need to play a bit more with the CGI stuff in ClearSilver, and tidy up the docs a bit more, before I add it to the website. But it's pretty much finished :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

More distractions(Posted 2007-05-19)
I think someone should ban me from the internet... at least until I can get my current projects finished.

Why?

Well, I seem to keep finding new libraries to wrap into modules. (Maybe it's a disease?)

The latest tragedy is something called ClearSilver. It's a cool little templating engine written in C.
It can be used for web-page generation, amongst other things. And it's *fast* !

Anyhoo, a day's work and I've wrapped all of the core stuff. Just need to work through the CGI bit, which in effect can turn your BlitzMax app into a cgi app - handling/processing page requests, and generating pages in response.
Or so the theory goes.

Currently it's running on Linux and Mac.

Was hacking around with Portmidi again yesterday, trying to get the sysex stuff working, but it turns out my cheap midi keyboard doesn't appear to do much in the way of sysex (that I can see), so I've had to code "blind" for now, and hope I was working along the right lines. (time will tell !)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

"System" console support(Posted 2007-05-13)
I thought I should also implement, while I was there, console support for things like Notify, Confirm, Proceed etc...

There are also File / Directory requesters as part of the SystemDriver, which I suppose should be done too.

I've yet to determine what kind of MOUSE support is available in there, which would be nice, if I can get it to work...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

And finally...(Posted 2007-05-13)
...we have the very same code running on Mac OSX 10.4 -



I can happily say... this really rocks :-)

I was considering working it into some kind of MaxGUI-style thang, but that's going to require a heap of extra work, so I guess I'll just throw everything together first, and then decide what I need to refactor.

I have to admit, I do prefer the console - being a Unix junkie - so this is going to be a very nice tool indeed...

<EDIT>
I have to say, that of the three examples, the best looking one is on the Mac. Although if you run the Linux app in an xterm, it looks better (ie. adds underline to the title etc). I guess it depends on the terminal you run it in.

;-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Ah-haaaa!(Posted 2007-05-12)
And here we are running the same BlitzMax source on Linux :



:o)


In other news, due to popular demand I think I may have to release the next Cairo module WITH a modified BRL.Pixmap module, since it is required, and I doubt there is going to be an official update for a while.
A bit messy... but my hands are tied...

My working copy is running on Cairo 1.4.2 but I'm going to update to the latest code-base before release... (1.4.6)
Let's hope the Windows mutex code is a bit better in that one...

Also had a play with portmidi yesterday. Quite interesting. Not really got much of an idea what to do with it, but I'm sure someone will.

Ho hum ;-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Console GUIs(Posted 2007-05-11)
How's about this?

Cross-platform console-based GUIs in BlitzMax...



No that anyone uses console mode these days... still, think it will be nice to have.

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

What the heckles...(Posted 2007-05-08)
I decided I may as well add Save functionality as well, since it's there.

FreeImage supports saving of, BMP, GIF, HDR, ICO, JPEG, PBM, PGM, PNG, PPM, TARGA, TIFF, WBMP and XPM.

I've also added more of the imaging functions too, to round things off.
Fairly well featured for a small library - not as much as ImageMagick, but better than nothing :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Game over!(Posted 2007-05-07)
Well, that wasn't too hard.

BaH.FreeImage is running well on all 3 platforms. Have tested most of the supported image formats, and they all seem to be working fine.

Going to tidy up the docs a bit, and perhaps add some more "advanced" imaging functionality, but as it stands, it's ready for prime-time.
A nice one to add to the other two BaH image loaders, me thinks. In fact, that about does it for image support.

I guess now it's back to playing with the Flight Dynamics module, and see about getting a MiniB3D example working with it.

Fun fun fun :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

FreeImage(Posted 2007-05-07)
Thought I may as well go all out and add more/better imaging support for BlitzMax.

I decided FreeImage seemed a good bet, as it supports the majority of image formats out there (well, the more popular ones, anyway).

With it you get : GIF, BMP, DDS, HDR, ICO, IFF, JNG, JPG, KOALA, LBM, Kodak, MNG, PCS, PBM, PGM, PNG, PPM, Photoshop (PSD), Fax G3, SGI, RAS, TARGA, TIFF, WBMP, XBM and XPM.

All reading... some writing (although I've only enabled reading at the moment).

I know we already have JPG and PNG... and BMP... but it comes with the package.
As yet, I've had trouble getting TIFF to work on Linux/Win32, so I've come to the conclusion either my example .tif is broken, or there's a bug in the library.

I already have it loading through the Stream interface, which allows you to do the standard LoadPixmap() call, and the library will decide if the stream is an image, and how to load it.

FreeImage comes with lots of "tools", but I'm not sure if I need to implement them, or just use FreeImage as a Loader/Saver.

Gifs load in grey-scale at the moment, cuz I need to convert from 8bpp to something palette-less (like 32bpp)... but they load... :-)

I've struggled to get the source to build in minGW on Windows, so I'm going to include the .dll for windows users. - unless someone knows how to get it to compile?
For Linux/Mac, it will compile the source into the module... saving on some installation hassles.

Kind of nice to have, me thinks...

UPDATE
Sorted out my TIFF issues... and along with it some of the others that I had trouble with. Looking good :-)


:o)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Oh Bugger !(Posted 2007-05-04)
Oracle Express 10g tells me it requires a 1gig swap on my Linux box before it will even think about installing...

Guess I'll need to find myself another hard-drive...

Native Oracle driver for BlitzMax will have to wait a little longer...


Now looking at one for Valentina... which is a lightning fast db...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

EXR on Mac(Posted 2007-05-02)
Amazingly, it worked first time on my Powerbook too...

It looks like the basic module (without the frilly parts) is about ready for primetime then.

Just yer basic image loader, and a handful of extra methods.

Thinking I should expose a lot of the rest of the API - like access to mipmaps/ripmaps, and the cube/spherical environment maps...

Yay ;-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Cross-platform CAN be fun!(Posted 2007-05-01)
sometimes, things *just work*...

Unpacked the EXR module onto the Windows box... ran Build Modules... Opened the test app... ran it... up comes the image...

BlitzMax rocks :-)


ps. developed entirely on Linux, btw :-p

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

EXR(Posted 2007-05-01)
After getting an EXR to load into Max, I thought it was time to make things a little easier to use.

Last night I implemented a way to get an EXR to load using Max's LoadPixmap function... using a Stream, even!
It did mean a load of C++, but hey, it's not so hard ;-)

Following the test image examples and what they say an image should appear like, I'm slowly getting everything looking right when you finally view the Pixmap on the screen.
There's a lot of stuff in there... YUV ,Chromaticity, 16bit RGBs, gamma, exposure, defogging etc...

For those who want to tinker (rather than simply load it as pixmap with default settings), I'll be having a method of opening the EXR that lets you play with the settings.

One teeny weeny issue, is that you'll need a modified bmk to build the module... (needs cc flags passed in at build time, etc).

:-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

ffmpeg(Posted 2007-05-01)
Ooooooooooh.... I just got an mp3 playing in BlitzMax on Linux using the ffmpeg library compiled up as a Max module ;-)

I used Skid's example of a TSynth running off a timer to fill the buffer. Which, once I finally understood what numbers to feed it, worked well.

It only took a week to get my head around everything. (only! :-/ )

Couple of issues...

* Max doesn't know when the music ends...
* Had to hack the freeaudio mod - but I'm now thinking I didn't have to at all.

So, what's next?
In theory, I can now play all audio formats that ffmpeg supports.

But next, I fancy getting video working.
There are a few problems concerning that tho... what with having to drive both the audio channels and video display at the same time. I'm not sure Max is up to it without proper threading support.

Oh well... at least the audio-side seems to work ok...

:o)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

1 + 1 = lots!(Posted 2007-04-24)
Still keeping busy, here in the sticks.

Lately, I've been working on a Flight Dynamics module using the open source JSBSim, which is pretty awesome. Talk about detailed. Just to get a jet engine to start up, you have to turn things on in the right order...
I've got a couple of basic tests running that show flight data, but nothing 3D yet, as I'm going to have to learn how to use MiniB3D first.

But, in order to do that, I needed a model of an aircraft...

...and since Blender can import the models used by FlightGear, I thought that might be a good place to get one.
But it turns out Blender can't export to B3D - and all the "free" converters are for Windows only.

So I set about throwing together a basic exporter for Blender.
Which works for me, but not for others... but enough for me to have exported some models.

Of course, these models were using RGB images as textures, which BlitzMax doesn't support.

So I spent an afternoon writing an RGB Loader module, which is now available from the website.


..what's next? ;-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Sorted !(Posted 2007-04-10)
Yet another one bites the dust...

The BaH.DBXbase module is working well on all platforms - after some hacking of the source to get it all building on Win32.

Once this is released (sometime tonight, if the documentation doesn't take me too long), we will have support for dBase (.dbf) format databases (unlike that Cheetah thing, this is cross-platform, and allows you to use SQL - which tends to be more natural to those that use it every day).

Apart from a lack of transaction support, everything else appears to work. It can't handle Long values though, but other than that, it's pretty decent.

The library handles all the nitty-gritty of file creation etc, so you just have to worry about using the correct SQL.



I've also managed to get the mSQL module compiling on Win32, but haven't had a chance to test it - will need to set up an mSQL server running somewhere first.
This one may not work on Win32, given the problems I had getting it to compile... we'll see how it goes.

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Xbase and xbSQL(Posted 2007-04-09)
Xbase is a library that supports the .dbf file format (like dBase and FoxPro).
xbSQL is a library that adds SQL functionality to Xbase.

Currently attempting to build these into a module...
...in which getting to a point where the two libraries would compile without errors/warnings was a bit of a task in itself.

Still, will be a nice wee addition if I can get it working.
xbSQL even support prepare/execute style statements, which was a bit of a surprise.

Fingers crossed...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Another one bites the dust...(Posted 2007-04-06)
After much key bashing, I've finished the 5th (FIFTH !!) driver module for the Database Framework - mSQL. (not bad for a days work)

Apparently it used to be very popular before MySQL grabbed hold of the reigns. It doesn't support transactions or prepared statements, but it's certainly easy to wrap and code with.

I downloaded an Informix trial and the SDK this morning too, so I guess I can have a look at implementing that next.
At least with the ODBC module, we have support for all those databases anyways - I just think direct driver support is a "nice-to-have", with these things.
That, and it exposes me to a lot more... which is always a bonus :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Database modules(Posted 2007-04-06)
Been looking at other databases that might be nice to have modules available for.
Currently on my investigation list :

DB2
Informix
mSQL (miniSQL)
Oracle

Both IBM (DB2 Express) and Oracle (10g Express) have "free" versions of their databases, which can be distributed and such-like for free.
Not that they are in anyway "small" distributions. They are both around 250 meg.
Informix (still IBM) have an "express" edition, but it is only available on trial - and I imagine it's expensive. Although, imho, Informix is better than Oracle and DB2 as a database server.

I noticed that someone has wrapped a "cheetah" database thing, but since it doesn't appear to use SQL, I'm not really interested in it.
If anyone finds any other databases they think might be suitable for inclusion into the framework... my email is in my profile :-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Usage(Posted 2007-04-02)
I actually used a couple of my modules over the course of the weekend... (shock... horror!)

It's all very well hacking together useful tools, but it's better when one can come up with some way to use them - something I'm never particularly good at.

But hey, I was pottering around, and thought I should finally sit down and start a project I've been meaning to get into for ages.

Essentially, I have a book - published in 1897 - which contains plan-views of routes/journeys between towns and cities all over Scotland. Basically, you can see how steep the road is along the course of the route.
The book was written primarily for cyclists - there not being much in the way of cars back then (or roads, for that matter).
Each route comes with a diagram, a short description, notes on milestones, gradients, places of interest, and measurements (a chart between points on the route).

I've been wanting to build a database out of it - just cuz I can - and somehow get the contour info in there too.

Over the weekend, I designed and implemented the database (in MySQL), and have a GUI app that allows the creation/updating of routes (less the measurements chart and the visual contours bit).
Not bad for a day and a half.

On the way, I found some issues with the Database module, MySQL module and GTK module, which I've sorted out - and need to get online at some point.
Problems with the database concerned the re-use of prepared statements - well, if you can't re-use it, what's the point?

The graphics part I've still to think about.
I guess, the nicest way will be to scan one in, and use that as a background onto which I plot all the points, intersections, towns/Inns etc... and store all that info in the database.

In the end, I think it would be cool to have it all available via a website... want to get from A to B? Want to see what the route looked like in 1897?
(obviously, for a lot of roads, the route will still be the same. only main routes where they've cut through a hill instead of going around it, will be significantly different).
May even be worth tying it in to my family tree website...

;-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Onwards and upwards!(Posted 2007-03-28)
That's the cairo module working well on 1.4.2. (can't release until BRL.Pixmap is updated though - or, I hack in some kind of work-around for the time being (which I'm loathed to do really).
Nice to have MacOS support back in there again - my fault for the mess of the current release.


Decided to update the Libxml/Libsxlt modules to the latest versions. Currently have Libxml working. Also fixed some bugs I found while going through the code (of where there is a lot of code - especially when you need to check each function!!)
That's looking good so far. The new versions fix some bugs and have optimizations here and there - which is always a bonus for any library.

The current count is 19 modules available on the website ! Nineteen!!

Am wondering what might be nice to round it up to 20... I suppose Qt when it's finished...
And I should probably consider stopping at some point too - 20 different modules is a bit of a handful to support for free....

;-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

No rest for the wicked(Posted 2007-03-23)
Just noticed that Cairo is now up to 1.4.2

So I guess I should update everything to that before release... (hoping I can have the Pixmap changes officialized too, before then).

Had some issues getting the win32 code working. Spent ages on it, and then suddenly, after adding all kinds of debug.. it just started working :-/
(Me thinks I would have been wise removing the .bmx folder and having it compile from scratch again...)

Almost there...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Cairo Update(Posted 2007-03-22)
Had a bash getting the Cairo module up to 1.4.0.

While I was at it, I've re-written the Pixmap handling code so that I don't need to hack Cairo's source to make things work on PPC (Mac).
It is running well on both Mac and Linux at the moment.

However, I really need a new Pixel Format (ARGB) type adding to BRL.Pixmap for the PPC code because of big endian, otherwise I'll be needing to write a whole heap of hacky Pixmap-converting code outside of that module - which wouldn't be ideal. We'll see how that goes.

1.4 is almost here.

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Firebird, IBPP and stuff(Posted 2007-03-19)
Well, I spent a good part of the weekend trying to get IBPP working with my Firebird Database.

Alas, it looks like its tanking somewhere in the Firebird client library when I try to execute a query.
Me thinks I'll leave it alone for a while...


On a brighter note, I mentioned the new RegEx module in the forums, so I guess it's official now. Has been working well in my tests, so I think it's solid enough for prime time :-)

I think I'm gonna work on the new Cairo for a while. 1.4 is meant to be a good bit faster than 1.2...

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Done and mostly dusted(Posted 2007-03-14)
Released the database stuff yesterday. No major issues to report at the moment.
Just need to test PostgreSQL some more - working 100% on Linux.
Also looking at Firebird.. but seems bmk is an issue there...

RegEx is done. No officially official release yet. A couple of things to tidy up, perhaps.

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Searching(Posted 2007-03-07)
Now.. this is nice :-)

SuperStrict

Framework BaH.RegEx
Import BRL.StandardIO


Local regex:TRegEx = TRegEx.Create("[-+]?[0-9]*\.?[0-9]+")

Try

	Local match:TRegExMatch = regex.Search("floats are 4.533, -10.232, 1446.2003 and even 100")
		
	
	While match
	
		Print "Found : " + match.SubExp(0)
		
		match = regex.Search()
	Wend

Catch e:TRegExException

	Print "Error : " + e.toString()
	End
	
End Try

Print "Done."


outputs:
Found : 4.533
Found : -10.232
Found : 1446.2003
Found : 100
Done.


;-)

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax

Trying to keep track(Posted 2007-03-06)
I should have realised, when I'd made my first module, that it was probably a good time to stop.

This worklog is just to keep track of the current work-in-progress of various modules that are being worked on.

All modules are cross-platform - otherwise, what's the point?

* Database Framework *

Status: 100%

Summary : Yet another database module framework. But this one includes prepared statements, documentation and such like.

There is a core database module, and a set of separate driver modules. Pick the driver you need, and use it.

The core stuff is done, and I think I'm happy with the way it hangs together.

Driver status :
* SQLite - Finished
* ODBC - Finished
* MySQL - Finished
* PostgreSQL - Finished - just more cross-platform testing to do.
* Firebird - 0% (thinking about it)



* Regex Module *

Status: 100%

Summary : finished !



* Qt *

Status: 96%

Summary : Most of the work is done. Still a couple of missing features, but essentially it works - In my own GUI app, all the features of that work fully. (I guess it depends what part of MaxGUI features you need).

This was the most interesting module for me to date. Considering how long it took to get the GTK module to the same point, I think 3 weeks wasn't too bad at all ;-)
That and I got to learn C++ at the same time !!

-+ Brucey +-

Come to Brucey's Modules for useful BlitzMax Modules!! . . . See my Modules Worklog - wxMax -

* The Definitive Module List * Qt-On-BlitzMax