BlitManager

class sofia_redux.visualization.display.blitting.BlitManager(canvas: FigureCanvasAgg, gallery: Gallery, signals)[source]

Bases: object

Manage drawing for background and animated artists.

Parameters:
canvasFigureCanvasAgg

The canvas to work with, this only works for sub-classes of the Agg canvas which have the copy_from_bbox and restore_region methods.

gallerysofia_redux.visualization.display.artist.Gallery

Gallery instance that tracks all artists to draw.

signalssofia_redux.visualization.signals.Signals

Collection of PyQt signals for passing on information to other parts of the Eye.

Attributes:
draw_cidint

The matplotlib event CID for the draw_event signal.

Methods Summary

blit()

Blit the canvas.

reset_background()

Reset the canvas background.

safe_draw()

Draw the canvas.

update_all([event])

Update the background and artists.

update_animated()

Update all animated artists.

update_background()

Update the canvas background.

Methods Documentation

blit() None[source]

Blit the canvas.

Restore the background without updating it, then update the animated artists on top of the restored background.

reset_background() None[source]

Reset the canvas background.

safe_draw() None[source]

Draw the canvas.

Disconnect the draw event signal before drawing, and reconnect it afterward.

update_all(event=None) None[source]

Update the background and artists.

update_animated() None[source]

Update all animated artists.

update_background() None[source]

Update the canvas background.