Skip to content

Commit 9a3d169

Browse files
authored
Get one shape transform (#446)
1 parent 022a65a commit 9a3d169

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/spatialdata_plot/pl/render.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ def _render_shapes(
185185
sdata_filt.shapes[element].loc[is_point, "geometry"] = _geometry[is_point].buffer(scale.to_numpy())
186186

187187
# apply transformations to the individual points
188-
element_trans = get_transformation(sdata_filt.shapes[element])
188+
element_trans = get_transformation(sdata_filt.shapes[element], to_coordinate_system=coordinate_system)
189189
tm = _get_transformation_matrix_for_datashader(element_trans)
190190
transformed_element = sdata_filt.shapes[element].transform(
191191
lambda x: (np.hstack([x, np.ones((x.shape[0], 1))]) @ tm)[:, :2]
@@ -195,7 +195,7 @@ def _render_shapes(
195195
)
196196

197197
plot_width, plot_height, x_ext, y_ext, factor = _get_extent_and_range_for_datashader_canvas(
198-
transformed_element, coordinate_system, ax, fig_params
198+
transformed_element, "global", ax, fig_params
199199
)
200200

201201
cvs = ds.Canvas(plot_width=plot_width, plot_height=plot_height, x_range=x_ext, y_range=y_ext)

0 commit comments

Comments
 (0)