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

Submit transaction with frame output enabled before transaction with … #2952

Merged
merged 1 commit into from Aug 7, 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

@@ -68,17 +68,6 @@ impl App {
) {
// Generate the external image key that will be used to render the output document to the root document.
self.external_image_key = Some(api.generate_image_key());
let mut txn = Transaction::new();
txn.add_image(
self.external_image_key.unwrap(),
ImageDescriptor::new(100, 100, ImageFormat::BGRA8, true, false),
ImageData::External(ExternalImageData {
id: ExternalImageId(0),
channel_index: 0,
image_type: ExternalImageType::TextureHandle(TextureTarget::Default),
}),
None,
);

let pipeline_id = PipelineId(1, 0);
let layer = 1;
@@ -93,6 +82,25 @@ impl App {
color,
};

let mut txn = Transaction::new();

txn.enable_frame_output(document.pipeline_id, true);

api.send_transaction(document.id, txn);

let mut txn = Transaction::new();

txn.add_image(
self.external_image_key.unwrap(),
ImageDescriptor::new(100, 100, ImageFormat::BGRA8, true, false),
ImageData::External(ExternalImageData {
id: ExternalImageId(0),
channel_index: 0,
image_type: ExternalImageType::TextureHandle(TextureTarget::Default),
}),
None,
);

let info = LayoutPrimitiveInfo::new(document.content_rect);
let mut builder = DisplayListBuilder::new(
document.pipeline_id,
@@ -112,7 +120,6 @@ impl App {
builder.pop_stacking_context();

txn.set_root_pipeline(pipeline_id);
txn.enable_frame_output(document.pipeline_id, true);
txn.set_display_list(
Epoch(0),
Some(document.color),
ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.