Skip to content

Commit a4fd264

Browse files
committed
bindings for quantity picking
1 parent 3d04605 commit a4fd264

3 files changed

Lines changed: 4 additions & 1 deletion

File tree

src/cpp/core.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -225,6 +225,7 @@ PYBIND11_MODULE(polyscope_bindings, m) {
225225
.def_readonly("structure_handle", &ps::PickResult::structureHandle)
226226
.def_readonly("structure_type", &ps::PickResult::structureType)
227227
.def_readonly("structure_name", &ps::PickResult::structureName)
228+
.def_readonly("quantity_name", &ps::PickResult::quantityName)
228229
.def_readonly("screen_coords", &ps::PickResult::screenCoords)
229230
.def_readonly("buffer_inds", &ps::PickResult::bufferInds)
230231
.def_readonly("position", &ps::PickResult::position)

src/polyscope/core.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -363,6 +363,7 @@ def __init__(self, bound_pick_result):
363363
self.is_hit = bound_pick_result.is_hit
364364
self.structure_type_name = bound_pick_result.structure_type
365365
self.structure_name = bound_pick_result.structure_name
366+
self.quantity_name = bound_pick_result.quantity_name
366367
self.screen_coords = bound_pick_result.screen_coords.as_tuple()
367368
self.buffer_inds = bound_pick_result.buffer_inds.as_tuple()
368369
self.position = np.array(bound_pick_result.position.as_tuple())
@@ -399,6 +400,7 @@ def __str__(self):
399400
is_hit={self.is_hit},
400401
structure_type_name={self.structure_type_name},
401402
structure_name={self.structure_name},
403+
quantity_name={self.quantity_name},
402404
screen_coords={self.screen_coords},
403405
buffer_inds={self.buffer_inds},
404406
position={self.position},

0 commit comments

Comments
 (0)