fti / ftr files

Open discussion on or around SGI; software/hardware related posts should go in the appropriate subforum.
Forum rules
Any posts concerning pirated software or offering to buy/sell/trade commercial software are subject to removal.
User avatar
nicolas
Posts: 146
Joined: Thu Apr 10, 2003 5:33 pm
Location: Sherbrooke, Quebec, Canada

Unread postby nicolas » Sat Apr 26, 2003 10:29 am

This is one of the little things that make SGI "Special". :wink:

User avatar
lisp
Posts: 274
Joined: Wed Feb 05, 2003 5:23 am
Location: England
Contact:

Unread postby lisp » Sun Apr 27, 2003 11:11 am

I see two options.

Either use something like AutoTrace to convert the bitmaps into vectors. However, you'd neeed to write a converter from one of it's output types to fti.

OR

Write a program that creates a vector image consisting of a matrix of squares (or maybe skewed quadrilaterals, so the icons are angled correctly) base on the bitmap image.
--
lisa

User avatar
lisp
Posts: 274
Joined: Wed Feb 05, 2003 5:23 am
Location: England
Contact:

Unread postby lisp » Sun Apr 27, 2003 1:40 pm

icongen.c will be appearing soon on my webspace at : http://www.thecommune.org.uk/~lisa/icongen.c

It's nasty at the moment:

Load your image up in the gimp, and save it as c source. Tell it not to use Glib types, and leave *all* other options at their defaults.

Take this file, and replace the structure at the start of icongen.c with its contents, compile, run, and pipe the output to a file. This file will contain an icon, which is an isometric projection of your bitmap.

There is primitive colourspace conversion but it's not great.

I might make this an easier tool to use, but not for a few weeks, but I'm more inclined to try the other approach I mentioned in preference.
--

lisa

vegac
Posts: 745
Joined: Thu Jan 23, 2003 11:34 am
Contact:

Unread postby vegac » Sun Apr 27, 2003 3:39 pm

hmm, this could actually turn out to be useful...

maybe I'll borrow the source (if you wouldn't mind) and make it a "full" bmp->fti converter (just because, well, I have bmp reading code around here somewhere)...

or maybe I'll just be lazy and not :)

User avatar
lisp
Posts: 274
Joined: Wed Feb 05, 2003 5:23 am
Location: England
Contact:

Unread postby lisp » Sun Apr 27, 2003 4:30 pm

vegac wrote:maybe I'll borrow the source (if you wouldn't mind) and make it a "full" bmp->fti converter (just because, well, I have bmp reading code around here somewhere)...


Be my guest. Acknowledgement would be nice. BTW, if used in such a way, it would be released under the BSD license.
--

lisa

User avatar
Chinstrap
Posts: 11
Joined: Sun Apr 20, 2003 6:42 pm
Contact:

icongen.c experiences

Unread postby Chinstrap » Sun May 25, 2003 12:49 pm

I was curious if my fti2svg.pl script would successfully create svg files from the fti files your program creates. It turned up a small bug in my script (a hard coded check for a space), but after I fixed that it converts them perfectly. Admittedly they aren't the most efficent files at that point, but it does work. Also, your solution kind of defeats one of the purposes of fti icons...they aren't scalable, since you are effectively making a path of each pixel, so scaling it up just gives you bigger pixels, just like a raster image. Not that I can complain, I have no better solution. It did give me a neat idea for a related project though. Using your solution (though not your code), I could easily write a web based [png|bmp|gif|jpeg]2[fti|svg] converter using gd. That way, any time you find a neat icon image on the web, you just enter it's url into a form and it spits out an fti/svg for you. If I actually get around to writing it (not this week, busy moving to NJ), I'll be sure to credit you on it.


Return to “SGI: Discussion”

Who is online

Users browsing this forum: No registered users and 1 guest