Can't generate Motion from Ellipse or Circle path

Post questions on how to use or achieve an effect in Inkscape.
abc
Posts: 16
Joined: Tue Apr 04, 2017 2:27 am

Can't generate Motion from Ellipse or Circle path

Postby abc » Tue Apr 04, 2017 3:42 am

I want to create long shadow for icons with Motion extension, but if my icon have any ellipse or circle Motion extension create an empty group, not long shadow.
Steps to reproduce:
1) Create New document : File -> New (or Ctrl + N)
2) Select tool :tool_ellipse: : Create circles, ellipses, and arcs (F5)
3) Draw any shape. Doesn't matter size or if is circle or ellipse
4) With shape selected Go to Path menu and select Object to Path (Ctrl + Shift + C)
5) Now go to Extensions -> Generate from Path -> Motion...
6) In Motion window insert any Magnitude value ex: 100 and Angle : 45, then select OK button
- Now almost nothing happening :
(*) Long shadow isn't created
(*) NO error or info displayed
(*) BUT if you open Objects window : Object menu -> Objects... you will notice this:
-- Under Layer 1 is one group who have inside 1 path and 1 empty group

I have to mention that my shape doesn't have any stroke, and have assigned one color
What i have tried :
- If i draw an Rectagle/Square/Star/Triangle and follow above steps LongShadow is created
- After step 4: I did also and Stroke to Path (Ctrl+Alt+C), then continued with steps 5 and 6, but same problem
- Reinstalling Inkscape ( 0.92.1 r) and it's dependencies doesn't work
- Downgrated Inkscape up to last 4 version in Arch Linux x64 => doesn't work
- Booted from Linux Mint 18.1 Live CD, Installed Inkscape => same problem
- Booted from openSuse Tumbleweed Live CD, Installed Inkscape => same problem

OS : ArchLinux x64
Inkscape V 0.92.1 r
Inkscape dependencies installed : desktop-file-utils gc gsl gtkmm gtkspell hicolor-icon-theme imagemagick libxslt poppler-glib popt potrace python2 ttf-dejavu gvfs pstoedit python2-lxml python2-numpy python2-scour texlive-core uniconvertor boost intltool

I want to use Motion extension because i'm using Inkscape --verbs to create LongShadow for more than 2000 icons from batch script. I don't want to use Extrude or Interpolation because shadow will look pixelated

Am i doing something wrong?
Thank's in advance

tylerdurden
Posts: 2344
Joined: Sun Apr 14, 2013 12:04 pm
Location: Michigan, USA

Re: Can't generate Motion from Ellipse or Circle path

Postby tylerdurden » Tue Apr 04, 2017 4:11 am

You are not doing anything wrong, I can replicate the issue in Inkscape 0.92.1 r15371, Win 8.1 64 bit.

There seems to be a workaround: with circles/ellipsis, after convert to path, add nodes and then run the extension. Maybe this can help.
Attachments
Motion_on_ellipse_Circle.png
Motion_on_ellipse_Circle.png (129.88 KiB) Viewed 3751 times
Have a nice day.

I'm using Inkscape 0.92.2 (5c3e80d, 2017-08-06), 64 bit win8.1

The Inkscape manual has lots of helpful info! http://tavmjong.free.fr/INKSCAPE/MANUAL/html/

abc
Posts: 16
Joined: Tue Apr 04, 2017 2:27 am

Re: Can't generate Motion from Ellipse or Circle path

Postby abc » Tue Apr 04, 2017 5:36 am

Thank's for ideea, but i can't do this from batch script / Inkscape verbs
My script do :
- First i optimize all files with scour & svgo
- Get objects ID's from : inkscape -f "$file_name" -z --query-all IGNORIG first id (starting with svg'Number')
- If exists any groups in file, founded id's isn't corect, so it will open "$file_name" in Inkscape, UnGroup N (where n is number of groups) times, save and get again ID's.
- Now i have all ID's into array
- An extra step to verif ID's is to make a copy of $file_name" select all founded id's, delete them and save. Then i check for nr. of id to be 0
- If ID isn't start with path*, it's mean that object with that id is not a path and need to be converted (ex: circle, ellipse, text). Because .svg file was optimized there's no any manual ID name, so NO mistakes were made.
- Now i open file in file in Inkscape, select ID's, convert them to path if needed, then using verb : --verb=org.ekips.filter.motion.noprefs it will generate long shadow for selected objects.
- After that i Ungroup ALL, delete ONLY objects with founded ID's, select all remaining objects and union them

Ex: for an icon with 3 paths :
-- script will find ID's : path2, path343 and path500
-- then command for creating long shadow for this icon is:

$ inkscape "$file_name" --select=path2 --select=path343 --select=path500 --verb=org.ekips.filter.motion.noprefs --select=path2 --select=path343 --select=path500 --verb=EditDelete --verb=EditSelectAll --verb=SelectionUnGroup --verb=SelectionUnGroup --verb=SelectionUnion --verb=FileSave --verb=FileQuit

- So i will have my long shadow for icon on separate file, and will took only 2-3 sec. Imagine making shadow manually for 2000+ files...
Also i found a way to SPEED up Inkscape on command line, because on default settings Inkscape will open in more than 5 sec ;)

BEFORE Run this script make sure you setup Inkscape :

(!!!) Edit > Preferences...
--> Interface :
- Maximum documents in Open Recent: 0
--> Interface > Windows :
- CHECK: Don't save window geometry
- CHECK: Save and restore dialogs status
--> Rendering :
- Number of Threads = 4 # I have 4 core processor
- Rendering cache size = 1024 MiB # depending on your RAM size, default is 64
- CHECK: Lowest quality (fastest) for :
- Gaussian blur quality for display
- Filter effects quality for display

(!!!) Make sure that there are [NO] Object/Fill/Align... windows displayed on Inkscape interface

(!!!) Setup : Extensions > Generate from Path > Motion... :
- Magnitude: 400
- Angle: 45

My script working great but i found this ugly BUG in Inkscape. So i need an workaround that let me use Inkscape --verbs to generate LongShadow for ellipse/circle objects.
Can someone please report this BUG, because my english isn't to good, and i don't have an Canonical account.

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

Re: Can't generate Motion from Ellipse or Circle path

Postby brynn » Tue Apr 04, 2017 6:25 am

Setting aside the scripting issue, for the moment -- I don't find the Motion extension very satisfying, to use with fills and no strokes. It really seems to be more effective to use dark strokes, and with or without lighter fills. Because for a circle, the motion part is a group of many narrow strips.

I added a lot of nodes to get the attached result.

I'm not sure if I would call this a bug, as much as a feature which just isn't capable of doing what you want.

But for your project with scripting, maybe it would be possible to create all the circles or ellipses with a bunch of extra nodes, before you run the script? Maybe you could run a script on them, that adds nodes to the curves???

If you want to get a little more involved, you'd be welcome to make a bug report/feature request about this. If any developers are interested, you could have a dialog with them. https://launchpad.net/inkscape
Attachments
cm.png
cm.png (35.73 KiB) Viewed 3722 times

abc
Posts: 16
Joined: Tue Apr 04, 2017 2:27 am

Re: Can't generate Motion from Ellipse or Circle path

Postby abc » Tue Apr 04, 2017 6:58 am

Thank's "brynn", but i really think is a BUG. Try this:
- Draw any shape with tool : Create circles, ellipses, and arcs (F5)
- Convert shape to Path. Now circle/elipse have 4 nodes
- Select tool : Edit path by nodes (F2)
- Select any 1 node from circle/elipse and move it in any direction
- Now if you apply Extensions -> Generate from Path -> Motion... it will WORK with 4 nodes & ellipse
So why not with original shape? Definitely a BUG
Unfortunately i CAN'T do this from Inkscape verbs, and icons doesn't have only circles or only rectagles to be able to see only broken shadows.
I like Motion extension because generate an LongShadow SYMPLIFIED. Also using Interpolation for creating shadow and Path -> Simplify (Ctrl+L) will 'break' my shadow

abc
Posts: 16
Joined: Tue Apr 04, 2017 2:27 am

Re: Can't generate Motion from Ellipse or Circle path

Postby abc » Tue Apr 04, 2017 7:07 am

Or try this :
- Select all nodes after Convert shape to path
- Press Arrow UP key (Will move object with some pixels in up dirrection)
- Press Arrow DOWN key (Will return object to first/original location)
- Now Motion extension will work.
So why not can't create motion after only converted to path and need to be moved and returned to default pozition ?

Moini
Posts: 3381
Joined: Mon Oct 05, 2015 10:44 am

Re: Can't generate Motion from Ellipse or Circle path

Postby Moini » Tue Apr 04, 2017 7:21 am

Here's a related bug report: https://bugs.launchpad.net/inkscape/+bug/542260
(something has been fixed, and the fix introduced this issue, see comments)

You could bump the report by adding info about the error occurring in your Inkscape version.
Something doesn't work? - Keeping an eye on the status bar can save you a lot of time!

Inkscape FAQ - Learning Resources - Website with tutorials (German and English)

Moini
Posts: 3381
Joined: Mon Oct 05, 2015 10:44 am

Re: Can't generate Motion from Ellipse or Circle path

Postby Moini » Tue Apr 04, 2017 7:25 am

(These actually seem to be two issues - one is when the circle is large, and the letters in its path data are capitalized - then, moving up+down does not help - the other one is when the circle is smaller, and the letters in its path data are lower case, then moving up+down does help)
Something doesn't work? - Keeping an eye on the status bar can save you a lot of time!

Inkscape FAQ - Learning Resources - Website with tutorials (German and English)

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

Re: Can't generate Motion from Ellipse or Circle path

Postby brynn » Tue Apr 04, 2017 7:26 am

That's interesting about moving a node. In other situations, when we can move a node and it seems to fix the problem, the problem is a display issue (and moving a node sort of jogs it into displaying properly). Unfortunately, I don't know enough about the technical side of Inkscape, to know if that's the situation, in this case.

Yes, I see what you mean! It's hard to think that might be a display issue.

Maybe some other members here will know more than I do, and can give you a better answer.

And as I said, feel free to report it. Or one of us can, if you don't want to get involved. (Unless it's already been reported...)

Whoops, and Moini posts while I type....

abc
Posts: 16
Joined: Tue Apr 04, 2017 2:27 am

Re: Can't generate Motion from Ellipse or Circle path

Postby abc » Sun Apr 09, 2017 6:17 pm

I've reported these bugs 4 days ago at https://bugs.launchpad.net/inkscape/+bug/1679618
But NO respose since then, so I'm asking for a little help from people interested.
Please bump the report / add comment, because this affect at least 4 Inkscape versions and ALL users with Inkscape last version.
Thank's

tylerdurden
Posts: 2344
Joined: Sun Apr 14, 2013 12:04 pm
Location: Michigan, USA

Re: Can't generate Motion from Ellipse or Circle path

Postby tylerdurden » Sun Apr 09, 2017 9:04 pm

I'd look for a workaround, or I'd try to customize the extension.
Have a nice day.

I'm using Inkscape 0.92.2 (5c3e80d, 2017-08-06), 64 bit win8.1

The Inkscape manual has lots of helpful info! http://tavmjong.free.fr/INKSCAPE/MANUAL/html/

tylerdurden
Posts: 2344
Joined: Sun Apr 14, 2013 12:04 pm
Location: Michigan, USA

Re: Can't generate Motion from Ellipse or Circle path

Postby tylerdurden » Mon Apr 10, 2017 11:34 am

It seems the non-extruding ellipse paths will extrude if the path is reversed when in node-editing mode.

Maybe the script can use some verbs to make that reversal happen...?
ToolNode
EditSelectAll
SelectionReverse
ToolSelector


Just thinkin out loud... Maybe it won't work for your process.

TD
Have a nice day.

I'm using Inkscape 0.92.2 (5c3e80d, 2017-08-06), 64 bit win8.1

The Inkscape manual has lots of helpful info! http://tavmjong.free.fr/INKSCAPE/MANUAL/html/

abc
Posts: 16
Joined: Tue Apr 04, 2017 2:27 am

Re: Can't generate Motion from Ellipse or Circle path

Postby abc » Mon Apr 10, 2017 6:10 pm

Thanks 'tylerdurden' for your support, it's by far the best way to manage this bug with --verbs.
BUT, as you can see in below image there seems to be another BUG (also reported in https://bugs.launchpad.net/inkscape/+bug/1679618 ) :
BUG2.png
BUG2.png (21.51 KiB) Viewed 3575 times

Quick recap :
--- BUG 1 -> Can't generate Motion from Ellipse or Circle path
--- BUG 2 -> After some 'tweaks' LongShadow is generated, but it's WRONG
So far some workarounds to bypass BUG 1 was found (see above posts).
Now I need some tweaks to baypass BUG 2, and generate right LongShadow. Any ideas?

To reproduce BUG2:
- Save attached .svg file: test.svg
- Open terminal in same directory with test.svg
- run in terminal this command :
inkscape test.svg --verb=EditSelectAll --verb=SelectionGroup --verb=SelectionUnGroup --verb=ToolNode --verb=EditSelectAll --verb=SelectionReverse --verb=ToolSelector --verb=org.ekips.filter.motion.noprefs
Attachments
test.svg
(620 Bytes) Downloaded 168 times

tylerdurden
Posts: 2344
Joined: Sun Apr 14, 2013 12:04 pm
Location: Michigan, USA

Re: Can't generate Motion from Ellipse or Circle path

Postby tylerdurden » Mon Apr 10, 2017 10:36 pm

There is no stroke set on the objects, so Id try adding the verb --EditPasteStyle, and copying an object with a stroke set to none before running the script.

Code: Select all

Inkscape test.svg --verb=EditSelectAll --verb=EditPasteStyle --verb=SelectionGroup --verb=SelectionUnGroup --verb=ToolNode --verb=EditSelectAll --verb=SelectionReverse --verb=ToolSelector --verb=org.ekips.filter.motion.noprefs
Have a nice day.

I'm using Inkscape 0.92.2 (5c3e80d, 2017-08-06), 64 bit win8.1

The Inkscape manual has lots of helpful info! http://tavmjong.free.fr/INKSCAPE/MANUAL/html/

abc
Posts: 16
Joined: Tue Apr 04, 2017 2:27 am

Re: Can't generate Motion from Ellipse or Circle path

Postby abc » Tue Apr 11, 2017 5:30 am

I've tryed from terminal and from Inkscape GUI doing that trick with Paste style, and didn't work. Also even if I add stroke manual didn't work. Did you succeed?

tylerdurden
Posts: 2344
Joined: Sun Apr 14, 2013 12:04 pm
Location: Michigan, USA

Re: Can't generate Motion from Ellipse or Circle path

Postby tylerdurden » Tue Apr 11, 2017 6:54 am

Seems to work here... verb location is different in this test, but it worked in the earlier location too.

Image
Have a nice day.

I'm using Inkscape 0.92.2 (5c3e80d, 2017-08-06), 64 bit win8.1

The Inkscape manual has lots of helpful info! http://tavmjong.free.fr/INKSCAPE/MANUAL/html/

tylerdurden
Posts: 2344
Joined: Sun Apr 14, 2013 12:04 pm
Location: Michigan, USA

Re: Can't generate Motion from Ellipse or Circle path

Postby tylerdurden » Tue Apr 11, 2017 6:56 am

PS:
You might need to leave one instance of Inkscape open to keep the style in the clipboard. (Although, it seemed to work here even without copying to clipboard.)
Have a nice day.

I'm using Inkscape 0.92.2 (5c3e80d, 2017-08-06), 64 bit win8.1

The Inkscape manual has lots of helpful info! http://tavmjong.free.fr/INKSCAPE/MANUAL/html/

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

Re: Can't generate Motion from Ellipse or Circle path

Postby brynn » Tue Apr 11, 2017 7:43 am

abc wrote:I've reported these bugs 4 days ago at https://bugs.launchpad.net/inkscape/+bug/1679618
But NO respose since then, so I'm asking for a little help from people interested.
Please bump the report / add comment, because this affect at least 4 Inkscape versions and ALL users with Inkscape last version.
Thank's


I can't help with fixing the extension. But I just wanted to mention that my experience with bug reports, is that I've never figured out what makes developers fix some bugs right away, and why other bugs are 8 to 10 years old. Obviously certain things will have a higher priority. But for a bug which doesn't crash the program, it's often hard to understand what takes priority. Just like with development, sometimes I think things that certain developers find interesting get fixed sooner than later.

Actually 4 days is expecting a lot! I would give it a couple of months, before I gave up hope of a quick fix. Some developers might only visit the bug tracker once per week. Others maybe once per month. I've reported bugs years ago, which have never even gotten Status and Importance ranking (which means they aren't even confirmed to be a bug yet). But not too long ago, a bug I reported was fixed in something like a week!

