summaryrefslogtreecommitdiffstats
path: root/media/libstagefright/include
Commit message (Collapse)AuthorAgeFilesLines
* stagefright: Fix seeking in MPEG4 container - do not mergeLajos Molnar2014-07-221-1/+9
| | | | | | | | | - seek based on user-visible timestamp - seek to previous, next and closest exactly - also update OggExtractor seek to same logic Bug: 12786906 Change-Id: I2d5e1fbff6469b6f081a284be2222a4cb50aa754
* Update OMX messages for 64 bitAndy Hung2014-06-122-2/+15
| | | | | | | | | Change node_id and buffer_id to uint32_t. Ensure IOMX messages are fixed size. Remove 64 bit compile warnings in associated files. Change-Id: Icdbef00aca575e5dc502ebb52e3ce7d0d7883203 Signed-off-by: Andy Hung <hunga@google.com>
* Smooth out AwesomePlayerLajos Molnar2014-05-011-0/+3
| | | | | | Use clock estimator to smooth out audio time stamps. Change-Id: Iec1ff30c011069d06ff8051fc4839d00895463d6
* warnings be gone.Andreas Huber2014-04-111-1/+1
| | | | | | | | (cherry picked from commit 84333e0475bc911adc16417f4ca327c975cf6c36) Modified by Mark Salyzyn <salyzyn@google.com> to keep merge conflicts or errors downstream to a minimum. Change-Id: Ic3b272f9cbf3155001aabd2f79728f1bc31de613
* Merge "ChromiumHTTPDataSource: Keep track of the redirected URL"Lajos Molnar2014-02-101-0/+1
|\
| * ChromiumHTTPDataSource: Keep track of the redirected URLMartin Storsjo2013-11-251-0/+1
| | | | | | | | | | | | | | | | This makes the code actually match an existing comment in DrmInitialization, which claimed that mURI was the redirected URL and not the original one. Change-Id: I0a5cc65f520f1482ff91320ae78af84a8a681ee3
* | Added support for ID3v2 meta data in 3gp filesOscar Rydhé2014-01-162-2/+3
| | | | | | | | | | | | | | | | Added support for parsing ID3v2 meta data from the ID32 chunk in 3gp files. The priority will be 3gpp -> ID3v2 -> iTunes per field. Change-Id: I0282ecab58e3e5fa6bd738078d562c8bb8ce00ed
* | libstagefright: Delay release of wakelock in TimedEventQueueHaynes Mathew George2013-12-171-1/+1
| | | | | | | | | | | | | | | | | | | | | | Delay release of wakelock in the TimedEventQueue to after an event has been processed. This ensures AP shutdown does not happen while an event is ready but hasn't been processed yet. Bug: 11976087. Change-Id: I71a5f3ac4a57e1d05dd5d9ab5c6f91ed7bb64c87
* | am a7291156: Merge "TimedEventQueue: improve wakelock management" into klp-devEric Laurent2013-11-101-1/+3
|\ \ | |/ |/| | | | | * commit 'a72911563b0e5b21b196d40249b53975bf8d8f85': TimedEventQueue: improve wakelock management
| * TimedEventQueue: improve wakelock managementEric Laurent2013-11-071-1/+3
| | | | | | | | | | | | | | | | | | Do not acquire a wakelock unless the event is delayed by more than a given time. This prevents from acquiring/releasing wakelocks too often which has adverse effects on performance. Bug: 11509471. Change-Id: Id06803b393b40c4db5095a6e7ec02339fa581a38
* | am da0926af: Merge "TimedEventQueue takes a wake lock" into klp-devEric Laurent2013-10-041-0/+25
|\ \ | |/ | | | | | | * commit 'da0926afdb12794497c93d68eee296f2d92bfa7e': TimedEventQueue takes a wake lock
| * TimedEventQueue takes a wake lockEric Laurent2013-10-041-0/+25
| | | | | | | | | | | | | | | | | | Take a wake lock when events present in a TimedEventQueue to prevent from going idle before all delayed events are processed. Bug: 11057387. Change-Id: I26a17df68068fde5e879a2fe7568dec439fc540f
* | am 56ce7260: IOMX: Add prepareForAdaptivePlayback methodLajos Molnar2013-10-032-0/+8
|\ \ | |/ | | | | | | * commit '56ce726019f700a95ce5b45beebceadae4836e30': IOMX: Add prepareForAdaptivePlayback method
| * IOMX: Add prepareForAdaptivePlayback methodLajos Molnar2013-10-032-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | prepareForAdaptivePlayback is the fallback mechanism to support seamless resolution change for devices that do not support dynamic output buffers. It is up to the codecs to handle this appropriately, but codecs that do not handle dynamic output buffers would request enough buffers up to the requested size in this method to avoid port reconfiguration on resolution changes. Change-Id: I58d4aa8ef1359ea3472735bbe9140c3132039b3d Signed-off-by: Lajos Molnar <lajos@google.com> Bug: 10192531 Related-to-bug: 7093648
* | am 3d97e23f: Merge "Prevent onPrepared callback from being called twice" ↵Marco Nelissen2013-09-301-0/+2
|\ \ | |/ | | | | | | | | | | into klp-dev * commit '3d97e23fcd78f752443cb6c30a1ee39f49f1f987': Prevent onPrepared callback from being called twice
| * Prevent onPrepared callback from being called twiceMarco Nelissen2013-09-271-0/+2
| | | | | | | | | | | | b/10891995 Change-Id: If6845c832d114629282f0b03f904a37c3325208e
* | am ff58698e: am f36ae7ca: Merge "Added support for 3GPP meta data atoms"Marco Nelissen2013-08-191-1/+2
|\ \ | |/ |/| | | | | * commit 'ff58698ec7e0f32bf9f3e1758173fe170e17270c': Added support for 3GPP meta data atoms
| * Added support for 3GPP meta data atomsOscar Rydhé2013-08-131-1/+2
| | | | | | | | | | | | | | 3GPP metadata is not supported, only iTunes Metadata Format is supported. Change-Id: I78b41c88788d5a43800c936e0ac0f98424515c62
* | Add MEDIA_STARTED/PAUSED/STOPPED events to media playersLajos Molnar2013-08-151-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | This is needed for the MediaTimeProvider java interface, so it does not continually poll for current media time. Note: NuPlayer and AwesomePlayer do not correctly handle stop (pause instead), so for those we will signal PAUSED. Signed-off-by: Lajos Molnar <lajos@google.com> Change-Id: I3c61e1bda475f131323f475c18a42e3ec66c9ae1 Bug: 10326117
* | IOMX: add updateGraphicBufferInMeta method for metadata modeLajos Molnar2013-08-062-0/+8
| | | | | | | | | | | | | | | | | | This is used to set the handle in the metadata buffer that is valid in the mediaserver process, as well as to keep a reference for the graphic buffers in BufferMeta. Change-Id: I46bb68d8bed894f357eeeb25368360d11b276634 Signed-off-by: Lajos Molnar <lajos@google.com>
* | stagefright: offload playback supportRichard Fitzgerald2013-07-261-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Offloading of compressed audio decoding to audio DSP is implemented for audio only, non streamed content. when the datasource is AudioPlayer: - Create an offloaded sink when playing a compressed source - Send metadata to audio HAL - Return sink start error to AwesomePlayer so that a new player for PCM audio can be created in case of problem. - Forward stream end and tear down callback events to AwesomePlayer - Stop the sink and wait for stream end callback when EOS is reached. - Pause and restart the sink if needed before flushing when seeking (otherwise flush is a no op). - For current media time, directly query the render position from the sink and offset by the start position (seek to time) AwesomePlayer: - When initializing the audio decoder, check with audio policy manager if offloading is supported. If yes, create the software decoder in case a reconfiguration is needed but connect the audio track directly to the AudioPlayer. - In case of error when starting the AudioPlayer, reconnect the software decoder (OMXSource) and recreate a PCM AudioPlayer. - Handle AudioPlayer tear down event by detroying and recreating the AudioPlayer to allow transitions between situations were offloading is supported or not. - Force tear down of offloaded AudioPlayer when paused for a certain time: This will close the sink and allow the DSP to power down. Utils: - Added helper methods: - send meta data to audio ia sink setParameters - query audio policy manager if offloading is supported for a given audio content Change-Id: I115842ce424f947b966d45e253a74d3fd5df9aae Signed-off-by: Eric Laurent <elaurent@google.com>
* | Merge "Add routing sockets for the requesting user"Geremy Condra2013-07-231-0/+3
|\ \
| * | Add routing sockets for the requesting userChad Brubaker2013-07-191-0/+3
| | | | | | | | | | | | | | | | | | | | | Mediaserver sockets are now routed as if the connection was in the requesting app in per user routing. Change-Id: I60f4649c3c4145a65264b54c1aa2c6c7741efaba
* | | Support "suspension" of a video encoder in "surface-input" mode.Andreas Huber2013-07-172-0/+13
|/ / | | | | | | | | | | i.e. feed no more input frames to the encoder while suspended. Change-Id: I51391e18c1517548e869f8ddece19f4af37e78f9
* | Public API changes for audio offload support.Richard Fitzgerald2013-06-272-2/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | NOTE: this does _not_ include all private member variables added to classes as part of offload support. Only public/protected functions and stubs functions/variables needed to make the changes buildable. - isOffloadSupported() added to audio policy service A stub implementation is required to build, this always returns false - setParameters() added to IAudioTrack A stub implementation is required to build, this always returns INVALID_OPERATION - CBlk flag for stream end - Change AudioSystem::getRenderPosition() to take an audio_output_t so caller can specify which output to query - Add AudioSystem::isOffloadSupported() This is fully implemented down to the AudioFlinger function AudioPolicyServer::isOffloadSupported() which is just a stub that always returns false. - Add EVENT_STREAM_END to AudioTrack interface. STREAM_END is used to signal when the hardware has actually finished playing all the data it was sent. - Add event type enumeration to media player interface AudioSink callbacks so that the same callback can be used to handle multiple types of event. For offloaded tracks we also have to handle STREAM_END and TEAR_DOWN events - Pass audio_offload_info_t to various functions used for opening outputs, tracks and audio players. This passes additional information about the compressed stream down to the HAL when using offload. For publicly-available APIs this is an optional parameter (for some of the internal and low-level APIs around the HAL interface it is mandatory) - Add getParameters() and setParameters() API to AudioTrack Currently dummy implementations. - Change AudioPlayer contructor so that it takes a set of bitflags defining what options are required. This replaces the original bool which only specified whether to use deep buffering. - Changes to StageFright class definition related to handling tearing-down of an offloaded track when we need to switch back to software decode - Define new StageFright utility functions used for offloaded tracks Currently dummy implementations. - AudioFlinger changes to use extended audio_config_t. Fills in audio_offload_info_t member if this info is passed in when opening an output. - libvideoeditor changes required to add the new event type parameter to AudioSink callback functions - libmediaplayerservice changes required to add the new event type parameter to AudioSink callback functions Change-Id: I3ab41138aa1083d81fe83b886a9b1021ec7320f1 Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Signed-off-by: Eric Laurent <elaurent@google.com>
* | stagefright: created SoftVideoDecoderOMXComponentLajos Molnar2013-06-051-0/+93
| | | | | | | | | | | | | | | | Created common base class for all software video decoders to make adding new features easier. Change-Id: Id89964e572d5cc5add02662273e6ae96c6b7eb12 Signed-off-by: Lajos Molnar <lajos@google.com>
* | am f9bb8358: am b7319a7e: Update HTTP proxy configuration for all media ↵Andreas Huber2013-06-033-0/+10
|\ \ | |/ | | | | | | | | | | playback inside stagefright. * commit 'f9bb8358e454be6dc88403171db7e0e182407f17': Update HTTP proxy configuration for all media playback inside stagefright.
| * Update HTTP proxy configuration for all media playback inside stagefright.Andreas Huber2013-05-313-0/+10
| | | | | | | | | | | | Change-Id: Ie0dd00045aba668d8b49da73224e7a7c9c04f69b related-to-bug: 8873723 (cherry picked from commit 2704965b8a1ff3b7450ff58ccecf86d8ec688c40)
| * Add support for common encryptionMarco Nelissen2013-04-081-0/+7
| | | | | | | | | | | | b/7465749 Change-Id: I5403b74a5ae428ad28b382863a09daafc400b137
| * Implement Surface input to MediaCodec.Andy McFadden2013-03-042-0/+30
| | | | | | | | | | | | | | | | | | Also, renamed a CHECK_INTERFACE macro that was clashing with the Binder version. Bug 7991062 Change-Id: If5e6ed0a06d9f67975497676e4b05abe3aa3d6c0
| * Remove FragmentedMP4ExtractorMarco Nelissen2013-02-151-70/+0
| | | | | | | | | | | | MPEG4Extractor now supports fragmented mp4 files. Change-Id: I5659a51f4e5e4407a12535e69238fe3abffda7dc
| * Add support for fragmented mp4 to MPEG4ExtractorMarco Nelissen2013-02-151-0/+18
| | | | | | | | | | | | | | This makes FragmentedMP4Extractor obsolete. It will be removed in a separate change. Change-Id: Ida74c07ccf84983e20a1320ee24ffc7a5c083859
| * HLS now properly publishes its "seekable" flags after connectionAndreas Huber2013-02-061-1/+14
| | | | | | | | | | | | | | has successfully completed and a sufficient amount of data fetched, and only then signals that preparation is completed. Change-Id: I7684a14238b826909f518f2af506966e522dfcfc
| * Added HTTP support for SDP files.Oscar Rydhé2013-02-051-0/+70
| | | | | | | | | | | | | | | | | | | | Added support for playing SDP files from http links. Previously, SDP files only worked when started from rtsp links (rtsp://a.b.c/abc.sdp), but they are just as common in http links. patch provided by "Oscar Rydhé <oscar.rydhe@sonyericsson.com>" Change-Id: Ic73af3a9a002009dbe8b04c267a4621bf7fe2f46
| * Merge "Rename ISurfaceTexture and SurfaceTexture"Andy McFadden2012-12-181-2/+2
| |\
| | * Rename ISurfaceTexture and SurfaceTextureAndy McFadden2012-12-181-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The C++ class names don't match what the classes do, so rename ISurfaceTexture to IGraphicBufferProducer, and SurfaceTexture to GLConsumer. Bug 7736700 Change-Id: I64520a55f8c09fe6215382ea361c539a9940cba5
| * | Make codecs reconfigurableMarco Nelissen2012-12-181-0/+1
| |/ | | | | | | Change-Id: I3dd46cb4401493becbf6152f4dcd5a8f1e9a0b44
| * Respect sample aspect ratio in NuPlayer.Andreas Huber2012-12-051-1/+4
| | | | | | | | | | related-to-bug: 7569402 Change-Id: I302de95d83b180bd2dc72ddd0c69a665dbce2527
| * am ce8dcdf5: am 031c93df: Merge "Bug fix for the MediaPlayer::prepare() api."Marco Nelissen2012-11-291-1/+1
| |\ | | | | | | | | | | | | * commit 'ce8dcdf5361dd5de8c86cf5b0308c71d519f98ca': Bug fix for the MediaPlayer::prepare() api.
| | * am 031c93df: Merge "Bug fix for the MediaPlayer::prepare() api."Marco Nelissen2012-11-291-1/+1
| | |\ | | | | | | | | | | | | | | | | * commit '031c93df74621dc2149876dc377aedee8930547f': Bug fix for the MediaPlayer::prepare() api.
| | | * Bug fix for the MediaPlayer::prepare() api.Dylan Powers2012-11-271-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For an MP3 source, within the prepare command, ID3 tags are checked in search of gapless playback info. This causes problems for streamed sources. If ID3v2 tags aren't present, then a check is done for ID3v1 tags. This results in a read command that asks the cache to jump to the end of the file, and subsequently make an extra http call to request those bytes. For a streamed source, this causes the file to not be downloaded automatically when MediaPlayer::prepare() is called, and causes stuttering and extra buffering time to be needed when start() is finally called. The solution is to ignore the ID3v1 tags as the gapless info would never exist there, and only check for ID3v2 tags. Change-Id: I7d1b94cffbfe7c38ca094834dedbc92a58855e20
| * | | am 7b7f17dc: am b7c8e918: Add support for HLS playlists of type \'event\'.Andreas Huber2012-11-282-3/+13
| |\ \ \ | | |/ / | | | | | | | | | | | | * commit '7b7f17dc9b30ff4ecdf0aea9bcfa1c518d4ac1e7': Add support for HLS playlists of type 'event'.
| | * | Add support for HLS playlists of type 'event'.Andreas Huber2012-11-272-3/+13
| | |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | related-to-bug: 6870049 Squashed commit of the following: commit eee2f3ba6bb7335f4e285632726db85645669929 Author: Andreas Huber <andih@google.com> Date: Tue Nov 27 15:02:01 2012 -0800 Make everything a lot less verbose by default. Change-Id: I884d7a7901aa1e7d4ff590f065ca57a79d2af8b3 commit 6bbdb837ed5bd88008e45efb8faf595e4051ba26 Author: Andreas Huber <andih@google.com> Date: Tue Nov 27 14:34:46 2012 -0800 HLS now properly signals media time changes at discontinuities including the start of playback (which may not necessarily be at time 0 if the playlist is of type 'event' and hasn't completed yet). Change-Id: I5ab747d024f9b8d0df72a4e06a12ebb29f62802e commit 1555589832b1878a144a976a643e1af4d61f877c Author: Andreas Huber <andih@google.com> Date: Tue Nov 27 14:32:28 2012 -0800 As part of a time discontinuity, clients of IStreamListener can now signal the corresponding media time after the discontinuity, i.e. the first PTS timestamp following the discontinuity will be considered equivalent to the specified media time and media buffers timestamped accordingly. Change-Id: Id7db7679b7faa6efd6270620ff52e34e884f3e92 commit 5c24c605c073a11c426d025b1e7478fc1ad8365a Author: Andreas Huber <andih@google.com> Date: Tue Nov 27 13:00:56 2012 -0800 NuPlayer sources now expose flags() and can announce that duration may change (increase) dynamically, in which case duration will be polled at 1 second intervals and communicated to the upper layers. Change-Id: I45102909b7a19eed0dda576747e3814d742a0eea commit ecb71de8e281e61971a2cd73e7161a97540bc357 Author: Andreas Huber <andih@google.com> Date: Tue Nov 27 12:57:47 2012 -0800 Stop caching duration in MediaPlayer, duration could increase dynamically. Change-Id: I7bb2f16c0abe49debdf45c776d2266aa069d7791 commit 544aec5823e6d7a3e97e15b6b23546616bcd343e Author: Andreas Huber <andih@google.com> Date: Tue Nov 27 08:46:28 2012 -0800 An attempt to add support for "event" style HLS playlists. Change-Id: I3dfb2e801ecaff8f5d8bdb3a4fca1b18aeeb2c60 Change-Id: I48cf7f65a654d33f2f49ded74f8be22aed9e3b98
| * | Remove unused default parameter for copyBuffer()James Dong2012-11-011-1/+1
| | | | | | | | | | | | Change-Id: I8002986ccb926165af393ca80cece60dee011204
| * | Make ThrottledSource more usableMarco Nelissen2012-10-241-5/+31
| |/ | | | | | | | | | | | | | | Add reconnectAtOffset(), DrmInitialization() and getDrmInfo(). Also rearrange the code a bit so all the methods that just call through to the wrapped DataSource are in the header. Change-Id: If25b674df317b0f6da5d36241c694e32abb0a01c
| * Add getError and setError to propagate error code from WVMMediaExtractor up ↵Edwin Wong2012-09-111-0/+6
| | | | | | | | | | | | | | | | | | | | to player. The two virtual functions provides a path for the player(AwesomePlayer) to retrieve the last error from WVMMediaExtractor container. Change-Id: Iee8d4a3eccf82af95eb3d4d465f069daced4aa1a related-to-bug: 7073630
| * Fragmented mp4 extractorMarco Nelissen2012-09-052-2/+91
| | | | | | | | | | | | | | Still experimental. Set property "media.stagefright.use-fragmp4" to true to enable. Change-Id: I210b9c5b5164b5c5eefc31309845ee881ac7db8e
| * Move fragmented mp4 parser to libstagefrightMarco Nelissen2012-08-311-0/+255
| | | | | | | | | | and rename it from Parser to FragmentedMP4Parser Change-Id: I986f50d0c5c93648aac675d6160e18623b031541
* | New HLS implementation supporting independent stream sources, audio-only streamsAndreas Huber2013-05-314-259/+7
| | | | | | | | | | | | and more. Change-Id: Icfc45a0100243b2f7a14a9e65696be45b67d6495
* | Edit list uses timescale from movie headerMarco Nelissen2013-05-301-0/+1
| | | | | | | | | | | | not from track media header Change-Id: I24063183f44027b999782cc9006e9a1b56e87355