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

PLOTTING: color alignment with service(Discovery,SpaceClaim) #433

Open
RobPasMue opened this issue Mar 2, 2023 · 4 comments
Open

PLOTTING: color alignment with service(Discovery,SpaceClaim) #433

RobPasMue opened this issue Mar 2, 2023 · 4 comments

Comments

@RobPasMue
Copy link
Member

As part of the JSON information, whenever it is send back, we also get information on the color of each body/component. We should make use of it when plotting.

@RobPasMue RobPasMue changed the title Implement color allignment with serviec (Discovery,SpaceClaim) Implement color allignment with service(Discovery,SpaceClaim) Mar 2, 2023
@RobPasMue RobPasMue changed the title Implement color allignment with service(Discovery,SpaceClaim) Implement color alignment with service(Discovery,SpaceClaim) Mar 2, 2023
@jonahrb
Copy link
Contributor

jonahrb commented May 24, 2023

Not sure this is possible with out current pyvista setup... Colors are usually assigned to actors, and pygeom only ever has 1 actor - the top level design component. Either have to iterate through multiblocks in that one actor, or use multiple actors if we want to implement this color-syncing. Lmk if you see something different.

@jonahrb
Copy link
Contributor

jonahrb commented May 24, 2023

We made a soft decision to implement this by having multiple actors - either at the component level or body level. Color can be passed from SC API using DesignBody.GetColor(). Probably best to pass this color in the Tessellation message.

@jonahrb
Copy link
Contributor

jonahrb commented May 24, 2023

Having multiple actors also allows us to have cheaper transform operations. You could now do something like actor.user_matrix = self.get_world_transform() instead of transforming the PolyData tessellation. Hopefully speeds up plotting significantly.

@jonahrb
Copy link
Contributor

jonahrb commented May 24, 2023

DesignBody.GetColor() is not exposed on linux yet, so this would be a windows-only feature.

@RobPasMue RobPasMue changed the title Implement color alignment with service(Discovery,SpaceClaim) PLOTTING: color alignment with service(Discovery,SpaceClaim) Sep 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants