Inkscape users, I have an Inkscape file that is about 4.5 megabytes in size. It is essentially an A4 size comic book page. One layer contains the orginal scanned pencils, which were in PNG format. The next layer are flat colours, no gradients, just simple paths with colour fills. The top layer is the inks, which were almost all created with the calligraphy pen. This seems to be where the problem is. Even just locking/unlocking the layer causes Inkscape to pause for many seconds, maybe 10 or so. My computer is by no means the latest, but it should handle these file sizes alright. I use GIMP and Photoshop on larger file sizes without any noticeable slowdown. (My computer is a 2.8GHz dual processor, with 2 GB RAM, running Ubuntu 9.04). Is it normal for a collection of paths created with the calligraphy pen to be this bulky and slow a system down? I tried removing the original scan images to try and reduce the file size, but it has not helped. Is there something I'm doing inefficiently or wrong, or is it just that complicated paths can't help but soak up lots of memory. Any advice would be much appreciated. -- Dave M G
on 27.06.2009 13:26
on 27.06.2009 13:33
On Saturday, 27 June 2009 13:07:48 Dave M G wrote: > Is there something I'm doing inefficiently or wrong, or is it just that > complicated paths can't help but soak up lots of memory. I have long moaned that "Nodes mean slow" :( I have a fast machine and 2gigs of RAM. It makes no difference. I think it's all the looping through those long lists of nodes.... You are doomed. Unless you can simplify or chop-up your comic page into frames and assemble them later in Gimp. \d -- home: http://otherwise.relics.co.za/ 2D vector animation : https://savannah.nongnu.org/projects/things/ Font manager : https://savannah.nongnu.org/projects/fontypython/
on 28.06.2009 19:18
Donn, Thank you for responding. > I have long moaned that "Nodes mean slow" :( I have a fast machine and 2gigs > of RAM. It makes no difference. I think it's all the looping through those long > lists of nodes.... > > You are doomed. Unless you can simplify or chop-up your comic page into frames > and assemble them later in Gimp. Okay. While it's a little disappointing that there isn't a way to optimize the file for better performance, it's good to know that at least I'm not doing something wrong. I'll export the paths into a PNG and handle the colouring in Photoshop or GIMP. It means committing to rasterizing the images sooner in my process than I had hoped, but hey, life is full of compromises. -- Dave M G
on 30.06.2009 12:19
And please be sure to file a bug/feature request at http://bugs.launchpad.net/inkscape/ In the end there will obviously always be cases where Inkscape is too slow, but Inkscape could most definitely be faster in some cases. And just locking/unlocking the layer should (from an intuitive standpoint) NOT cause such a big pause.
on 01.07.2009 10:19
Hey, I'd like to write a Python script in Inkscape, but I cannot find something like a straightforward "API" or something. I have seriously Googled quite a bit on it, but everything looks horribly complicated. Is there a straightforward way for creating a line from A to B, for example? Or does everything I want to do in Python require some complicated XML handling? Thanks, Maarten On 6/30/09 12:16 PM, "Jasper van de Gronde" <th.v.d.gronde@hccnet.nl> wrote: >> >> > ------------------------------------------------------------------------------ > _______________________________________________ > Inkscape-user mailing list > Inkscape-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/inkscape-user ________________________________________________________________ Maarten van der Velde graphic designer Powel ASA Klæbuveien 194, NO-7037 Trondheim, NORWAY Phone: +47 73 80 45 00 - Fax: +47 73 80 45 01 Direct line: +47 73 80 46 21 - Mobile: +47 48 16 46 21 / +31 (0) 6 30 80 95 91 Email: Maarten.van-der-Velde@powel.no http://www.powel.com/ ********************************************************************** This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify the system manager. This footnote also confirms that this email message has been swept by MIMEsweeper for the presence of computer viruses. www.powel.no **********************************************************************
on 01.07.2009 17:16
All interaction with the svg involves the XML representation. In you example, to create a new line you would add a bezzier curve objext into the DOM. (I think that is the right term). Fortunately, the xml handling code is available in python. Check out existind scripts for examples. -Rob A> On 7/1/09, Maarten van der Velde <Maarten.van-der-Velde@powel.no> wrote: > Maarten >> NOT cause such a big pause. >>>> long >>> I'll export the paths into a PNG and handle the colouring in Photoshop > > Email: Maarten.van-der-Velde@powel.no > This footnote also confirms that this email message has been swept by > https://lists.sourceforge.net/lists/listinfo/inkscape-user > -- Sent from my mobile device
on 01.07.2009 17:35
Maarten van der Velde wrote: > I'd like to write a Python script in Inkscape, but I cannot find something > like a straightforward "API" or something. I have seriously Googled quite a > bit on it, but everything looks horribly complicated. Is there a > straightforward way for creating a line from A to B, for example? Or does > everything I want to do in Python require some complicated XML handling? A number of people have proposed building a drawing API on top of the current xml handling base, but no one has followed through. You might be able to save some effort if you merge with svg-utils: http://www.programmer-art.org/projects/svg-utils I'm still wishing for a model by which we have access to the living inkscape internals and access to draw with all of those tools in python. Aaron Spike
on 02.07.2009 10:41
Hey everybdoy, Thanks for your replies. So, basically, if I'd want to get information from the underlaying drawing (like the coordinates of a node), I'd have to do XML operations? Like finding an attribute and it's value, etc? > http://www.programmer-art.org/projects/svg-utils I'll have a look! > > I'm still wishing for a model by which we have access to the living > inkscape internals and access to draw with all of those tools in python. Yes, that was what I was hoping for. A bit like in Blender, maybe. Programmig in Python there is surprisingly straight-forward, compared to its´ user-interface :) I guess people would create a lot more "effects" if there was a simple and straightforward way of saying things like: x=selection.drawingNode[3].x or myBezier.addDrawingNode(myNewNode) Kind regards, Maarten ********************************************************************** This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify the system manager. This footnote also confirms that this email message has been swept by MIMEsweeper for the presence of computer viruses. www.powel.no **********************************************************************
on 02.07.2009 13:43
Maarten van der Velde wrote: > or > > myBezier.addDrawingNode(myNewNode) Keep going! It would be very helpful to your cause if you could start a page on the Wiki to design the API you seek. Implementation is probably pretty easy here, I think it is the API design part that is holding people back. Aaron Spike
on 02.07.2009 17:21
On Thu, 02 Jul 2009 10:39:45 +0200 Maarten van der Velde <Maarten.van-der-Velde@powel.no> wrote: > So, basically, if I'd want to get information from the underlaying > drawing (like the coordinates of a node), I'd have to do XML > operations? Like finding an attribute and it's value, etc? For a node, yes. Some python extensions actually call another instance of inkscape on the current file, using the --query-all flag which makes inkscape dump id,x,y,w,h (i.e. bounding box) for all objects, something you can't really do just parsing the XML, on account of possible layered transformations. Cheers -Terry
on 04.07.2009 11:13
Hi, Use PIL (Python Image Library) or for Lines/Graphs http://code.google.com/p/svgfig/ http://www.google.fr/search?q=drawing+with+python&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-US:official&client=firefox-a Norman On Wed, Jul 1, 2009 at 9:56 AM, Maarten van der
on 04.07.2009 15:22
Hi, Thanks for the links. That looks very good... Something like that, indeed, but then straight from Inkscape. Maarten -----Oorspronkelijk bericht----- Van: Norman Khine [mailto:norman@khine.net] Verzonden: wo 1-7-2009 10:39 Aan: Inkscape User Community Onderwerp: Re: [Inkscape-user] Python API Hi, Use PIL (Python Image Library) or for Lines/Graphs http://code.google.com/p/svgfig/ http://www.google.fr/search?q=drawing+with+python&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-US:official&client=firefox-a Norman On Wed, Jul 1, 2009 at 9:56 AM, Maarten van der
on 10.07.2009 08:11
I think the following email came directly to me but was intended for the list. I invite everyone who is interested in this to also look at the recent thread by Soren on the dev list. Aaron Spike
on 10.07.2009 09:48
Hello all, > > http://wiki.inkscape.org/wiki/index.php/QuickDrawingAPI >From my recent toying with python and SVG I have discovered that you can do a lot of stuff in Python-Cairo and then generate an SVG file from that! It seems to me that a lot of the "Artistic API" stuff is already done. ( Not all of it - Inkscape seems to have more scope than what cairo provides. I think it's an SVG version thing. ) Perhaps working with the Cairo (and pycairo) teams could get this idea further and faster. \d
on 22.07.2009 08:54
Hey everybody, ClarisWorks etc...: The meaning of life IS Inkscape, isn't it...? ^^ But seriously, elaborating on my previous question (about the creation of an API for creating "artistic" python scripts), wouldn´t it be handy to have a "build in" script editor? Or is that already present and haven't I been able to locate it in Inkscape? Again, I'm thinking of the way one creates VBA applications in Word... These things would lower the barriers for users to quickly create some scripts, which would result in a more available effects on the internet as well. Regards, Maarten ********************************************************************** This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify the system manager. This footnote also confirms that this email message has been swept by MIMEsweeper for the presence of computer viruses. www.powel.no **********************************************************************