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

noticeable lag between buffer spawn and fill color application #144

Open
databasedav opened this issue Jun 1, 2024 · 4 comments
Open

noticeable lag between buffer spawn and fill color application #144

databasedav opened this issue Jun 1, 2024 · 4 comments

Comments

@databasedav
Copy link
Contributor

databasedav commented Jun 1, 2024

repro by adding fill_color: CosmicBackgroundColor(Color::DARK_GRAY) to the basic_ui example, the window flashes from white to grey, even in release mode

i'd like to address this but need some guidance, how can i synchronize the spawn and the fill?

@Dimchikkk
Copy link
Owner

Ping @bytemunch :)

@databasedav
Copy link
Contributor Author

simply calling buffer.draw after construction of the CosmicEditBundle does not seem to suffice

@Dimchikkk
Copy link
Owner

Dimchikkk commented Jun 3, 2024

@databasedav trying to reproduce the issue... basically I added:

image

no noticeable lag even in debug mode (I am on M1 Pro)

@bytemunch
Copy link
Collaborator

I can reproduce, got a white flash on setting fill_color to both DARK_GRAY and NONE, so can assume it breaks on all fill colors.

Will be an issue somewhere in the instantiation of the target sprite, I think it has a frame of blank before it's drawn to.
May be able to fix by removing the funky sprite making and swapping steps, there's probably a much more ergonomic way of adding the target sprite to the entity.

2024-06-05_090131.mp4

White flash with fill_color set, 3x in a row

Looks like it's more than one frame, maybe two or three.

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

3 participants