Layer question

Use this forum to post questions about using LXFree and other LXSeries software for OS-X.
Post Reply
lanternz
Posts: 198
Joined: Mon Feb 04, 2008 10:59 am
Location: Adelaide

Layer question

Post by lanternz »

I have a drawing with 5 different layers of set plans on it for the 5 different scenes in an opera I am doing. My usual procedure is to scale the CAD plan at 1:50 in Vectorworks and then simply copy and paste into a layer in LxBeams (latest version). This gives me detailed and very accurate plans that I can switch on or off as I need. However the file size becomes comparatively large (11.5MB) but more to the point scrolling the plan becomes slow even on my current model fastest processor Retina Pro. Is there a better way to set up the layers? And why is importing the plan better than copy and paste?
Lanternz
admin
Site Admin
Posts: 1643
Joined: Mon Nov 05, 2007 1:26 am
Contact:

Post by admin »

The answer to your question most likely has to do with the format that Vectorworks uses when it places graphics on the system pasteboard. But, imported graphics has been a focus area of LXBeams 4.0. Perhaps some information about this and why it came about might help you figure out what is going on.

Recently two things prompted a look at how the display of imported graphics could be improved. First, I wanted to use a large PDF of an architectural drawing produced from AutoCAD for the basis of a plot I was working on. This was a large, complex drawing and importing the PDF slowed down working with the plot. Opening the PDF in Preview.app had similarly slow screen re-draw times. So, it was obvious that it was the complexity and detail of the drawing that was slowing things down.

To solve this, I opened the PDF in preview and exported it as a PNG file, which I imported into LXBeams. This improved screen re-draw speed immensely. Not too long after this, I got an inquiry from someone working on a major motion picture who wanted to import a PDF, also large, detailed and from an architectural drawing produced by the film's art department into their plot for the studio setup. To help with this issue, I described my process for converting the file to speed up screen re-draw when working in LXBeams (which solved the problem). But, this got me thinking that LXBeams could do the same thing automatically.

In the latest build of LXBeams, there is now an option in the view menu called "Faster PDF Display". What this function does when enabled is to temporarily create a bitmap copy of imported PDF graphics to use when re-drawing the screen. The original PDF is preserved and saved with the file. The bitmap is created in RAM and requires more memory for the application. But, with most computers having gigabytes of RAM available these days, this is not a performance issue unless there are a lot of memory hungry applications open and being switched in and out. In that case, performance could slow because of increased virtual memory use. But, taken by itself, the extra memory is not a drawback. Using the faster drawing method does cause the imported graphic to appear pixellated as you zoom in. So, it takes more memory and the display has reduced quality (at magnification) using Faster PDF Drawing. What you get for this tradeoff is that the screen re-draw is much much faster. Without Faster PDF Drawing, and one of these large complex graphics, you would scroll the screen and have to wait for it to re-draw. With Faster PDF drawing, the screen scrolls without delay, making your actual working on the plot much easier.

Faster PDF drawing is an automated way of converting a PDF to a bitmap before importing it. But, because the original PDF is preserved and stored, it can still be used for printing and export. So, although using Faster PDF Drawing reduces the screen quality at magnification, there is no reduction in printed quality. Or, if you export a PDF of the plot, the full quality of the original is maintained.

Faster PDF Drawing only works with graphics that are imported in PDF format. There are many other graphics formats that you can import, JPEG, PNG, TIFF, etc. These are all bitmap formats and are not likely to benefit in terms of re-draw speed from being converted into another bitmap. This would just take more memory.

I don't know if any of this information helps you figure out how to best deal with your multiple layers. In terms of file size, I can tell you that by default LXBeams stores imported bitmap type graphics in uncompressed form in .lxplot binary files. This means if you are importing an image say from your iPhone's camera, the file size can become quite large even when the original picture file is much smaller. This is because the picture is stored in the highly compressed JPEG format. There is a preference option that greatly reduces the size of LXBeams .lxplot files that include imported bitmap graphics. This is found under File/XML and is called "Use JPEG compression for LXPlot bitmap images. This compresses all imported images into JPEG format when they are stored and can greatly reduce file size. The default .lxxplot XML based format can use either PNG or JPEG to store imported graphics. The thing to consider about JPEG is that it does not support transparency like PNG. So, if it is important that your imported graphic be transparent in parts, you would want not to store it as JPG.
lanternz
Posts: 198
Joined: Mon Feb 04, 2008 10:59 am
Location: Adelaide

Post by lanternz »

I seem to be able to copy and paste from Vectorworks to LxBeams with no problems - does this make the file inherently bigger or does it have the same operational function as "import"?
Lanternz
admin
Site Admin
Posts: 1643
Joined: Mon Nov 05, 2007 1:26 am
Contact:

Post by admin »

The same data will use up the same memory in an LXSeries document whether it is imported from a file or pasted from the pasteboard.

The format of the data does have an impact on how much memory it uses. An application may export graphics in a number of formats either as files or via copy. When you export a file you have a notion of its content because of the file's extension. An application may place data on the clipboard in a number of formats and it is hard to tell without examining it programmatically what the actual format is. When you copy selected graphics with LXBeams or with Preview.app's rectangular selection tool, data is placed on the clipboard as PDF. Other applications may do things differently.

In general PDF format is composed of vector type graphics. Other formats such as JPG or PNG are bitmaps. But, PDF also supports internal bitmaps. So, that's not an absolute.

A simple vector graphic often uses less memory to store than the bit map that is created when it is rasterized. But, its possible that a complex PDF will actually take more memory as vector objects than rasterized into a bitmap. So, its not necessarily a valid generalization that vector graphics or PDF takes less memory than a bitmap. But, with relatively simple graphics, it will be true.

As far as quality goes, it is often preferable to use vector graphics because they are not tied to a fixed resolution. That means you can print or zoom in and the graphics will still render smooth rather than becoming pixellated.

You can probably tell what type of graphics are being imported or pasted by zooming in and seeing if the lines remain smooth. You can do this with Preview.app's New from Clipboard command or LXBeams. If you use LXBeams, keep in mind that for the latest build you need to turn off Faster PDF Drawing to see this on the screen.
Post Reply