OLD | NEW |
---|---|
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 <dlfcn.h> | 5 #include <dlfcn.h> |
6 #include <errno.h> | 6 #include <errno.h> |
7 #include <fcntl.h> | 7 #include <fcntl.h> |
8 #include <linux/videodev2.h> | 8 #include <linux/videodev2.h> |
9 #include <poll.h> | 9 #include <poll.h> |
10 #include <sys/eventfd.h> | 10 #include <sys/eventfd.h> |
(...skipping 397 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
408 | 408 |
409 child_message_loop_proxy_->PostTask(FROM_HERE, base::Bind( | 409 child_message_loop_proxy_->PostTask(FROM_HERE, base::Bind( |
410 &Client::NotifyInitializeDone, client_)); | 410 &Client::NotifyInitializeDone, client_)); |
411 return true; | 411 return true; |
412 } | 412 } |
413 | 413 |
414 void ExynosVideoDecodeAccelerator::Decode( | 414 void ExynosVideoDecodeAccelerator::Decode( |
415 const media::BitstreamBuffer& bitstream_buffer) { | 415 const media::BitstreamBuffer& bitstream_buffer) { |
416 DVLOG(1) << "Decode(): input_id=" << bitstream_buffer.id() | 416 DVLOG(1) << "Decode(): input_id=" << bitstream_buffer.id() |
417 << ", size=" << bitstream_buffer.size(); | 417 << ", size=" << bitstream_buffer.size(); |
418 DCHECK(child_message_loop_proxy_->BelongsToCurrentThread()); | 418 DCHECK(!child_message_loop_proxy_->BelongsToCurrentThread()); |
Ami GONE FROM CHROMIUM
2013/08/22 14:52:03
Better to affirmatively check being on IO thread.
| |
419 | 419 |
420 scoped_ptr<BitstreamBufferRef> bitstream_record(new BitstreamBufferRef( | 420 scoped_ptr<BitstreamBufferRef> bitstream_record(new BitstreamBufferRef( |
421 client_, child_message_loop_proxy_, | 421 client_, child_message_loop_proxy_, |
422 new base::SharedMemory(bitstream_buffer.handle(), true), | 422 new base::SharedMemory(bitstream_buffer.handle(), true), |
423 bitstream_buffer.size(), bitstream_buffer.id())); | 423 bitstream_buffer.size(), bitstream_buffer.id())); |
424 if (!bitstream_record->shm->Map(bitstream_buffer.size())) { | 424 if (!bitstream_record->shm->Map(bitstream_buffer.size())) { |
425 DLOG(ERROR) << "Decode(): could not map bitstream_buffer"; | 425 DLOG(ERROR) << "Decode(): could not map bitstream_buffer"; |
426 NOTIFY_ERROR(UNREADABLE_INPUT); | 426 NOTIFY_ERROR(UNREADABLE_INPUT); |
427 return; | 427 return; |
428 } | 428 } |
(...skipping 2014 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2443 DestroyGscOutputBuffers(); | 2443 DestroyGscOutputBuffers(); |
2444 DestroyMfcOutputBuffers(); | 2444 DestroyMfcOutputBuffers(); |
2445 | 2445 |
2446 // Finish resolution change on decoder thread. | 2446 // Finish resolution change on decoder thread. |
2447 decoder_thread_.message_loop()->PostTask(FROM_HERE, base::Bind( | 2447 decoder_thread_.message_loop()->PostTask(FROM_HERE, base::Bind( |
2448 &ExynosVideoDecodeAccelerator::FinishResolutionChange, | 2448 &ExynosVideoDecodeAccelerator::FinishResolutionChange, |
2449 base::Unretained(this))); | 2449 base::Unretained(this))); |
2450 } | 2450 } |
2451 | 2451 |
2452 } // namespace content | 2452 } // namespace content |
OLD | NEW |