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

Add log message on app gain/loss of focus and when unpausing application #1780

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from

Conversation

marius-pelegrin-arm
Copy link
Contributor

It makes more sense to have messages for both when the application is paused and unpaused than only when paused.
In addition, in the context of an automated process, it is useful to be able to differentiate, only with the logs, an application that was paused because of a manual input to an application paused because of a lose of focus.

This commit adds these log messages

@ci-tester-lunarg
Copy link

CI gfxreconstruct build queued with queue ID 269472.

@ci-tester-lunarg
Copy link

CI gfxreconstruct build # 4940 running.

@ci-tester-lunarg
Copy link

CI gfxreconstruct build # 4940 passed.

@ci-tester-lunarg
Copy link

CI gfxreconstruct build queued with queue ID 273399.

@ci-tester-lunarg
Copy link

CI gfxreconstruct build # 4969 running.

@ci-tester-lunarg
Copy link

CI gfxreconstruct build # 4969 passed.

@bradgrantham-lunarg
Copy link
Contributor

This doesn't appear to work like I'd expect. The pause and resume messages are out of order. Here's the result from our job 4940, before my commit to your branch:

10-02 07:51:32.388  4998  5031 I gfxrecon: Unpaused from frame 0
10-02 07:51:32.446  4998  5031 I gfxrecon: Paused at frame 0

{
uint32_t current_frame = file_processor_->GetCurrentFrameNumber();
if (current_frame > 0)
if (paused_)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it possible this should be paused? paused_ (with underscore) is the previous value of the pause, so this would invert the messages, I think.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, this is a mistake on my side, I will fix that =)

@bradgrantham-lunarg
Copy link
Contributor

Although I have not paused or resumed replay, I get the messages that playback has been paused and resumed, because the logic no longer checks the frame number. Before this change, there were no extraneous messages about pausing. Can that behavior be restored?

@bradgrantham-lunarg bradgrantham-lunarg added P2 A high-priority code maintenance issue or a functional problem that is recoverable or not a crash. replay Issue with replay (capture was successful) android labels Oct 7, 2024
@marius-pelegrin-arm
Copy link
Contributor Author

The idea of this commit was to explicitly tell the user that the application starts paused and resume only when it gains focus - because in some cases the app doesn't get the focus, then the replay doesn't start and it seems like a bug of GFXReconstruct when it is in fact a bug of the environment. So we would like to keep messages about what happens at frame 0.

Change-Id: I3fd493a6cb8520a9ec69078b62f8be31287c8355
@ci-tester-lunarg
Copy link

CI gfxreconstruct build queued with queue ID 273627.

@ci-tester-lunarg
Copy link

CI gfxreconstruct build # 4974 running.

@ci-tester-lunarg
Copy link

CI gfxreconstruct build # 4974 passed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
android P2 A high-priority code maintenance issue or a functional problem that is recoverable or not a crash. replay Issue with replay (capture was successful)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants