PDA

View Full Version : Text Input and complex Vector Graphics


bgx
10-15-2004, 12:50 PM
Hi,

I built an application that loads technical drawings and allows users to add information into TextInput fields or Text Areas.

I noticed that if those drawings are very complex (detailed machine drawings converted from CAD) the text input becomes VERY slow. It takes several seconds (up to 20 I experienced) for the text to display after you hit a key.

What puzzles me is that there is no animation or blending or similar involved, the graphics are already drawn. It is also enough to simply set the MC that holds the graphics to _visible =false to speed up the text input.

Questions:
- Does anybody know how to prevent textinput to be slow without hiding the graphic
- If not, is there a way to detect the complexity of vector graphics? Filesize is no indicator.

CyanBlue
10-17-2004, 06:51 AM
Howdy and Welcome... :)

Well... Can you tell us how youa re reading the technical drawing file and actually drawing the image within the Flash??? We can start from there, I think... :)

bgx
10-17-2004, 09:43 AM
Attached is a zip file with an example of such a drawing ("drawing.swf") and another swf ("slow.swf") that loads the drawing into an MC using loadMovie (I haved used various other methods like the Loader component, but that makes no difference).

I found out by now that it is a general text input problem, therefore this example does not contain the Text Input component but a simple editable TextField.

Further there is a button that sets the mc containing the drawing to _visible = true or false. Notice the difference in keyboard input.

The drawing itself was opened as DXF file in Freehand and exported as SWF.

There seems a direct relation to the complexity of the drawing and the delay in keyboard input. With simpler drawings no such delay happens.

farafiro
10-17-2004, 12:39 PM
this very strange
have you tried to save it as jpg and then load it into your file??

bgx
10-17-2004, 08:22 PM
JPEGs are fine, but they are no option. One of the key features of the product is that you can zoom right down to the smallest bolt and still see everything clearly. Also print quality is key.

I hoped somebody had similar experiences. At the moment I see if the conversion from DXF to SWF can in some way be optimized

CyanBlue
10-17-2004, 09:01 PM
Well... Obviously there is no code in your slow.fla file, so I guess it is a matter of the complexity of your drawing.swf file...
How do you create that file??? Does AutoCAD have that sort of functionality built in??? Or do you use some sort of third party program to do the conversion??? Maybe there is some option that you can customize how complex the output should be or if you can hide the points that are not actually visible or something???

bgx
10-17-2004, 09:12 PM
Hi CyanBlue, here again how it was done:


The drawing itself was opened as DXF file in Freehand and exported as SWF.


And yes I will see if there are ways to reduce complexity

farafiro
10-18-2004, 08:25 AM
hmmmmmmm
okey, here is what you want
jpg it and then swf it with the [url=http://www.zoomify.com/]Zoomifier[/as]