Tracing image storage

Hi,

  1. I wonder if it is possible to link to tracing image (RhinoViewport.SetTraceImage) instead of storing it in the rhino file.
    I use many named views with tracing images and the file becomes really large.
    (And I need the option to have each image visible in its own viewport. So, no picture nor background option)

  2. Even if I remove the named views and purge, the file keeps its large size.
    If it is not possible to link file, is there a way to purge tracaing images ?

Regards.

Hi @lahos, have you tried RhinoViewport.ClearTraceImage() ? You might also try to SaveAs and uncheck the “Save textures” checkbox.

_
c.

Once namedviews are deleted (from ui) is there any handle to it to call ClearTraceImage ?

Hi @Lahos, i guess if you cannot access the view by finding it in the named views table, there is no way to call ClearTraceImage() as it requires a RhinoViewport.

@dale: Imho if a user had set a trace image and deleted the (named) viewport, it should also purge the trace image from the file after saving. Or is this then part of the file’s bitmap table and remains ?

_
c.

So, if nothing could be done for the moment, I propose 2 options in the near future:

  • have an option to link or embed the tracing file in a named view.
  • have the ClearTraceImage getting rid of the embedded bitmap.

The link option has the advantage of keeping the 3dm ligthweight and let the user
manage the quality of his images. Cause the way I see the 3dm file getting larger,
I assume it stores it in a way there is no noticeable compression loss.
24 named views with jpgs of 5.5 mb (5312 x 2988) gives me a 250 mb file.
Maybe it is due to consecutives add/delete named views not being purged.

Hi @lahos,

I believe the bitmap is not deleted automatically because there is no way of knowing if it’s being used somewhere else.

If you know the full path to the bitmap, then you can remove it by calling BitmapTable.DeleteBitmap.

– Dale

thanks. I’ll try it.