Performance Video: Normal or not?

Post questions on how to use or achieve an effect in Inkscape.
snowdrop
Posts: 2
Joined: Wed Jul 18, 2012 8:04 am
Location: Sweden

Performance Video: Normal or not?

Postby snowdrop » Wed Jul 18, 2012 8:16 am

I recorded a short test session with Inkscape where I try to demonstrate the very slow responsiveness I get:

https://vimeo.com/45914597

It seems related to filters and/or raster graphics. What I want to ask here is the following:

1. Is what we see in the video "normal" functionality of Inkscape and what is to be expected when using those filters and raster images?
2. Why is hardly any of my cpu cores used? (I'm on a quad core system with a 64 OS)
3. Why isn't my graphics cards used to some expected extent? (Most complex 3d games currently run on it flawlessly on ultrahigh in 1920x1080 and all other apps that use the GPU work well)
4. Are filters, for example drop shadows, (re)rendered realtime, each time you zoom in or out?
5. Why is Inkscape slowed down by raster images? (I can name no other program/example where raster images need to "load" that much when I zoom in...)

While I love Inkscape and what it's aspiring to become and am a fan and participant of the open source community in general, I still would want to get a greater understanding of how it comes that my hardware is far from properly utilized and what causes the "sluggishness" and how it can be avoided. Please don't tell me to change the view-mode or change software or system - that isn't an answer to any of my questions. Would appreciate it if somebody could confirm some of my suspicions and show me the light. ;)

User avatar
druban
Posts: 1917
Joined: Fri Nov 20, 2009 10:48 pm

Re: Performance Video: Normal or not?

Postby druban » Thu Jul 19, 2012 10:55 am

Some of the issues you mention are addressed here http://wiki.inkscape.org/wiki/index.php/Release_notes/0.49
Although I don't think anyone with a
quad core system with a 64 OS
is really into waiting an indefinite time until the release of 0.49 ;) ! So you might want to download a development build and see if that improves rendering and performance.
I wouldn't know if it does though since I am on a low performance machine. I started typing this response a couple of days before your post and I'm still not done....
Your mind is what you think it is.

snowdrop
Posts: 2
Joined: Wed Jul 18, 2012 8:04 am
Location: Sweden

Re: Performance Video: Normal or not?

Postby snowdrop » Wed Jul 25, 2012 11:12 am

druban wrote:Some of the issues you mention are addressed here http://wiki.inkscape.org/wiki/index.php/Release_notes/0.49


It's great that they deal with plenty of issues that would bring more speed in theory, yet all of my questions remain unanswered in regards to what is expected of Inkscape when it comes to the performance in my case. :( Thanks for your input though.

Uktrunie
Posts: 154
Joined: Sun Jul 18, 2010 4:48 am

Re: Performance Video: Normal or not?

Postby Uktrunie » Thu Jul 26, 2012 11:20 am

First of all, I'm not an Inkscape developer, so my answers could be waaaay off. But:

snowdrop wrote:1. Is what we see in the video "normal" functionality of Inkscape and what is to be expected when using those filters and raster images?


I'm not sure what parts were exactly filters and what parts were raster images, but I'd say what I see is pretty normal. If try to do as in the video, my 5 years old dual core dinosaur would certainly explode. :)

