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

ShapeBase.delete scenarios clarification #1104

Merged
merged 1 commit into from May 10, 2024

Conversation

matanox
Copy link
Contributor

@matanox matanox commented May 9, 2024

tentatively avoids the self-referencing description and provides more direct clarity (?) to ShapeBase.delete()

@matanox
Copy link
Contributor Author

matanox commented May 9, 2024

Obviously not any great contribution

@benmoran56 benmoran56 merged commit 823f220 into pyglet:master May 10, 2024
16 checks passed
@benmoran56
Copy link
Member

Thanks for the PR. Documentation fixes/clarifications are always helpful.

@matanox
Copy link
Contributor Author

matanox commented May 11, 2024

Would it make sense to add a delete method to pyglet.graphics.Batch, deleting all included Shape objects and freeing all other video resources of the batch, extending deletion one level higher in the hierarchy of abstraction?

@benmoran56
Copy link
Member

It would be possible, but doesn't account for the Python objects.
If you make a bunch of Sprites/Labels/etc. that are added to a Batch, and then delete that Batch, the Python objects remain.

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

Successfully merging this pull request may close these issues.

None yet

2 participants