Jump to content
GreenSock

Search In
  • More options...
Find results that contain...
Find results in...
padders

MorphSVG crashing browsers! (Turns out it was InkScape produced SVGs causing an issue)

Recommended Posts

Hi, 

 

I'm having some problems with MorphSVG. The latest version seems to be crashing every browser other than Internet Explorer 11 (which works, amazingly!) with a little morph I've made. (Chrome, Firefox and Opera all crash)

 

I'm not sure If I've done something wrong, if inkscape has created a slightly dodgy svg file, or if it's a bug in the latest version of MorphSVGPlugin. I can't get any error data as it totally kills the browser tab.

 

It was working in the version of MorphSVGPlugin dated 13/10/2015, but it wasn't setting the shapeIndex correctly on the A's in my morph, nor was setting that value making any difference to the resultant morph when I changed shapeIndex manually. I decided to use your codepen to check I was doing it correctly so forked it and the crashing behaviour started. Since then I've updated my local copy of the plugin (dated 21/10/2015) and it's now crashing in everything other than IE on my webpage too. 

 

Does anyone know what's going on?

 

Note that the latest version now sets the shapeIndex correctly (at least in IE, I can't see the others as they crash), so that behaviour seems to have been caused by the older version of the plugin I was using.

 

Cheers,

Paul

See the Pen xwQJbE by padders1980 (@padders1980) on CodePen

Link to post
Share on other sites

Nice, I did wonder if Inkscape was doing something funny. It's not the most stable of products!

 

It is doing something strange with the N now though. Wonder if the tool is moving something it shouldn't!

Link to post
Share on other sites

Which is easily sorted using the shapeIndex tool.

 

Ta. that sorted it. You're a star :)

 

Wonder what was actually up with the SVG code! Still, that's a nice tool to know about. I shall use it in future.

  • Like 1
Link to post
Share on other sites

I did find a little problem in the parsing algorithm in MorphSVGPlugin that could cause that crash if your path has multiple "z" commands. Pretty uncommon, but possible. Sorry about that - I updated the codepen file as well as the bonus download zip files. Version 0.5.0.

  • Like 3
Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.

×