ImageCollection#

ImageCollection#

Constructor#

ImageCollection(data, *[, vmin, vmax, cmap, ...])

Create a collection of graphics of the same type.

Properties#

ImageCollection.alpha

The opacity of the graphic

ImageCollection.alpha_mode

How the alpha is handled by the renderer

ImageCollection.alpha_modes

get or set the alpha_modes of the graphics in the collection

ImageCollection.alphas

get or set the alphas of the graphics in the collection

ImageCollection.axes

ImageCollection.block_events

Used to block events for a graphic and prevent recursion.

ImageCollection.block_handlers

Used to block event handlers for a graphic and prevent recursion.

ImageCollection.cmap

get or set the cmap of the graphics in the collection

ImageCollection.cmap_interpolation

get or set the cmap_interpolation of the graphics in the collection

ImageCollection.data

get or set the data of the graphics in the collection

ImageCollection.deleted

used to emit an event after the graphic is deleted

ImageCollection.event_handlers

Registered event handlers.

ImageCollection.gamma

get or set the gamma of the graphics in the collection

ImageCollection.graphics

the graphics in the collection

ImageCollection.imgui_right_click

The imgui popup of each graphic of this collection, in order.

ImageCollection.interpolation

get or set the interpolation of the graphics in the collection

ImageCollection.legend_item

The legend item of this graphic, created with create_legend_item().

ImageCollection.metadatas

get or set the metadatas of the graphics in the collection

ImageCollection.name

Graphic name

ImageCollection.names

get or set the names of the graphics in the collection

ImageCollection.offset

[x, y, z]

ImageCollection.offsets

get or set the offsets of the graphics in the collection

ImageCollection.rotation

Orientation of the graphic as a quaternion

ImageCollection.rotations

get or set the rotations of the graphics in the collection

ImageCollection.scale

(x, y, z) scaling factor

ImageCollection.scales

get or set the scales of the graphics in the collection

ImageCollection.supported_events

events supported by this graphic

ImageCollection.tooltip_format

set a custom tooltip format function which takes a pick_info dict and returns a str to be displayed in the tooltip

ImageCollection.visible

Whether the graphic is visible

ImageCollection.visibles

get or set the visibles of the graphics in the collection

ImageCollection.vmax

get or set the vmax of the graphics in the collection

ImageCollection.vmin

get or set the vmin of the graphics in the collection

ImageCollection.world_object

Associated pygfx WorldObject.

Methods#

ImageCollection.add_axes()

Add axes onto this Graphic

ImageCollection.add_event_handler(*args)

Register an event handler.

ImageCollection.add_graphic(graphic)

Add a graphic to the collection.

ImageCollection.append_imgui_right_click([gui])

Append imgui elements to the popup of every graphic of this collection.

ImageCollection.clear_event_handlers()

clear all event handlers added to this graphic

ImageCollection.format_pick_info(ev)

Takes a pygfx.PointerEvent and returns formatted pick info.

ImageCollection.map_model_to_world(position)

map position from model (data) space to world space, basically applies the world affine transform

ImageCollection.map_world_to_model(position)

map position from world space to model (data) space, basically applies the inverse world affine transform

ImageCollection.remove_event_handler(...)

remove a registered event handler

ImageCollection.remove_graphic(graphic)

Remove a graphic from the collection.

ImageCollection.remove_imgui_right_click(popup)

Remove popup from every graphic of this collection that has it set.

ImageCollection.rotate(alpha[, axis])

Rotate the Graphic with respect to the world.

ImageCollection.set_imgui_right_click([...])

Set the imgui popup opened by a right-click on any graphic of this collection.