SkethchUp write_image method
-
Does anyone know how to calculate time which SU will take writing an image knowing the future file size in MB?
-
Too many variables.
How would you for instance determine a harddrive's interface speed, and whether the write cache is on?
If you want worstcase, then you could use old PATA speed of 33Mb/s, but most newer computers will have PATA of 100Mb/s. If the computer is late model, and has a SATA drive, the speeds can be up in the 3 .. 6 Gb/s range.
So.. the easiest way would be to have the user fill in a WebDialog form for this info.
They you would multiply width x height in pixels, by say 24bits each to get a approximate size for the image (if a BMP,) then divide by the interface speed.
Estimating compressed format sizes (like GIF and JPEG,) will be much harder, but you might be able find some equations out on the web. (Then of course, there is extra processing time for the image to be compressed.)
Sketchup uses PaintLib, an Open Source library. Perhaps there are some speed data on the PaintLib author's website?
Advertisement