Last edited by james; 11-07-2014 at 10:08.
Creator of LaserBoy!
LaserBoy is free and runs in Windows, MacOS and Linux (including Raspberry Pi!).
Download LaserBoy!
YouTube Tutorials
Ask me about my LaserBoy Correction Amp Kit for sale!
All software has a learning curve usually proportional to its capabilities and unique features. Pointing with a mouse is in no way easier than tapping a key.
.... random blabbering ....
I just discovered another reason I love UNIX.
There is a set of ASCII character that are legitimate to use in standard UNIX file names.
0 - 9 (digit glyphs : 10)
a - z (lower case glyphs : 26)
A - Z (upper case glyphs : 26)
-_. (dash, underscore and dot : 3)
Because the space character crept into the scene with Win95 file naming extensions and cross-platform file system translation, Linux knows how to "deal with" a space in a file name, but it BUSTS the idea of a "token" as a file name.
Count it up!
There are EXACTLY 65 unique glyphs!
So what?
That's 64 plus the dot.
64 is 2 to the 6th; exactly what you can count with 6 bits.
So a file name can be a perfect hash; a bijective function.
Each glyph is a 6 bit number, leaving the dot as the name dot extension separator.
So a file name of 8 characters could be a hash of a 48 bit number and that hash could be translated back to exactly one 48 bit value.
That's plenty of room for a UNIX time value!
That's a count of every second (except for added leap seconds) since midnight, January 1, 1970; the beginning of The Epoch!
Somehow I don't think this was pure coincidence.
James.
Creator of LaserBoy!
LaserBoy is free and runs in Windows, MacOS and Linux (including Raspberry Pi!).
Download LaserBoy!
YouTube Tutorials
Ask me about my LaserBoy Correction Amp Kit for sale!
All software has a learning curve usually proportional to its capabilities and unique features. Pointing with a mouse is in no way easier than tapping a key.
suppose you're thinkin' about a plate o' shrimp. Suddenly someone'll say, like, plate, or shrimp, or plate o' shrimp out of the blue, no explanation. No point in lookin' for one, either. It's all part of a cosmic unconciousness.
Uh... not exactly... But, OK. But UNIX is UNIX.
Do you get why it's a nice coincidence?
Last edited by james; 11-07-2014 at 17:47.
Creator of LaserBoy!
LaserBoy is free and runs in Windows, MacOS and Linux (including Raspberry Pi!).
Download LaserBoy!
YouTube Tutorials
Ask me about my LaserBoy Correction Amp Kit for sale!
All software has a learning curve usually proportional to its capabilities and unique features. Pointing with a mouse is in no way easier than tapping a key.
It's no big deal to anyone else. I just discovered a way to do something that has been bothering me for a while.
Part of the ILDA file format spec is that each section has an 8 character space in the section header for the name of the data that follows it.
Usually that's a frame, but section 2 is a palette.
There are a few ways to make new palettes in LaserBoy. You can directly create one, import one from an ILDA or text file, get one by reducing or matching either one or many frames to a palette, etc...
In all version of LB, up to and including the current one that's out there now, there are two kinds of "new" palettes. One is just a palette, probably for a single frame and another is a super palette for several consecutive frames; perhaps the whole frame set.
My current naming convention is P0000000, P0000001, P0000002, etc... for regular palettes and SP000000, SP000001, SP000002, etc... for super palettes. The palette and super palette counters always start at 0 each time you start the application.
This is fine for storing palettes with names within an ILDA file because of the way it works and the fact that the file is read in consecutive order and palettes are only in play for as long as another palette is not yet defined in the same file. The name doesn't really do anything.
But, in the LaserBoy plain ASCII text laser vector art format, palette names are important!
Each frame of vectors can have the vector colors defined within it as either separate decimal RGB values or a single hexidecimal value OR the colors can be defined as indexes into a named palette. The palette can be one of the built-in, named LaserBoy palettes or a custom palette defined previously in the text file.
It doesn't matter what order the palettes are defined within the file. They just need to be defined before the frame or frames that use the named palette. When LaserBoy sees a palette definition, it looks for a name. If there is no name, it makes one and loads the palette into the LaserBoy palette set (in the memory of the running app). Any frame that follows that uses the palette of that name has its palette index set to the named palette in the palette set.
With the naming convention that I have described above, it is obvious that many different palettes could be created with the same names; P0000000, etc... That's a real problem for reading the text file format.
But, if I make a call to UNIX time() I get an integer that is the number of seconds (excluding leap seconds) from midnight, January 1st, 1970 to now (the epoch). I can hash that integer into visible ASCII characters that can be used to name a palette and I can be pretty sure it will be globally unique at least for the rest of my life here on Earth.
It works for the ILDA file format spec and my text file spec. It also happens to be made of characters that are valid for a UNIX file name!
Whooooop Teeeee Dooooooo!
Strange things get me excited.
I still have a lot of work to do!
James.
Last edited by james; 11-08-2014 at 10:41.
Creator of LaserBoy!
LaserBoy is free and runs in Windows, MacOS and Linux (including Raspberry Pi!).
Download LaserBoy!
YouTube Tutorials
Ask me about my LaserBoy Correction Amp Kit for sale!
All software has a learning curve usually proportional to its capabilities and unique features. Pointing with a mouse is in no way easier than tapping a key.
I spent an hour looking for this old project, checking 9 drives, mostly because I thought I had written it in Java.
But I hadn't.
I wrote it in C++. It's part of a unit I called "ildadump.cpp" and I e-mailed you the source on Jan. 10, 2013. If you don't still have it I can forward it to you again.
Boy, I thought I had lost it! Well, it was almost two years ago. Cut my memory some slack.
Best,
Mike
No worries. I'm glad you found it!
I know how time can slip away. It's been over a year since I release LaserBoy.
I am working on it though!
Soon.
It would probably be a lot easier if you sent it to me again.
James.
Creator of LaserBoy!
LaserBoy is free and runs in Windows, MacOS and Linux (including Raspberry Pi!).
Download LaserBoy!
YouTube Tutorials
Ask me about my LaserBoy Correction Amp Kit for sale!
All software has a learning curve usually proportional to its capabilities and unique features. Pointing with a mouse is in no way easier than tapping a key.
So I have yet another question. i have an animation that I would like to run with two colours at the same time. The top part red and the bottom part blue. I could divide the animation into two parts, and run up a set of dxf for both. But is it possible to place two sets of dxf's on top of each other? After I've changed the colour of both in laserboy?
Is there anyway to colour an animation like this without having to go through each frame?
Thanks again