NEW! PaintShop Pro 2019

help! Can't view this svg file

Corel Paint Shop Pro

Moderator: Kathy_9

Re: help! Can't view this svg file

Postby ehume » Thu May 23, 2019 9:29 pm

Well, LF, you made me do some homework. First of all Chrome (albeit not chromium) asked me about sharing (which I avoid) before it opened a file. Firefox OTOH opened it just fine. PSP just shows a lavender swatch. Affinity shows the image as it is. Inkscape, of course, showed it true. Here is the SVG (the website will not upload my copy of the SVG file)(the png was exported from Inkscape.):
History_of_the_Universe.png

The SVG file is located here
https://commons.wikimedia.org/wiki/File:History_of_the_Universe.svg
Had PS3, PSP3; Installed: PSP-4.12, 5.03, 6.02, 7.04 (liked it a lot & used it for years), 9.00, 10, 11, x4, x6, x7, x8, x9; now using PSPx10 (PSP 2018; version 20.2.0.1 x64) on Win 10-64; rejected PSP 2019.
User avatar
ehume
 
Posts: 454
Joined: Tue Sep 18, 2012 2:05 am
operating_system: Windows 7 Home Premium
System_Drive: C
32bit or 64bit: 64 Bit
motherboard: Gigabyte GA-Z87X-UD4H
processor: i7 4770k
ram: 16GB
Video Card: Intel HD4600
sound_card: no_sound_card
Hard_Drive_Capacity: 512GB+4TB
Monitor/Display Make & Model: Acer KN242HYL
Corel programs: PSP 2018 32b & 64b, AS3 64b, PE5 64b

Re: help! Can't view this svg file

Postby LeviFiction » Fri May 24, 2019 2:31 am

I don't know why we're doing this back and forth. This isn't a competition on which one is better. It's just an alternative option is anyone wants it.

Here you can see what it looks like in action. I try several SVGs to show it off. First I try importing into PSP, then I run the script to demonstrate the difference in how PSP imports, if it can at all, and how my script imports. https://drive.google.com/file/d/1NYz8hD ... YeJB5/view

This script is not perfect. Although it may not be be clear in the video on the History of the universe SVG the text rendering is completely different. But all of the other visual effects work just fine.

In every other SVG text and gradients, and effects all appear as they are meant to.

On my computer Inkscape is excruciatingly slow to open and load files. So I use the command line like this. inkscape SVGfile.svg -e svgfile.png That will load in and export a PNG file without opening the UI. Which, on my computer, is the better option.

Doing a comparison. Both my script and Inkscape command line averaged about 5 seconds importing into PSP via script. The only differences came with the History of the Universe and Linux Distribution SVG imports.

History of the Universe: my script importedd it in 5 seconds. Inkscape in 15.

Linux distribution History: My script 15 seconds, Inkscape 1.5 minutes.

For the superior text rendering that extra slowdown may be worth it. I won't even attempt to fix the text issue unless someone actually wants this script.
LeviFiction
Advisor
 
Posts: 5399
Joined: Thu Oct 02, 2008 1:07 pm
Location: USA
operating_system: Windows 10
System_Drive: C
32bit or 64bit: 64 Bit
Corel programs: PSP: 8, 9, X, XI, X2, X8,X9, 2018, 2019

Re: help! Can't view this svg file

Postby ehume » Fri May 24, 2019 3:01 am

Impressive results. But I can't figure out the script. You mention "electron application." What is that? Further down you mention that you did "edited the Nik Script." I did not know Nik had a script. How does that work?
Had PS3, PSP3; Installed: PSP-4.12, 5.03, 6.02, 7.04 (liked it a lot & used it for years), 9.00, 10, 11, x4, x6, x7, x8, x9; now using PSPx10 (PSP 2018; version 20.2.0.1 x64) on Win 10-64; rejected PSP 2019.
User avatar
ehume
 
Posts: 454
Joined: Tue Sep 18, 2012 2:05 am
operating_system: Windows 7 Home Premium
System_Drive: C
32bit or 64bit: 64 Bit
motherboard: Gigabyte GA-Z87X-UD4H
processor: i7 4770k
ram: 16GB
Video Card: Intel HD4600
sound_card: no_sound_card
Hard_Drive_Capacity: 512GB+4TB
Monitor/Display Make & Model: Acer KN242HYL
Corel programs: PSP 2018 32b & 64b, AS3 64b, PE5 64b

Re: help! Can't view this svg file

Postby LeviFiction » Fri May 24, 2019 3:14 am

The Nik script by JSJ is a script to run an external application like the NIK standalone apps and then return the result as a new layer into PSP. You can find it here: viewtopic.php?f=104&t=64877

I made custom edits to that script to work with my program.

Electron is a a cross-platform development framework for creating desktop applications using HTML and javascript. I wrote a very simple application in javascript to convert SVG files into PNGs and compiled it into a desktop application using Electron. I then ussed the Nik script to call this desktop application and import the results into PSP.

As I've said I can do this same thing with Inkscape, but it requires some extra bits to deal with the wait times.
LeviFiction
Advisor
 
Posts: 5399
Joined: Thu Oct 02, 2008 1:07 pm
Location: USA
operating_system: Windows 10
System_Drive: C
32bit or 64bit: 64 Bit
Corel programs: PSP: 8, 9, X, XI, X2, X8,X9, 2018, 2019

Re: help! Can't view this svg file

Postby ehume » Fri May 24, 2019 4:37 am

I looked at a script with Notepad++. JoeB does like structured programming. That is a good thing. It reminds me of the thousands of lines of CSS code that made up my old themes in Firefox.

I also looked at the Electron home page. I did not see a DL button. I'll look again tomorrow when I am not so tired.

Thanks
Had PS3, PSP3; Installed: PSP-4.12, 5.03, 6.02, 7.04 (liked it a lot & used it for years), 9.00, 10, 11, x4, x6, x7, x8, x9; now using PSPx10 (PSP 2018; version 20.2.0.1 x64) on Win 10-64; rejected PSP 2019.
User avatar
ehume
 
Posts: 454
Joined: Tue Sep 18, 2012 2:05 am
operating_system: Windows 7 Home Premium
System_Drive: C
32bit or 64bit: 64 Bit
motherboard: Gigabyte GA-Z87X-UD4H
processor: i7 4770k
ram: 16GB
Video Card: Intel HD4600
sound_card: no_sound_card
Hard_Drive_Capacity: 512GB+4TB
Monitor/Display Make & Model: Acer KN242HYL
Corel programs: PSP 2018 32b & 64b, AS3 64b, PE5 64b

Re: help! Can't view this svg file

Postby LeviFiction » Fri May 24, 2019 6:29 am

Electron relies on Node.js. So you need to install node with the npm (node package manager). You can download a starter package from git or start one from scratch using npm to create a new node project and then calling npm install electron (full vali instructions on the electron site) to install electron in the project and make it a dependency of the project.
LeviFiction
Advisor
 
Posts: 5399
Joined: Thu Oct 02, 2008 1:07 pm
Location: USA
operating_system: Windows 10
System_Drive: C
32bit or 64bit: 64 Bit
Corel programs: PSP: 8, 9, X, XI, X2, X8,X9, 2018, 2019

Previous

Return to Paint Shop Pro

Who is online

Users browsing this forum: No registered users and 7 guests