I suspect that because there is a simple workaround, your report probably won't be a high priority for fixing right away, or even before the next version. Probably your particular case, using Inkscape from command line and being unable to add new nodes or reverse the path (as TD discovered), is not very common. I don't know that for a fact, but that's my best guess.

Out of curiosity, is the discussion about verbs related to fixing the extension, or making the commandline produce the wanted results? (As many of you know, I'm not very technically inclined.)

tylerdurden
Posts: 2344
Joined: Sun Apr 14, 2013 12:04 pm
Location: Michigan, USA

Re: Can't generate Motion from Ellipse or Circle path

Postby tylerdurden » Tue Apr 11, 2017 8:06 am

In this case the OP wants to get the work done; verbs in the CLI are under their control, and may work for their needs.

A verb based solution in the CLI may also show an avenue to resolve the issue in an extension, since verbs can be used there also.
Have a nice day.

I'm using Inkscape 0.92.2 (5c3e80d, 2017-08-06), 64 bit win8.1

The Inkscape manual has lots of helpful info! http://tavmjong.free.fr/INKSCAPE/MANUAL/html/

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

Re: Can't generate Motion from Ellipse or Circle path

Postby brynn » Tue Apr 11, 2017 8:10 am

Thanks for the info!

abc
Posts: 16
Joined: Tue Apr 04, 2017 2:27 am

Re: Can't generate Motion from Ellipse or Circle path

Postby abc » Tue Apr 11, 2017 8:20 am

Sorry 'tylerdurden', but or I'm a noob or I miss something because in my sistem doesn't work.
I've tryed this :
1) Open Inkcape -> create 1 rectagle with a stroke set to none
2) select that rectangle, Edit -> copy
3) run this command :
inkscape test.svg --verb=EditSelectAll --verb=SelectionGroup --verb=SelectionUnGroup --verb=EditPasteStyle --verb=ToolNode --verb=EditSelectAll --verb=SelectionReverse --verb=ToolSelector --verb=org.ekips.filter.motion.noprefs
4) Now same BUG2 occur
Also I've tryed with that rectangle converted to path, but same problem. Assigning stroke to rectagle doesn't work either. Opening and test.svg into another instance before running terminal command from step 3) doesn't work.
To be sure that isn't my OS 'broken' (Arch Linux), I've tryed also in W7. Did I miss something?

abc
Posts: 16
Joined: Tue Apr 04, 2017 2:27 am

Re: Can't generate Motion from Ellipse or Circle path

Postby abc » Tue Apr 11, 2017 8:45 am

Thanks 'brynn' for your support

tylerdurden
Posts: 2344
Joined: Sun Apr 14, 2013 12:04 pm
Location: Michigan, USA

Re: Can't generate Motion from Ellipse or Circle path

Postby tylerdurden » Tue Apr 11, 2017 9:18 am

Maybe try without group/ungroup verbs, they don't do anything useful that I can see.
Have a nice day.

I'm using Inkscape 0.92.2 (5c3e80d, 2017-08-06), 64 bit win8.1

The Inkscape manual has lots of helpful info! http://tavmjong.free.fr/INKSCAPE/MANUAL/html/

tylerdurden
Posts: 2344
Joined: Sun Apr 14, 2013 12:04 pm
Location: Michigan, USA

Re: Can't generate Motion from Ellipse or Circle path

Postby tylerdurden » Tue Apr 11, 2017 9:19 am

Also, does your version of inkscape support paste-style on those objects?
Have a nice day.

I'm using Inkscape 0.92.2 (5c3e80d, 2017-08-06), 64 bit win8.1

The Inkscape manual has lots of helpful info! http://tavmjong.free.fr/INKSCAPE/MANUAL/html/

tylerdurden
Posts: 2344
Joined: Sun Apr 14, 2013 12:04 pm
Location: Michigan, USA

Re: Can't generate Motion from Ellipse or Circle path

Postby tylerdurden » Tue Apr 11, 2017 11:09 am

Manual approach:
Image
Have a nice day.

I'm using Inkscape 0.92.2 (5c3e80d, 2017-08-06), 64 bit win8.1

The Inkscape manual has lots of helpful info! http://tavmjong.free.fr/INKSCAPE/MANUAL/html/


Return to “Help with using Inkscape”