ScatterCollection#

ScatterCollection#

Constructor#

ScatterCollection(data, *[, colors, cmap, ...])

Create a collection of graphics of the same type.

Properties#

ScatterCollection.alpha

The opacity of the graphic

ScatterCollection.alpha_mode

How the alpha is handled by the renderer

ScatterCollection.alpha_modes

get or set the alpha_modes of the graphics in the collection

ScatterCollection.alphas

get or set the alphas of the graphics in the collection

ScatterCollection.axes

ScatterCollection.block_events

Used to block events for a graphic and prevent recursion.

ScatterCollection.block_handlers

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

ScatterCollection.cmap

get or set the colormap(s) across the collection

ScatterCollection.cmap_range

get or set the cmap_range of the graphics in the collection

ScatterCollection.cmap_transform

get or set the cmap_transform across the collection

ScatterCollection.colors

get or set the colors of the graphics in the collection

ScatterCollection.data

get or set the data of the graphics in the collection

ScatterCollection.deleted

used to emit an event after the graphic is deleted

ScatterCollection.edge_colors

get or set the edge_colors of the graphics in the collection

ScatterCollection.edge_width

get or set the edge_width of the graphics in the collection

ScatterCollection.event_handlers

Registered event handlers.

ScatterCollection.graphics

the graphics in the collection

ScatterCollection.image

get or set the image of the graphics in the collection

ScatterCollection.imgui_right_click

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

ScatterCollection.markers

get or set the markers of the graphics in the collection

ScatterCollection.metadatas

get or set the metadatas of the graphics in the collection

ScatterCollection.name

Graphic name

ScatterCollection.names

get or set the names of the graphics in the collection

ScatterCollection.offset

[x, y, z]

ScatterCollection.offsets

get or set the offsets of the graphics in the collection

ScatterCollection.point_rotations

get or set the point_rotations of the graphics in the collection

ScatterCollection.rotation

Orientation of the graphic as a quaternion

ScatterCollection.rotations

get or set the rotations of the graphics in the collection

ScatterCollection.scale

(x, y, z) scaling factor

ScatterCollection.scales

get or set the scales of the graphics in the collection

ScatterCollection.size_space

get or set the size_space of the graphics in the collection

ScatterCollection.sizes

get or set the sizes of the graphics in the collection

ScatterCollection.supported_events

events supported by this graphic

ScatterCollection.tooltip_format

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

ScatterCollection.visible

Whether the graphic is visible

ScatterCollection.visibles

get or set the visibles of the graphics in the collection

ScatterCollection.world_object

Associated pygfx WorldObject.

Methods#

ScatterCollection.add_axes()

Add axes onto this Graphic

ScatterCollection.add_event_handler(*args)

Register an event handler.

ScatterCollection.add_graphic(graphic)

Add a graphic to the collection.

ScatterCollection.add_linear_region_selector([...])

Add a LinearRegionSelector.

ScatterCollection.add_linear_selector([...])

Add a LinearSelector.

ScatterCollection.add_polygon_selector([...])

Add a PolygonSelector.

ScatterCollection.add_rectangle_selector([...])

Add a RectangleSelector.

ScatterCollection.append_imgui_right_click([gui])

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

ScatterCollection.clear_event_handlers()

clear all event handlers added to this graphic

ScatterCollection.format_pick_info(ev)

Takes a pygfx.PointerEvent and returns formatted pick info.

ScatterCollection.map_model_to_world(position)

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

ScatterCollection.map_world_to_model(position)

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

ScatterCollection.remove_event_handler(...)

remove a registered event handler

ScatterCollection.remove_graphic(graphic)

Remove a graphic from the collection.

ScatterCollection.remove_imgui_right_click(popup)

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

ScatterCollection.rotate(alpha[, axis])

Rotate the Graphic with respect to the world.

ScatterCollection.set_imgui_right_click([...])

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