summaryrefslogtreecommitdiffstats
path: root/media
Commit message (Collapse)AuthorAgeFilesLines
* Implement VideoDecoder IPC hooks from plugin to GPU processvrk@google.com2011-05-134-34/+44
| | | | | | | | | | | | | This implements the communciation layers from the Renderer process to the GPU process and back for the AcceleratedVideoDecoder PPAPI interfaces. BUG=NONE TEST=NONE Review URL: http://codereview.chromium.org/6876004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@85296 0039d316-1c4b-4281-b951-d872f2087c98
* Convert Filter::Seek() to use new callback system.acolwell@chromium.org2011-05-1333-221/+422
| | | | | | | | | BUG=82167 TEST=none. Existing tests still pass. Review URL: http://codereview.chromium.org/6969026 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@85279 0039d316-1c4b-4281-b951-d872f2087c98
* Reland 85013 - Split GLContext::Create*GLContext into ↵apatrick@chromium.org2011-05-121-3/+5
| | | | | | | | | | | | GLSurface::Create*GLSurface plus a surface type independent GLContext::CreateGLContext TEST=try, including layout tests BUG=none Review URL: http://codereview.chromium.org/7013037 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@85207 0039d316-1c4b-4281-b951-d872f2087c98
* Revert "Reland 85013 - Split GLContext::Create*GLContext into ↵antonm@chromium.org2011-05-121-5/+3
| | | | | | | | | GLSurface::Create*GLSurface plus a surface type independent GLContext::CreateGLContext". git-svn-id: svn://svn.chromium.org/chrome/trunk/src@85124 0039d316-1c4b-4281-b951-d872f2087c98
* iwyu: Include stringprintf.h where appropriate, part 3.jhawkins@chromium.org2011-05-122-5/+5
| | | | | | | | | | | BUG=82098 TEST=none R=csilv@chromium.org Review URL: http://codereview.chromium.org/7016011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@85088 0039d316-1c4b-4281-b951-d872f2087c98
* Reland 85013 - Split GLContext::Create*GLContext into ↵apatrick@chromium.org2011-05-121-3/+5
| | | | | | | | | | | GLSurface::Create*GLSurface plus a surface type independent GLContext::CreateGLContext. TEST=webgl on windows and mac, trybots BUG=none Review URL: http://codereview.chromium.org/6997003 Review URL: http://codereview.chromium.org/7015016 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@85081 0039d316-1c4b-4281-b951-d872f2087c98
* Convert Demuxer::Read() to use the new callback system.acolwell@chromium.org2011-05-1113-45/+40
| | | | | | | | | BUG=82167 TEST=Existing unit tests still pass. Review URL: http://codereview.chromium.org/7004006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@85029 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 85013 - Split GLContext::Create*GLContext into ↵apatrick@chromium.org2011-05-111-5/+3
| | | | | | | | | | | | | GLSurface::Create*GLSurface plus a surface type independent GLContext::CreateGLContext. TEST=webgl on windows and mac, trybots BUG=none Review URL: http://codereview.chromium.org/6997003 TBR=apatrick@chromium.org Review URL: http://codereview.chromium.org/7015003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@85016 0039d316-1c4b-4281-b951-d872f2087c98
* Split GLContext::Create*GLContext into GLSurface::Create*GLSurface plus a ↵apatrick@chromium.org2011-05-111-3/+5
| | | | | | | | | | surface type independent GLContext::CreateGLContext. TEST=webgl on windows and mac, trybots BUG=none Review URL: http://codereview.chromium.org/6997003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@85013 0039d316-1c4b-4281-b951-d872f2087c98
* revert CL 84847wjia@google.com2011-05-101-3/+6
| | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/7005013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@84883 0039d316-1c4b-4281-b951-d872f2087c98
* Update VideoDecode PPAPI structs to be consistent with media structures, part 1vrk@google.com2011-05-105-270/+159
| | | | | | | | | | | | | | This patch fixes some of the inconsistencies between the VideoDecode structs in the ppapi namespace and their wrappers in the media namespace. It also implements some of the hooks to pass messages to and from the browser and plugin. BUG=NONE TEST=NONE Review URL: http://codereview.chromium.org/6901036 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@84871 0039d316-1c4b-4281-b951-d872f2087c98
* Adding a new file for media stream types that will be used by future Chrome ↵wjia@google.com2011-05-101-5/+3
| | | | | | | | changes to support video capture devices and the media stream api. Review URL: http://codereview.chromium.org/6980019 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@84847 0039d316-1c4b-4281-b951-d872f2087c98
* Fix crashes that occur during building & stopping the AdaptiveDemuxer.acolwell@chromium.org2011-05-102-29/+73
| | | | | | | | | BUG=78730 TEST=none Review URL: http://codereview.chromium.org/6975006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@84789 0039d316-1c4b-4281-b951-d872f2087c98
* iwyu: Include stringprintf.h where appropriate, part 1.jhawkins@chromium.org2011-05-101-2/+3
| | | | | | | | | | | BUG=82098 TEST=none R=thakis@chromium.org Review URL: http://codereview.chromium.org/6997006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@84754 0039d316-1c4b-4281-b951-d872f2087c98
* iwyu: Use callback_old.h where appropriate, part 1.jhawkins@chromium.org2011-05-107-6/+7
| | | | | | | | | | | BUG=none TEST=none R=thakis@chromium.org Review URL: http://codereview.chromium.org/6985009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@84725 0039d316-1c4b-4281-b951-d872f2087c98
* add MessageLoopProxy in MessageLoopFactorywjia@google.com2011-05-073-0/+37
| | | | | | | | bug=None TEST=try bots Review URL: http://codereview.chromium.org/6951013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@84540 0039d316-1c4b-4281-b951-d872f2087c98
* add video capture message filter and its unit test.wjia@google.com2011-05-063-24/+42
| | | | | | | | BUG=none TEST=try bots Review URL: http://codereview.chromium.org/6903018 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@84489 0039d316-1c4b-4281-b951-d872f2087c98
* Linux hardware dependent code for Video Capture.scherkus@chromium.org2011-05-046-0/+799
| | | | | | | | | | | | | | This includes header files for the abstract base classes necessary for lower level parts necessary for video capturing in Chromium as well as an implementation of these classes on Linux. This patch is the first in a series necessary for implementing video capture in the browser process. Tested on Linux. This patch also includes a fake implementation of VideoCaptureDevice to be used with unittests for testing Video Capture classes. Patch by perkl@google.com: http://codereview.chromium.org/6878013/ BUG=none TEST=none git-svn-id: svn://svn.chromium.org/chrome/trunk/src@84148 0039d316-1c4b-4281-b951-d872f2087c98
* Forward decoder errors from FFmpegVideoDecodeEngine to FFmpegVideoDecoder.scherkus@chromium.org2011-04-298-32/+113
| | | | | | | | | | | Previously they were getting dropped on the floor, which could leave the media pipeline in lame duck mode. BUG=80187 TEST=media_unittests Review URL: http://codereview.chromium.org/6899058 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@83577 0039d316-1c4b-4281-b951-d872f2087c98
* Updating logging in src/media/. Using DCHECK_EQ/NE/LE() where possible.kushi.p@gmail.com2011-04-296-10/+10
| | | | | | | | | BUG=58409 TEST=None Review URL: http://codereview.chromium.org/6893032 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@83557 0039d316-1c4b-4281-b951-d872f2087c98
* Make buffer_queue_ and read_queue_ from DemuxerStream shared resources.fgalligan@chromium.org2011-04-292-4/+43
| | | | | | | | | | | | Added lock calls around buffer_queue_, read_queue_, and stopped_ in demuxer stream. This is so the Read call will not block if the DemuxTask is blocked and the buffer queue is not empty. BUG=75483 TEST=Play a live WebM stream and make sure the AV sync is good and the video plays back smoothly. Review URL: http://codereview.chromium.org/6879035 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@83552 0039d316-1c4b-4281-b951-d872f2087c98
* Base: Adjust dependencies to build with base.dllrvargas@google.com2011-04-281-0/+1
| | | | | | | | BUG=76996 TEST=none Review URL: http://codereview.chromium.org/6883205 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@83269 0039d316-1c4b-4281-b951-d872f2087c98
* Switch VideoDecoder over to the new hot callbacks.scherkus@chromium.org2011-04-276-22/+35
| | | | | | | | | BUG=none TEST=media_unittests, compiles, etc. Review URL: http://codereview.chromium.org/6905071 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@83240 0039d316-1c4b-4281-b951-d872f2087c98
* Rename VideoCodecConfig to VideoDecoderConfig and move to ↵scherkus@chromium.org2011-04-2717-88/+105
| | | | | | | | | | | media/base/video_decoder_config.{cc,h}. BUG=none TEST=compiles Review URL: http://codereview.chromium.org/6905065 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@83226 0039d316-1c4b-4281-b951-d872f2087c98
* Forgot to include media/base/audio_decoder_config.h in media/media.gyp.scherkus@chromium.org2011-04-271-0/+1
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@83187 0039d316-1c4b-4281-b951-d872f2087c98
* Switch AudioDecoder's ConsumeAudioSamplesCallback over to the new hotness ↵scherkus@chromium.org2011-04-279-69/+50
| | | | | | | | | | | | | callbacks. They are indeed hot. BUG=none TEST=media_unittests, unit_tests, etc... Review URL: http://codereview.chromium.org/6893014 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@83184 0039d316-1c4b-4281-b951-d872f2087c98
* Refactor PTS processing logic from FFmpegVideoDecoder::FindPtsAndDuration() ↵scherkus@chromium.org2011-04-2711-184/+325
| | | | | | | | | | | | | | | | | | | | | | | | into PtsStream. This simplifies its reuse in other video decoders. An instance of this class is added to OmxVideoDecoder filter. The PTS processing is mostly left intact. The only difference is addition of PtsStream::Seek() method, which resets the current PTS. Without this method seeking brakes AV synchronization if the video decoder relies on last known PTS and frame rate to calculate timestamps for decoded frames. Patch by ostrovsm@gmail.com: http://codereview.chromium.org/6902032/ BUG=none TEST=The easiest way I found to reproduce the problem is to use an .avi file. It doesn't happen all the time but sometimes AVI demuxer reports invalid timestamps for video packets, and the decoder heavily relies on the PTS estimation logic (last PTS + frame rate). A sample file that triggers the behavior can be downloaded from [1]. The FFmpeg library has to be reconfigured to support MPEG4 decoding and AVI demuxing. Also to simplify the experiment "video/x-msvideo" has to be added to the list of supported media types in net/base/mime_util.cc. [1] http://www.dvdloc8.com/clip.php?movieid=284&clipid=1 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@83180 0039d316-1c4b-4281-b951-d872f2087c98
* Replace AudioDecoder::media_format() with AudioDecoderConfig.scherkus@chromium.org2011-04-2616-95/+136
| | | | | | | | | | | Also includes some cleanup for AudioParameter users including a new helper method GetBytesPerSecond(). BUG=28206 TEST=media_unittests, test_shell_tests, etc... Review URL: http://codereview.chromium.org/6903007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@83098 0039d316-1c4b-4281-b951-d872f2087c98
* Base: Adjust dependencies to build with base.dllrvargas@google.com2011-04-261-0/+2
| | | | | | | | BUG=76996 TEST=none Review URL: http://codereview.chromium.org/6894040 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@83082 0039d316-1c4b-4281-b951-d872f2087c98
* Blind fix for a Linux only crash in AudioManager::Destroythestig@chromium.org2011-04-221-4/+6
| | | | | | | | BUG=80059 TEST=none Review URL: http://codereview.chromium.org/6878081 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@82612 0039d316-1c4b-4281-b951-d872f2087c98
* Open ALSA device using hw_params callsdavej@chromium.org2011-04-192-4/+72
| | | | | | | | | | | Replaced using ALSA snd_pcm_set_params() with separate snd_pcm_hw_X() calls in order to use snd_pcm_hw_params_set_rate_near() which allows for setting rates on some devices that don't normally allow some rates like 22050Hz. BUG=chromium-os:13231, chromium-os:13721 TEST=Manual, 22khz audio should play (test file in bug) Review URL: http://codereview.chromium.org/6869037 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@82042 0039d316-1c4b-4281-b951-d872f2087c98
* Allow audio output on Linux to work with web audio APIcrogers@google.com2011-04-161-2/+3
| | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/6871030 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@81843 0039d316-1c4b-4281-b951-d872f2087c98
* Fix erratic HTML5 audio playbackdavej@chromium.org2011-04-144-21/+77
| | | | | | | | | | | | | | | This was affecting all platforms. The major issue was that he SetPlaybackRate(1) which is used to start playback was being done in the middle of the series of Seek operations. So doing Seek() followed by SetPlaybackRate(1) was done, the Seek could immediately stop the playback. To fix, Seek() was made atomic with regards to SetPlaybackRate() by delaying the execution of SetPlaybackRate until after the Seek sequence has completely finished. To make things run even smoother, a short delay was added before recyclilng a used audio stream in the Dispatcher. This gives the stream time to 'power down' before being reused. Tested on Linux, Chrome-OS (Cr48) and Mac with great results, making HTML5 audio much more usable for games. BUG=73045,59369,59370,65618 TEST=Manual, Quickly playing/stopping HTML5 audio should play cleanly. Review URL: http://codereview.chromium.org/6822019 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@81670 0039d316-1c4b-4281-b951-d872f2087c98
* Fix Linux audio playbackdavej@chromium.org2011-04-142-2/+26
| | | | | | | | | | | | | Playing audio files shorter than about 11000 samples on Linux was either not working at all, or re-playing (starting and stopping on the same audio object) was working only intermittently. It was possible to stop audio playback before the first buffer was played, resulting in no sound at all. Also, if replaying, the buffer may have been dirty from the previous playback on the same device. So on Linux at least, these issues appear fixed. BUG=73045,47761,59367,59369,59370,65618 TEST=Manual, quickly playing short audio files on Linux should work Review URL: http://codereview.chromium.org/6776024 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@81669 0039d316-1c4b-4281-b951-d872f2087c98
* Draft version of the HW video decode tester and few other changes.scherkus@chromium.org2011-04-145-4/+386
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Intention is that this tester can be used to decouple HW decode accelerator integration from running the whole Chrome browser. Features: - Independent GUnit executable, which should be possible to use in autotests. - Mimics Renderer process from Gpu video pipeline perspective. * Test bench contains implementation of FakeClient which essentially mimics Renderer process from the GpuVideoDecodeAccelerator's point of view. * FakeClient runs on it's own thread and will communicate with using the IPC messages that are used also within the real use case. * FakeClient will allocate memories using same SharedMemory stuff as the real Renderer code. * Currently reads H.264 Annex B bitstream from file and parses it to NAL units before feeding to the decoder * TODO: Polish and improving the features and configurability. * TODO: GLES texture allocation for textures. - Allows building various test cases and error behaviour as well both on AcceleratedVideoDecoder interface as well as erroneous behaviour from the client. - Allows also checking expected order of calls if we want to enforce certain behaviour across various implementations. Patch by vmr@chromium.org: http://codereview.chromium.org/6720040/ BUG=none TEST=none git-svn-id: svn://svn.chromium.org/chrome/trunk/src@81663 0039d316-1c4b-4281-b951-d872f2087c98
* Implements AudioInputDevice API for low-latency audio input in the browser ↵scherkus@chromium.org2011-04-124-13/+85
| | | | | | | | | | | | | | process. Also refactors some shared audio code into audio_common.{cc,h}. Patch by henrika@chromim.org: http://codereview.chromium.org/6250196/ BUG=none TEST=none git-svn-id: svn://svn.chromium.org/chrome/trunk/src@81315 0039d316-1c4b-4281-b951-d872f2087c98
* Include base/win/scoped_comptr.h instead of base/scoped_comptr_win.h.tfarina@chromium.org2011-04-124-35/+36
| | | | | | | | | | | | | | | | | Fix up all the callers to use the new location and namespace. Also, delete the stub file since it isn't included by anyone more. (Note: This was a TODO for brettw). BUG=None TEST=None R=brettw@chromium.org Review URL: http://codereview.chromium.org/6825055 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@81303 0039d316-1c4b-4281-b951-d872f2087c98
* Add IPC messages and renderer process side API for video capture. wjia@google.com2011-04-123-1/+121
| | | | | | | | BUG=none TEST=try bots Review URL: http://codereview.chromium.org/6815011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@81199 0039d316-1c4b-4281-b951-d872f2087c98
* Remove svn:mergeinfo props from many files.pkasting@chromium.org2011-04-082-2/+2
| | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/6814027 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@80878 0039d316-1c4b-4281-b951-d872f2087c98
* Make the windows_version.h functions threadsafe by using a singleton. Add ↵pkasting@chromium.org2011-04-072-2/+4
| | | | | | | | | | | | accessors to the singleton for more values that various code wants, then convert almost everyone using OSVERSIONINFO or SYSTEM_INFO structs to calling these accessors. Declare an AtExitManager in the out-of-process test runner since it didn't have one and that breaks singleton-using code in the test executable (as opposed to in chrome.dll). A few other minor cleanups along the way (binding of "*", shorter code, etc.). Because I ran into problems with it while modifying gcapi.cc, I cleaned up our usage of strsafe.h a bit, so that files that don't need it don't include it and files that do use STRSAFE_NO_DEPRECATE instead of a modified #include order. BUG=none TEST=none Review URL: http://codereview.chromium.org/6816027 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@80851 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 80819 due to failed testsmmenke@chromium.org2011-04-072-4/+2
| | | | | | | TBR=pkasting@chromium.org Review URL: http://codereview.chromium.org/6816024 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@80824 0039d316-1c4b-4281-b951-d872f2087c98
* Make the windows_version.h functions threadsafe by using a singleton. Add ↵pkasting@chromium.org2011-04-072-2/+4
| | | | | | | | | | | | accessors to the singleton for more values that various code wants, then convert almost everyone using OSVERSIONINFO or SYSTEM_INFO structs to calling these accessors. Declare an AtExitManager in the out-of-process test runner since it didn't have one and that breaks singleton-using code in the test executable (as opposed to in chrome.dll). A few other minor cleanups along the way (binding of "*", shorter code, etc.). Because I ran into problems with it while modifying gcapi.cc, I cleaned up our usage of strsafe.h a bit, so that files that don't need it don't include it and files that do use STRSAFE_NO_DEPRECATE instead of a modified #include order. BUG=none TEST=none Review URL: http://codereview.chromium.org/6713107 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@80819 0039d316-1c4b-4281-b951-d872f2087c98
* Fix valgrind messages for uninitialized preload_ value.vrk@google.com2011-04-052-1/+2
| | | | | | | | | | | | | The preload_ field was uninitialized when PipelineImpl was constructed, so PipelineImpl unit tests failed Valgrind tests. CL 80465 introduced the problem. BUG=NONE TEST=NONE TBR=acolwell Review URL: http://codereview.chromium.org/6720052 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@80503 0039d316-1c4b-4281-b951-d872f2087c98
* Implementing preload=metadata for videovrk@google.com2011-04-0511-5/+85
| | | | | | | | | | | | | This patch implements the logic necessary to respect the preload attribute when it is set to MetaData. This also refactors the BufferedResourceLoader to determine its buffering techniques based on a DeferStrategy value. BUG=16482,76555 TEST=media/video-preload.html, test_shell_tests Review URL: http://codereview.chromium.org/6625059 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@80465 0039d316-1c4b-4281-b951-d872f2087c98
* Fix an uninitialized variable compiler warning on some systems.mdm@chromium.org2011-04-031-1/+1
| | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/6677123 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@80279 0039d316-1c4b-4281-b951-d872f2087c98
* Fix samplefmt.h inclusion with newer ffmpegscherkus@chromium.org2011-04-011-1/+0
| | | | | | | | | | | | libavcore is defunct in upstream ffmpeg. Patch by floppymaster@gmail.com: http://codereview.chromium.org/6791004/ BUG=77795 TEST=Build with recent ffmpeg (use_system_ffmpeg=1) git-svn-id: svn://svn.chromium.org/chrome/trunk/src@80200 0039d316-1c4b-4281-b951-d872f2087c98
* Mac platform was not treating 8bit PCM audio as unsigned data.sjl@google.com2011-04-011-4/+15
| | | | | | | | | | | If bits per channel is 8, open the stream as unsigned and use 128 as the silence value. BUG=70730 TEST=media_unittests and manual testing of a bunch of audio files (8 bit and others). Review URL: http://codereview.chromium.org/6689003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@80181 0039d316-1c4b-4281-b951-d872f2087c98
* Fix some style issues in media/video/ffmpeg_video_allocator.{cc,h}.scherkus@chromium.org2011-04-012-14/+16
| | | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/6771037 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@80174 0039d316-1c4b-4281-b951-d872f2087c98
* Create helper methods to process FFmpeg index data.acolwell@chromium.org2011-04-0110-15/+313
| | | | | | | | | BUG=none TEST=FFmpegCommonTest Review URL: http://codereview.chromium.org/6708130 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@80153 0039d316-1c4b-4281-b951-d872f2087c98
* Initialize stderr logging for player_x11 so we can use --v=N.scherkus@chromium.org2011-03-301-0/+7
| | | | | | | | | BUG=none TEST=build player_x11, start it with --v=1 Review URL: http://codereview.chromium.org/6776002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@79889 0039d316-1c4b-4281-b951-d872f2087c98