Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "content/common/gpu/media/fake_video_decode_accelerator.h" | 5 #include "content/common/gpu/media/fake_video_decode_accelerator.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 #include <string.h> | 8 #include <string.h> |
| 9 | 9 |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| (...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 170 if (flushing_ && queued_bitstream_ids_.empty()) { | 170 if (flushing_ && queued_bitstream_ids_.empty()) { |
| 171 flushing_ = false; | 171 flushing_ = false; |
| 172 client_->NotifyFlushDone(); | 172 client_->NotifyFlushDone(); |
| 173 } | 173 } |
| 174 while (!free_output_buffers_.empty() && !queued_bitstream_ids_.empty()) { | 174 while (!free_output_buffers_.empty() && !queued_bitstream_ids_.empty()) { |
| 175 int bitstream_id = queued_bitstream_ids_.front(); | 175 int bitstream_id = queued_bitstream_ids_.front(); |
| 176 queued_bitstream_ids_.pop(); | 176 queued_bitstream_ids_.pop(); |
| 177 int buffer_id = free_output_buffers_.front(); | 177 int buffer_id = free_output_buffers_.front(); |
| 178 free_output_buffers_.pop(); | 178 free_output_buffers_.pop(); |
| 179 | 179 |
| 180 const media::Picture picture = | 180 const media::Picture picture = media::Picture( |
| 181 media::Picture(buffer_id, | 181 buffer_id, bitstream_id, gfx::Rect(frame_buffer_size_), false); |
|
liberato (no reviews please)
2016/03/09 15:32:06
perhaps remove this file from the CL.
chcunningham
2016/03/09 20:25:09
Done.
| |
| 182 bitstream_id, | |
| 183 gfx::Rect(frame_buffer_size_), | |
| 184 false); | |
| 185 client_->PictureReady(picture); | 182 client_->PictureReady(picture); |
| 186 // Bitstream no longer needed. | 183 // Bitstream no longer needed. |
| 187 client_->NotifyEndOfBitstreamBuffer(bitstream_id); | 184 client_->NotifyEndOfBitstreamBuffer(bitstream_id); |
| 188 if (flushing_ && queued_bitstream_ids_.empty()) { | 185 if (flushing_ && queued_bitstream_ids_.empty()) { |
| 189 flushing_ = false; | 186 flushing_ = false; |
| 190 client_->NotifyFlushDone(); | 187 client_->NotifyFlushDone(); |
| 191 } | 188 } |
| 192 } | 189 } |
| 193 } | 190 } |
| 194 | 191 |
| 195 } // namespace content | 192 } // namespace content |
| OLD | NEW |