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

Don't generate a frame when no scene is built. #2541

Merged
merged 1 commit into from Mar 19, 2018
Merged
Changes from all commits
Commits
File filter...
Filter file types
Jump to…
Jump to file
Failed to load files.

Always

Just for now

Don't generate a frame when no scene is built.

  • Loading branch information
nical committed Mar 19, 2018
commit 4aa439a5a4e750ddbb01efd4cd726ecef607b8f5
@@ -963,14 +963,6 @@ impl RenderBackend {

let doc = self.documents.get_mut(&document_id).unwrap();

if !doc.can_render() {
// TODO: this happens if we are building the first scene asynchronously and
// scroll at the same time. we should keep track of the fact that we skipped
// composition here and do it as soon as we receive the scene.
op.render = false;
op.composite = false;
}

if transaction_msg.generate_frame {
if let Some(ref mut ros) = doc.render_on_scroll {
*ros = true;
@@ -982,6 +974,14 @@ impl RenderBackend {
}
}

if !doc.can_render() {
// TODO: this happens if we are building the first scene asynchronously and
// scroll at the same time. we should keep track of the fact that we skipped
// composition here and do it as soon as we receive the scene.
op.render = false;
op.composite = false;
}

debug_assert!(op.render || !op.composite);

if op.render {
ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.