Problem with SVG files

Post Reply
UrbanCyborg
Posts: 625
Joined: Mon Nov 15, 2021 9:23 pm

Problem with SVG files

Post by UrbanCyborg »

Apparently VMD still has an issue with importing SVG files as backdrops. I had chalked it up to a shaky SVG implementation on Adobe's part when VMD wouldn't correctly display a file created in Photoshop, but it behaves the same way with one created in Inkscape, which some established developers here use. The issue, which others have reported, is that Inkscape displays a black field, instead of the SVG file.

Is there a fix or workaround for this?
Cyberwerks Heavy Industries -- viewforum.php?f=76
UrbanCyborg
Posts: 625
Joined: Mon Nov 15, 2021 9:23 pm

Re: Problem with SVG files

Post by UrbanCyborg »

For what it's worth, I discovered that the black screen is actually part of the retainer screw graphic, and it's covering up the SVG graphic. On a secondary note, if I don't enable screws, I can see the SVG, but it's scaled ridiculously small if I had the SVG canvas set to 144 x 360 pixels or 288 by 720 pixels (for a two-inch wide module), which are the sizes for a PNG background. What is the size VMD wants to see for a background SVG? I'd have thought it didn't matter, but obviously, it does.
Cyberwerks Heavy Industries -- viewforum.php?f=76
ColinP
Posts: 1000
Joined: Mon Aug 03, 2020 7:46 pm

Re: Problem with SVG files

Post by ColinP »

It's still not working for me.

In VMD editor preview mode sometimes I get the miniscule version you're talking about but if I scroll the view it results in a crazy corrupted thing that looks like it's copying randomish bits of screen.

On compiling it ignores the SVG altogether and displays a plain background.
Cherryaudio Danny
Site Admin
Posts: 23
Joined: Mon Jan 03, 2022 9:13 pm

Re: Problem with SVG files

Post by Cherryaudio Danny »

Hello,

Are the SVG files sized to the dimensions of your module?
If you want to troubleshoot this further, please submit a support request and attach an SVG file that presents the behavior described.

Thanks!

Danny
UrbanCyborg
Posts: 625
Joined: Mon Nov 15, 2021 9:23 pm

Re: Problem with SVG files

Post by UrbanCyborg »

Submit it in this forum? Or some other way. On Kayako there's just the option to chat, so far as I can see.
Cyberwerks Heavy Industries -- viewforum.php?f=76
ColinP
Posts: 1000
Joined: Mon Aug 03, 2020 7:46 pm

Re: Problem with SVG files

Post by ColinP »

Hi Danny,

If you remember we discussed this issue in late January. To create the problem - just generate a 144 x 360 pixel SVG image and use it as the standard resolution background in VMDs default start up state (which produces a 144 x 360 module).

Then simply compile and try dragging things around and it produces this sort of mess...
testoutput.png
testoutput.png (154.67 KiB) Viewed 2184 times
I don't think there's anything weird about the SVG file as I've tried several from different sources and none work but have sent you a copy in an email anyway.

I'm using Windows 10 and the very latest 2.5.5 version of VM and VMD.
ColinP
Posts: 1000
Joined: Mon Aug 03, 2020 7:46 pm

Re: Problem with SVG files

Post by ColinP »

Also if you create a 288 x 720 pixel file and use that as the High Resolution image too (so that there are both standard and high res files) then the same problems occur. Although according to the documentation if one uses an SVG file then only one file is required. But I did the test just in case.
ColinP
Posts: 1000
Joined: Mon Aug 03, 2020 7:46 pm

Re: Problem with SVG files

Post by ColinP »

I thought there might be some problem with Inkscape tags so stripped everything down to plain SVG with nothing but a single rectangle and the problem persists.

As you can see the SVG file is about as vanilla as it could possibly be...

Code: Select all


<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->

<svg
   width="144"
   height="360"
   viewBox="0 0 38.099999 95.250003"
   version="1.1"
   id="svg828"
   xmlns="http://www.w3.org/2000/svg"
   xmlns:svg="http://www.w3.org/2000/svg">
  <defs
     id="defs825" />
  <g
     id="layer1">
    <rect
       style="fill:#ff0000;stroke-width:0.223044"
       id="rect911"
       width="15.696801"
       height="16.522949"
       x="11.979137"
       y="32.219749" />
  </g>
</svg>
Post Reply

Return to “Module Designer”