Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

how to render label faster #5892

Open
lqyp0420 opened this issue Apr 9, 2024 · 0 comments
Open

how to render label faster #5892

lqyp0420 opened this issue Apr 9, 2024 · 0 comments
Labels
feature-request Please add this cool feature!

Comments

@lqyp0420
Copy link

lqyp0420 commented Apr 9, 2024

Describe the feature you would like to be added.

after I used add_point_labels to add 2000 points label to then scene, I pad the scene not smooth. I test add_point_labels used time:0.1s, how can i render quickly? thank u

Links to VTK Documentation, Examples, or Class Definitions.

No response

Pseudocode or Screenshots

        self.mesh = pv.read(fname, file_format='abaqus')
        self.plotter.add_text(fname, 'upper_edge', font_size=10)
        self.mesh['z'] = 20 * np.log10(abs(self.mesh.points[:, 1]) + self.mesh.points[:, 0]**2)
        self.mesh.points[:, 2] = 0
        self.plotter.add_mesh(self.mesh, scalars='z', show_edges=True, lighting=True, show_scalar_bar=False,
                              cmap='viridis')
        actor = self.plotter.add_point_labels(self.mesh.points, list(range(self.mesh.points.shape[0])),
                                              text_color='blue', bold=False, font_size=20, point_size=30,
                                              show_points=False,
                                              shape_color='white', fill_shape=False, shape_opacity=0,
                                              point_color='red', render_points_as_spheres=True, pickable=True,
                                              tolerance=0.1,
                                              always_visible=True, )

Or drag your screenshot here!

@lqyp0420 lqyp0420 added the feature-request Please add this cool feature! label Apr 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature-request Please add this cool feature!
Projects
None yet
Development

No branches or pull requests

1 participant