Hi all,
is it possible to make 'slices' - rectangular named rectangles for export to png? I'ts known from Xara and Photoshop for creating web images. Does exists such plugin? it would be very helpful. (in addition: keeping an index pallete for the whole image would be great)
Michal
Hi Michal,
On Mon, 13 Mar 2006 21:30:08 +0100, Michal Žeravík <michalz@...28...> wrote:
Hi all,
is it possible to make 'slices' - rectangular named rectangles for export to png? I'ts known from Xara and Photoshop for creating web images. Does exists such plugin?
I am not sure if this can help you but there is a svg slicing tool made by digitalunleashed.com and called by "SVGSlice" [1]. Perhaps it can do at least part of things you need. I've not tested it yet but from a quick view on the file [2] it is python script with Inkscape's extension included. See the webpage [1] for details about slicing the image in Inkscape.
cheers cornelius
[1] http://www.digitalunleashed.com/giving.php [2] http://www.digitalunleashed.com/downloads/svgslice/svgslice_0.12.tar.bz2
Josef Vybiral wrote:
Hi Michal,
On Mon, 13 Mar 2006 21:30:08 +0100, Michal Žeravík <michalz@...28...> wrote:
Hi all,
is it possible to make 'slices' - rectangular named rectangles for export to png? I'ts known from Xara and Photoshop for creating web images. Does exists such plugin?
I am not sure if this can help you but there is a svg slicing tool made by digitalunleashed.com and called by "SVGSlice" [1]. Perhaps it can do at least part of things you need. I've not tested it yet but from a quick view on the file [2] it is python script with Inkscape's extension included. See the webpage [1] for details about slicing the image in Inkscape.
aw, looks good, but how can I install that extension (.inx) to inkscape?
Michal
On Tue, 14 Mar 2006 04:05:41 +0100, Michal Žeravík <michalz@...28...> wrote:
Josef Vybiral wrote:
Hi Michal,
On Mon, 13 Mar 2006 21:30:08 +0100, Michal Žeravík <michalz@...28...> wrote:
Hi all,
is it possible to make 'slices' - rectangular named rectangles for export to png? I'ts known from Xara and Photoshop for creating web images. Does exists such plugin?
I am not sure if this can help you but there is a svg slicing tool made by digitalunleashed.com and called by "SVGSlice" [1]. Perhaps it can do at least part of things you need. I've not tested it yet but from a quick view on the file [2] it is python script with Inkscape's extension included. See the webpage [1] for details about slicing the image in Inkscape.
aw, looks good, but how can I install that extension (.inx) to inkscape?
To install it as an extension into Inkscape you have to copy the .inx file into the /usr/share/inkscape/extensions directory (or c:\program files\inkscape\share\extensions ) and then restart Inkscape. If you have the pyslice script copied into the /bin directory and set to be executable then it should be enought ot get it working. According to the .inx file the new option should appear in the list of available formats in the Save dialogue. Unfortunatelly I had no luck with this on my Windows machine, where other extensions work, so I can not tell you any practical information or experiences.
cheers cornelius
Josef Vybiral wrote:
On Tue, 14 Mar 2006 04:05:41 +0100, Michal Žeravík <michalz@...28...> wrote:
Josef Vybiral wrote:
Hi Michal,
On Mon, 13 Mar 2006 21:30:08 +0100, Michal Žeravík <michalz@...28...> wrote:
Hi all,
is it possible to make 'slices' - rectangular named rectangles for export to png? I'ts known from Xara and Photoshop for creating web images. Does exists such plugin?
I am not sure if this can help you but there is a svg slicing tool made by digitalunleashed.com and called by "SVGSlice" [1]. Perhaps it can do at least part of things you need. I've not tested it yet but from a quick view on the file [2] it is python script with Inkscape's extension included. See the webpage [1] for details about slicing the image in Inkscape.
aw, looks good, but how can I install that extension (.inx) to inkscape?
To install it as an extension into Inkscape you have to copy the .inx file into the /usr/share/inkscape/extensions directory (or c:\program files\inkscape\share\extensions ) and then restart Inkscape. If you have the pyslice script copied into the /bin directory and set to be executable then it should be enought ot get it working. According to the .inx file the new option should appear in the list of available formats in the Save dialogue. Unfortunatelly I had no luck with this on my Windows machine, where other extensions work, so I can not tell you any practical information or experiences.
cheers cornelius
hey, I did exactly what you've written but I can't see any additional options in inkscape... i'm using 0.42 on Ubuntu linux; i can run svgslice script though, but I can't find any examples of how to use it... all i can find is the help screen:
./svgslice --help usage: svgslice [options]
options: -h, --help show this help message and exit -d, --debug Enable extra debugging info. -b BACKGROUNDCOLOR, --backgroundcolor=BACKGROUNDCOLOR Background color to use when rendering transparent bitmaps (any valid inkscape color; defaults to "white"). -p SLICEPREFIX, --sliceprefix=SLICEPREFIX Filename prefix to use for generated slices. -l, --layerengine Use layer-and-rectangle based slicing engine. -w WEBPAGE, --webpage=WEBPAGE Generate webpage code to display the slices. (Currently only available for Guide-based slicing). -t, --test Test mode: leave temporary files for examination.
but no examples. Can anyone help?
regards, #9
Jacek Brzeski wrote:
Josef Vybiral wrote:
On Tue, 14 Mar 2006 04:05:41 +0100, Michal Žeravík <michalz@...28...> wrote:
Josef Vybiral wrote:
Hi Michal,
On Mon, 13 Mar 2006 21:30:08 +0100, Michal Žeravík <michalz@...28...> wrote:
Hi all,
is it possible to make 'slices' - rectangular named rectangles for export to png? I'ts known from Xara and Photoshop for creating web images. Does exists such plugin?
I am not sure if this can help you but there is a svg slicing tool made by digitalunleashed.com and called by "SVGSlice" [1]. Perhaps it can do at least part of things you need. I've not tested it yet but from a quick view on the file [2] it is python script with Inkscape's extension included. See the webpage [1] for details about slicing the image in Inkscape.
aw, looks good, but how can I install that extension (.inx) to inkscape?
To install it as an extension into Inkscape you have to copy the .inx file into the /usr/share/inkscape/extensions directory (or c:\program files\inkscape\share\extensions ) and then restart Inkscape. If you have the pyslice script copied into the /bin directory and set to be executable then it should be enought ot get it working. According to the .inx file the new option should appear in the list of available formats in the Save dialogue. Unfortunatelly I had no luck with this on my Windows machine, where other extensions work, so I can not tell you any practical information or experiences.
cheers cornelius
hey, I did exactly what you've written but I can't see any additional options in inkscape... i'm using 0.42 on Ubuntu linux; i can run svgslice script though, but I can't find any examples of how to use it... all i can find is the help screen:
./svgslice --help usage: svgslice [options]
options: -h, --help show this help message and exit -d, --debug Enable extra debugging info. -b BACKGROUNDCOLOR, --backgroundcolor=BACKGROUNDCOLOR Background color to use when rendering transparent bitmaps (any valid inkscape color; defaults to "white"). -p SLICEPREFIX, --sliceprefix=SLICEPREFIX Filename prefix to use for generated slices. -l, --layerengine Use layer-and-rectangle based slicing engine. -w WEBPAGE, --webpage=WEBPAGE Generate webpage code to display the slices. (Currently only available for Guide-based slicing). -t, --test Test mode: leave temporary files for examination.
but no examples. Can anyone help?
regards, #9
yeah, the same on gentoo64 with inkscape-0.43: -rw-r--r-- 1 michal users 691 Mar 15 23:03 /usr/share/inkscape/extensions/svgslice_output.inx -rwxr-xr-x 1 root root 20229 Mar 14 03:44 /usr/local/bin/svgslice
and no such options in Save As dialog. By the way, is it possible to choose image format and pallete when exporting to slices? And is it slicing only with guides?
michal
Hi, Although getting an SVG slice program to run from Inkscape is an interesting project in itself (I'm starting work on a plugin myself, so I'm quite interested in prior examples), I didn't see anybody mention the "really dumb and obvious" way to do this in Inkscape, so I thought maybe I should post ...
Create a series of background rectangles behind your drawing, representing the "slices" you want -- you'll note there's no need for them to conform to an even grid, unless that's what you want, but doing so is trivial with grid, duplicate, and/or snap-to-object settings.
Set each of those objects to white fill with no border.
Then select each and export "selection" to PNG files.
The bounding box of the rectangle will define the limits of the resulting PNG files, and you will see a series of "slices" of your drawing, which is, I think, what you wanted.
I can appreciate that this might not be quite as automated as you were hoping for, although it may be more customizable (I haven't tried SVGSlice, so I can't say for sure).
I also have to point out that there are a zillion ways to do this (starting with ImageMagick's "crop") on the bitmap output. And given that this kind of application is strictly tied to the limitations of the bitmap output (e.g. you are dimensioning in "pixels"), why would you want to mess with doing it in the original drawing?
Cheers, Terry
Terry Hancock wrote:
Hi, Although getting an SVG slice program to run from Inkscape is an interesting project in itself (I'm starting work on a plugin myself, so I'm quite interested in prior examples), I didn't see anybody mention the "really dumb and obvious" way to do this in Inkscape, so I thought maybe I should post ...
Create a series of background rectangles behind your drawing, representing the "slices" you want -- you'll note there's no need for them to conform to an even grid, unless that's what you want, but doing so is trivial with grid, duplicate, and/or snap-to-object settings.
Set each of those objects to white fill with no border.
Then select each and export "selection" to PNG files.
The bounding box of the rectangle will define the limits of the resulting PNG files, and you will see a series of "slices" of your drawing, which is, I think, what you wanted.
I can appreciate that this might not be quite as automated as you were hoping for, although it may be more customizable (I haven't tried SVGSlice, so I can't say for sure).
I also have to point out that there are a zillion ways to do this (starting with ImageMagick's "crop") on the bitmap output. And given that this kind of application is strictly tied to the limitations of the bitmap output (e.g. you are dimensioning in "pixels"), why would you want to mess with doing it in the original drawing?
Cheers, Terry
Hey, thanks for your point of view. Right now i'm slicing output images in imageMagick (crop functions) or in Gimp, but I asked about the script to make it more automatic... I was using your method previously (to be exact: i created a box covering the slice / field i want to export, selected that box, then go to export dialog, switched to "export selection", then switch to "custom export" which remembers the export settings (X and Y, width and height). Then, without closing export dialog, i went back to the image, deleted the box - got back to export dialog (with custom still switched on) and hit "GO".
But this method isn't working well with edges (sometimes Inkscape gives transparent egdes of that slice) and isn't helping with webgraphics - where you got one banner and want to slice it into 5 pieces, easy and quickly... and that's why i'm very interested in this slicing plugin :)
regards, #9
Terry Hancock wrote:
Hi, Although getting an SVG slice program to run from Inkscape is an interesting project in itself (I'm starting work on a plugin myself, so I'm quite interested in prior examples), I didn't see anybody mention the "really dumb and obvious" way to do this in Inkscape, so I thought maybe I should post ...
Create a series of background rectangles behind your drawing, representing the "slices" you want -- you'll note there's no need for them to conform to an even grid, unless that's what you want, but doing so is trivial with grid, duplicate, and/or snap-to-object settings.
Set each of those objects to white fill with no border.
Then select each and export "selection" to PNG files.
The bounding box of the rectangle will define the limits of the resulting PNG files, and you will see a series of "slices" of your drawing, which is, I think, what you wanted.
I can appreciate that this might not be quite as automated as you were hoping for, although it may be more customizable (I haven't tried SVGSlice, so I can't say for sure).
I also have to point out that there are a zillion ways to do this (starting with ImageMagick's "crop") on the bitmap output. And given that this kind of application is strictly tied to the limitations of the bitmap output (e.g. you are dimensioning in "pixels"), why would you want to mess with doing it in the original drawing?
Cheers, Terry
Hey man, that's great idea to cut image parts with rectangles in special layer. Moreover, it would be nice to define image format/pallete for each block. This way is much more flexible than guillotine around guides.
michal
participants (4)
-
Jacek Brzeski
-
Josef Vybiral
-
Michal Žeravík
-
Terry Hancock