snowdrop wrote:2. Why is hardly any of my cpu cores used? (I'm on a quad core system with a 64 OS)

If not mistaken Inskcape only uses one core. It has been requested, but I don't know the state of this.

snowdrop wrote:3. Why isn't my graphics cards used to some expected extent? (Most complex 3d games currently run on it flawlessly on ultrahigh in 1920x1080 and all other apps that use the GPU work well)

Inkscape renderer doesn't use the GPU... It's one of the things that will change with 0.49 AFAIK.

snowdrop wrote:4. Are filters, for example drop shadows, (re)rendered realtime, each time you zoom in or out?

I'm not sure, but I believe so, yes, if you zoom out things are a lot better, I suspect it's because of that. Also I remember (or think I remember) some discussion about using some sort of buffer in the new renderer that would help with the repainting, so yes, my bet is that all gets redrawn every time.

snowdrop wrote:5. Why is Inkscape slowed down by raster images? (I can name no other program/example where raster images need to "load" that much when I zoom in...)


No idea, but I also experienced this.

~suv
Posts: 2272
Joined: Sun May 10, 2009 2:07 am

Re: Performance Video: Normal or not?

Postby ~suv » Thu Jul 26, 2012 11:34 am

Uktrunie wrote:
snowdrop wrote:2. Why is hardly any of my cpu cores used? (I'm on a quad core system with a 64 OS)
If not mistaken Inskcape only uses one core. It has been requested, but I don't know the state of this.
The next major version will support multi-threading via OpenMP for all SVG filter effects (current stable only supports it for Gaussian blurs) - everything else is still running in a single thread (i.e. using a single core).
Uktrunie wrote:
snowdrop wrote:3. Why isn't my graphics cards used to some expected extent? (Most complex 3d games currently run on it flawlessly on ultrahigh in 1920x1080 and all other apps that use the GPU work well)
Inkscape renderer doesn't use the GPU... It's one of the things that will change with 0.49 AFAIK.
No - Inkscape 0.49 will not use the GPU for rendering.

For a summary of performance gains with the new renderer in the next major release, see the preliminary notes (work-in-progress) for 0.49.

User avatar
brynn
Posts: 10309
Joined: Wed Sep 26, 2007 4:34 pm
Location: western USA
Contact:

Re: Performance Video: Normal or not?

Postby brynn » Thu Jul 26, 2012 11:52 am

Most of your questions I can't answer. But I did learn something recently about imported raster images, which might shed some light.

When you embed raster images in Inkscape, it vastly increases the file size. And large file size is the source of many Inkscape performance issues. You can see in the XML Editor, with the raster image selected, the xlink:href value is lines and lines and lines upon lines of text. Apparently that's how Inkscape "reads" the raster image, and every time you do something (like moving it or zooming) is has to "re-read" all that text.

If you simply link the imported raster, it does not affect the file size. (However, if you take the image to another computer, that raster image won't go with it, unless it's embedded.)

I can also agree with Uktrunie about the cores.....or.....well, actually, I'm a little confused about 32 vs 64 vs cores. I know that Inkscape only has a 32-bit support. I think there may be ongoing work on a 64-bit version, but I can't remember where I read that. There is a way, I think to have Inkscape use more than one core, at least for filters. I don't know if it affects imported rasters. If you go to Inkscape Preferences > Filters > Number of Threads, you can change it to match your number of cores. Mine was on the default for years, until recently something about it came up in the forum. I don't remember now what the default was, but I changed mine to 8, and got a very nice performance improvement. Not earth-shattering, but quite significant.

Oh nice, I see that ~suv posted while I was typing. I was hoping she'd show up in this topic :D

~suv
Posts: 2272
Joined: Sun May 10, 2009 2:07 am

Re: Performance Video: Normal or not?

Postby ~suv » Thu Jul 26, 2012 12:36 pm

brynn wrote:I know that Inkscape only has a 32-bit support.

No, this is not true.

Maybe you got confused because the official packages for Inkscape on Windows are currently only available as 32bit application - but this does not mean that Inkscape in general can't be compiled as a 64bit application.

User avatar
brynn
Posts: 10309
Joined: Wed Sep 26, 2007 4:34 pm
Location: western USA
Contact:

Re: Performance Video: Normal or not?

Postby brynn » Thu Jul 26, 2012 6:34 pm

Ooh, well I wouldn't say confused. It's just another case of me not understanding the technical stuff. I do use Windows, and I knew that there's only 32-bit for Windows. But I didn't know that there was 64-bit for other operating systems, or that Inkscape could be compiled in 64-bit.

Can Inkscape be compiled in 64-bit for Windows? Would that improve performance, due to using more cores? Could an average user like me compile a 64-bit Inkscape, if I had proper instructions? Or would that be inadvisable?

And finally, if it's just a case of compiling in a certain way, why couldn't a 64-bit official package be made for Windows (or hasn't yet been made)?

Sorry for all the questions. You know me, I always like to try to understand things, even if eventually I can't comprehend it.

~suv
Posts: 2272
Joined: Sun May 10, 2009 2:07 am

Re: Performance Video: Normal or not?

Postby ~suv » Thu Jul 26, 2012 11:05 pm

Off topic:
brynn wrote:Can Inkscape be compiled in 64-bit for Windows?
Yes

(I know it's doable when cross-compiling for Windows on Linux - I can't tell the amount of work still needed to make this easier if compiling on Windows natively)
brynn wrote:Would that improve performance, due to using more cores?
Again - multi-threading (splitting a single process into several jobs which run in parallel on several (virtual) cores, while accessing the same shared memory) and 32bit vs. 64bit are not the same (and OpenMP multi-threading support does not depend on compiling Inkscape as 64bit application).

(32bit applications can be multi-threaded as well, and your Windows Inkscape 0.48.1 indeed can render Gaussian blurs using multiple cores, as was explained to you in an earlier topic with much more technical details)
brynn wrote:Could an average user like me compile a 64-bit Inkscape, if I had proper instructions? Or would that be inadvisable?
I would never recommend an "average" Inkscape user on Windows (who probably hasn't compiled a single program in his/her live before) to try it - be it based on the current instructions for 32bit, or on future notes for 64bit.
brynn wrote:And finally, if it's just a case of compiling in a certain way, why couldn't a 64-bit official package be made for Windows (or hasn't yet been made)?
Because it's an open-source project, based on voluntary contributions, and never shorts of things that would be great to have, but no one has had the time, interest and/or energy to work on?

User avatar
brynn
Posts: 10309
Joined: Wed Sep 26, 2007 4:34 pm
Location: western USA
Contact:

Re: Performance Video: Normal or not?

Postby brynn » Fri Jul 27, 2012 8:33 am

Oh awesome!
Thanks ~suv :D

(I was guessing that my understanding of threading and cores was still incomplete, so I appreciate your comments which indeed confirm that suspicion :D)


Return to “Help with using Inkscape”