Standard vector format for RunRev

LiveCode is the premier environment for creating multi-platform solutions for all major operating systems - Windows, Mac OS X, Linux, the Web, Server environments and Mobile platforms. Brand new to LiveCode? Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

ale870
Posts: 250
Joined: Tue Apr 22, 2008 9:17 am
Contact:

Standard vector format for RunRev

Post by ale870 » Tue Nov 03, 2009 12:02 pm

Hello,
I need to load some images in RunRev, but I cannot use png, jpg, etc... since they are bitmap format, and have serious problems in image zoom in/out. I need to make a page viewer similar to PDF reader.
I want to convert a PDF page to a vectorial format (e.g. Postscript) and read it in a special RunRev viewer created by me.

I really need to maintain cross-platform support (Linux/Windows).

Can you give me some suggestions to solve this problem? I tried to save (only for testing) some images from FireWorks in PNG-vectorial and reload them in RunRev image control, but it seems such images are loaded as bitmap, and not vectorial (zoom in is terrible!).

Thank you for your help!

Klaus
Posts: 14198
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Post by Klaus » Tue Nov 03, 2009 7:52 pm

Hi ale870,

sorry, but Rev does not support any vector format natively :(


Best

Klaus

ale870
Posts: 250
Joined: Tue Apr 22, 2008 9:17 am
Contact:

Post by ale870 » Tue Nov 03, 2009 9:31 pm

Oh... bad news....
Is there any way to import eps, ps, wmf, etc... of PNG in vectorial format (I tried with png but it is imported in bitmap format)?

ukimiku
Posts: 101
Joined: Thu Oct 22, 2009 10:45 am

Post by ukimiku » Tue Nov 03, 2009 10:17 pm

If your task is to convert .PDF to .PS, it should be possible to extract the .ps portion of the .pdf file since .pdf is based on .ps and contains .ps sections in the file. Do you really need to view/zoom the images being processed?

Another option, if size and memory are not of superior consideration in your case, would be to load big raster images and thus allow deeper zooming. The conversion process could handle true vectorial formats, while the screen display only simulated it.

Anyway, just my 2 cents.

Regards

ale870
Posts: 250
Joined: Tue Apr 22, 2008 9:17 am
Contact:

Post by ale870 » Tue Nov 03, 2009 10:25 pm

My object was creating a server-side procedure (made in java+iText) to read a single pdf page, convert it in a format that I can send to runrev client application which will show such image.
I could converty pdf image in a bitmap-like image (like jpg, tga, png, etc...) but if I could read a vector format from runrev I could create a vector image of the pdf page:

My "dream":

PDF Page->Vectorial format->client runrev (show page, zoom, etc...)

Thank you!

SparkOut
Posts: 2947
Joined: Sun Sep 23, 2007 4:58 pm

Post by SparkOut » Wed Nov 04, 2009 2:13 am

I've not done any testing or delving, but although this material seems to be "in reverse" to your desired requirement, you may find it a helpful start.

http://lists.runrev.com/pipermail/use-r ... 92225.html

Alejandro Tejada made a vector image exporter with various formats, some of it based on a library by Richard Gaskin, I believe. If nothing else, it's food for thought, but I reckon it's quite impressive.

Now, the Geocities site referred to is no longer available, but I have a copy of the export vector stack if you can't track down Alejandro's official source.

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 10052
Joined: Sat Apr 08, 2006 7:05 am
Contact:

Post by FourthWorld » Wed Nov 04, 2009 5:51 am

I haven't had occasion to use it, but I believe WMF is now supported on Windows. With PICT support on Mac that would cover at least those two, if you don't mind making two versions of your files.
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

mwieder
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3581
Joined: Mon Jan 22, 2007 7:36 am
Contact:

Post by mwieder » Wed Nov 04, 2009 6:55 am

Here's Alejandro's new site:

http://capellan2000.000space.com/

ale870
Posts: 250
Joined: Tue Apr 22, 2008 9:17 am
Contact:

Post by ale870 » Wed Nov 04, 2009 9:13 am

Thank you for your help, but it seems everything goes from Rev to vector (and not reverse way).
I will try to import an WMF since it could solve my problems.
Generally speaking, I think this is a BIG HOLE in Rev, since it works with vector but I cannot load any vector image.

I think RunRev should have to contain, built-in, at least a standard vector importer/exporter like SVG, since it it not platform dependent.

Thank you again for your help, this community is always friendly and very reactive!

EDIT: RunRev does NOT support WMF nor EMF.

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 10052
Joined: Sat Apr 08, 2006 7:05 am
Contact:

Post by FourthWorld » Wed Nov 04, 2009 9:29 am

Sorry about the red herring. Not sure where I'd read that (maybe it was just an RQCC request; I had thought it was in the docs circa v2.9, but double-checking it seems indeed it's not there).

I agree it would be way cool to have it, but as multi-platform tool it would be limited to SVG or EPS. Either would be better than nothing.

There are a couple requests for this in the RQCC if you have some spare votes looking for a home:
http://quality.runrev.com/qacenter/show_bug.cgi?id=5336
http://quality.runrev.com/qacenter/show_bug.cgi?id=683
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

SparkOut
Posts: 2947
Joined: Sun Sep 23, 2007 4:58 pm

Post by SparkOut » Wed Nov 04, 2009 10:37 am

On Alejandro's "new" site location, there is a Eps_Import_V04 metacard stack which I have just opened with RunRev and imported .ai files quite happily.
This again may give you helpful info.

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 10052
Joined: Sat Apr 08, 2006 7:05 am
Contact:

Post by FourthWorld » Wed Nov 18, 2009 1:55 am

FWIW, while looking up something else I found where I'd gotten the idea that the engine handles WMF files -- from the v3.0 Engine Change Log (also in v3.5 and v4.0 change logs):
Windows Metafile Support
~~~~~~~~~~~~~~~~~~~~~~~~
You can now set the text of an image to the content of a EMF or WMF file on Windows. This is a direct analog of PICT support on Mac OS X. Note that images which have EMF or WMF data within them will only render on Windows.
So if you're using v3 or later and this isn't working, please file a bug report on it.
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

ale870
Posts: 250
Joined: Tue Apr 22, 2008 9:17 am
Contact:

Post by ale870 » Wed Nov 18, 2009 9:09 am

Hello @FourthWorld, wnf format is used only for export (like creating a pdf file as a printer). In fact, every OS has a specific proprietary format (see docs).
They are used only to render output, not as some functions to manage the format (create, modify, show on screen, etc...).

I think a program like RunRev should definitively contain a library to manage a standard vectorial format like ps, or svg (cross-platform philosophy).

malte
Posts: 1098
Joined: Thu Feb 23, 2006 8:34 pm
Contact:

Post by malte » Wed Nov 18, 2009 9:40 am

You might want to take a look at the SVGL stack by IAn Mcphail you will find on revOnline.

Cheers,

malte

hliljegren
Posts: 111
Joined: Sun Aug 23, 2009 7:48 am
Contact:

Post by hliljegren » Wed Nov 18, 2009 7:41 pm

Wouldn't it be possible to use the HTML viewer to view several formats??? (I.e. If you can show your file in an ordinary web browser you should be able to "view" it in a stack)

Post Reply