summaryrefslogtreecommitdiffstats
path: root/media/libstagefright/SurfaceMediaSource.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Remove deprecated BufferQueue constructorDan Stoza2014-03-121-10/+10
| | | | | Bug: 13415624 Change-Id: I1a824d09ce582ee54753683d30cdc23813c13b6b
* Add empty onSidebandChanged callbacks to BufferQueue::ConsumerListenersJesse Hall2014-03-071-0/+4
| | | | Change-Id: I94384aefd47b3a581cbdc3905ba9fdbc88d3d06c
* Merge "warnings be gone."Andreas Huber2014-02-111-5/+7
|\
| * warnings be gone.Andreas Huber2014-02-111-5/+7
| | | | | | | | Change-Id: Ie3bae3f037730e316d7fca12e7a3527973f752ef
* | fix delay when shutting down wifi displayChong Zhang2014-02-071-2/+3
|/ | | | | | | | | | | | RepeaterSource needs to stop SurfaceMediaSource before stopping its looper, otherwise the stop could get queued behind the last read(), which will not return until a new frame comes. Change SurfaceMediaSource stop to signal frame avalable first, so that its read() returns EOS to reader upon stop. Bug: 11677087 Change-Id: Ie331cc8c7f4824fd3930f3e909b53db4463902fb
* separte producer and consumer interfacesMathias Agopian2013-08-061-2/+2
| | | | | Bug: 9265647 Change-Id: Iefabc11e4bd2e2e8ffd31160476c450affe6629c
* fix fallout from binderizing BufferQueues consumer sideMathias Agopian2013-08-011-4/+2
| | | | Change-Id: I626bac6df4fc3d8478046193f06ecc7ea60dd3a8
* update to new Consumer APIsMathias Agopian2013-07-161-4/+3
| | | | Change-Id: I3c5d4be2a2e8783fbf98b3e268fd02658f71dc7d
* Pass additional arg to acquireBuffer calls.Andy McFadden2013-07-081-1/+1
| | | | | | Bug 7900302 Change-Id: I30b9cca783e0a48f77035b745b7d5e20edf10f27
* stagefright: BufferProducer updatesLajos Molnar2013-05-231-10/+14
| | | | | | | | | | | | Update BufferQueue and ConsumerBase users to new BufferQueue API, to allow BufferQueue slots to be reused. Buffer consumers generally now need to track the unique frameNumber belonging to each frame acquired if they are using BufferQueue directly. Otherwise, they can simply track the graphicBuffer. Change-Id: I30ee3158cf40fb10bbd085241646d5f1128ee480 Signed-off-by: Lajos Molnar <lajos@google.com> Related-to-bug: 7093648
* update to Fence::waitForever() API changeMathias Agopian2013-05-161-1/+1
| | | | | Bug: 8988871 Change-Id: I24a2620d356f3bb6207ed834c79fd3e48b429695
* SurfaceMediaSource: wait on fence from acquired buffersGreg Hackmann2012-12-141-0/+4
| | | | | Change-Id: I4ab93a4adeec536648258c70a7d943503d9b10f4 Signed-off-by: Greg Hackmann <ghackmann@google.com>
* Optionally have SurfaceMediaSource return absolute timestampsAndreas Huber2012-10-011-3/+10
| | | | | | | based on systemTime(). Change-Id: I2eff15dd149a4b737d6e7473d1907cf0c80b6b38 related-to-bug: 7266706
* Remove double negatives from SurfaceMediaSourceAndreas Huber2012-10-011-7/+10
| | | | | | | ensure mStarted actually reflects the state of SurfaceMediaSource Change-Id: I92557896993ad8da23fe6940e997402ad63b8cbc related-to-bug: 7258622
* Various improvements to a cleaner shutdown of the wifi display connection.Andreas Huber2012-09-281-0/+32
| | | | | Change-Id: Id029a89939e53c2bd1d20e572d3975ec2795c239 related-to-bug: 7247918
* Cleaner Wifi Display shutdown process, avoid crashing HDCP on exit.Andreas Huber2012-09-271-0/+1
| | | | | Change-Id: Ie54ee3edd672ec629360b4ecc5df2f85ecbaa45f related-to-bug: 7247584
* Throttle SurfaceMediaSource.Andreas Huber2012-09-131-12/+33
| | | | Change-Id: I214ce60f8d94df9c07041577e34ed1ad5e199fdb
* Configure the SurfaceMediaSource to emit the same number of buffersAndreas Huber2012-09-041-0/+4
| | | | | | | as the video encoder allocates for its input. Do this before connecting the bufferqueue through surface flinger. Change-Id: Ibc81db1359afe2d88fdb75b23fadae65c8a6f7cc
* Don't hard code the number of buffers for SurfaceMediaSourceJames Dong2012-08-301-3/+25
| | | | Change-Id: I9ce17b3dc82a5d3e4a66569c76ad9745ceedacd6
* SurfaceMediaSource: a few fixes / cleanupsJamie Gennis2012-08-261-16/+12
| | | | | | | | - Remove the setting of mStopped to true in onBuffersReleased - Cleaned up a few function call logs - Removed the 'reset' method. Change-Id: I56bab1d5cb2f3e6d59d54698c2e045d796d1849f
* Provide new argument to BufferQueue::releaseBufferJesse Hall2012-06-221-2/+4
| | | | Change-Id: Ib86f1af80a0d2833535a0ad170dce5ac061eec75
* SurfaceMediaSource: keep refs to current buffersJamie Gennis2012-06-221-48/+52
| | | | | | | | | This change fixes a bug in SurfaceMediaSource where it would not keep a reference to all of the Gralloc buffers that the video encoder is currently using. Bug: 6655597 Change-Id: Ifd99976cc7ae57ed724bbf2bbcff357a39497391
* Set gralloc consumer usage bits in SurfaceMediaSource.Eino-Ville Talvala2012-04-161-0/+2
| | | | | | | | | BufferQueue is no longer setting these for its endpoints; set the bits to GRALLOC_USAGE_HW_VIDEO_ENCODER | GRALLOC_USAGE_HW_TEXTURE. In the longer term, the set flags should be just GRALLOC_USAGE_HW_VIDEO_ENCODER, but that requires other changes. Change-Id: I4170658de49bf88d829d34605a15684e72a90706
* Refactored SurfaceMediaSourceDaniel Lam2012-04-091-634/+138
| | | | | | | SurfaceMediaSource takes advantage of BufferQueue to avoid duplicated code. Change-Id: I5e60b8eca21e6c3cf728d363cd8f3786125182d1
* reduce IPCs in BufferQueueMathias Agopian2012-03-291-0/+1
| | | | Change-Id: I1f8c32a771a411476d225adc62d1f07c24f39a3e
* SurfaceTexture: Fully refactored from BufferQueueDaniel Lam2012-03-131-0/+3
| | | | | | Cleaning up camera and media interactions as part of SurfaceTexture refactoring Change-Id: Iea2b10ff80b5f01f83ed0902c725df1d3b4c541a
* Switched to use the header files in /frameworks/nativeJames Dong2012-03-121-2/+2
| | | | | | | | and deleted the duplicate header files in /frameworks/base o related-to-bug: 6044887 Change-Id: I17e0692d9a9b5c8796ded36677c833ca8ab36795
* fix libgui header locationMathias Agopian2012-02-271-3/+2
| | | | Change-Id: Iec71706cdd4f29c6904993648ce873e83ef9cafe
* Move away from MediaDebug and use ADebug insteadJames Dong2012-02-101-3/+3
| | | | Change-Id: I963a3b6f79a7292891973cbeeaf3378b38629f08
* Don't call virtual function in destructor of SurfaceMediaSourceJames Dong2012-02-061-3/+3
| | | | Change-Id: I3cbc2b1222335b61c814b5cdcfaefa495148b0ec
* Rename (IF_)LOGE(_IF) to (IF_)ALOGE(_IF) DO NOT MERGESteve Block2012-01-081-16/+16
| | | | | | | See https://android-git.corp.google.com/g/#/c/157220 Bug: 5449033 Change-Id: Ic9c19d30693bd56755f55906127cd6bd7126096c
* am 0cc1e42d: am ac279de9: Merge "SurfaceMediaSource: use the HW_TEXTURE ↵Dave Burke2011-12-151-1/+3
|\ | | | | | | | | | | | | usage bit" into ics-mr1 * commit '0cc1e42d74e09c259a6da0abc9009d1abf7537b1': SurfaceMediaSource: use the HW_TEXTURE usage bit
| * SurfaceMediaSource: use the HW_TEXTURE usage bitJamie Gennis2011-12-151-1/+3
| | | | | | | | | | | | | | | | | | This change makes SurfaceMediaSource request Gralloc buffers with the HW_TEXTURE usage bit rather than the VIDEO_ENCODER bit. It is a temporary workaround for what is likely a Gralloc bug. Bug: 5771063 Change-Id: I9cce615e80fc14a1644fae27ba06970c262dd179
* | am c040e1e7: am 6f1dd757: Merge "SurfaceMediaSource: use the vid enc usage ↵Jamie Gennis2011-11-301-1/+1
|\ \ | |/ | | | | | | | | | | bit" into ics-mr1 * commit 'c040e1e77923d81050f2d3dbdac5d07e01be72f6': SurfaceMediaSource: use the vid enc usage bit
| * SurfaceMediaSource: use the vid enc usage bitJamie Gennis2011-11-211-1/+1
| | | | | | | | | | | | | | This change makes SurfaceMediaSource add the VIDEO_ENC usage bit when allocating its GraphicBuffers rather than the HW_TEXTURE bit. Change-Id: Ie20e225c894fdbc31cad6bb82b3b64c7e98074eb
* | split ComposerService out of SurfaceComposerClient.hMathias Agopian2011-11-281-0/+2
| | | | | | | | Change-Id: I1eb691f7ca263d5895d871ab675bb5826e0323c6
* | Rename (IF_)LOGV(_IF) to (IF_)ALOGV(_IF) DO NOT MERGESteve Block2011-10-261-31/+31
|/ | | | | | | See https://android-git.corp.google.com/g/#/c/143865 Bug: 5449033 Change-Id: I0122812ed6ff6f5b59fe4a43ab8bff0577adde0a
* Returning EOS in SurfaceMediaSource:readPannag Sanketi2011-09-221-2/+2
| | | | | | | | | | In SurfaceMediaSource::read, if disconnect has already been called, then ERROR_END_OF_STREAM should be returned rather that NO_INIT. Else, it sometimes leads to a crash in mediarecorder stop() call. Related to FactoryROM bug: 5332812 Change-Id: I22132538ab2501d084e0283876817b1ec3f64a1d
* Always set geometry in queuebufferPannag Sanketi2011-09-081-4/+5
| | | | | | | The queuebuffer could return early due to timestamp issues. Need to set the geometry even in that case. Change-Id: I04d7cd1df3996d640c269285398c0042923ba920
* Fix SurfaceMediaSource timestamp handling.Eino-Ville Talvala2011-08-301-2/+26
| | | | | | | | Was not basing timestamps on startTimeUs. Now synchronizes properly with audio. Bug: 4510826 Change-Id: I613db0aa91e51fc75d120e65540e742d8ab2ae43
* Merge "Default W, H allowed in SurfaceMediaSource dequeue"Pannag Sanketi2011-08-281-3/+5
|\
| * Default W, H allowed in SurfaceMediaSource dequeuePannag Sanketi2011-08-241-3/+5
| | | | | | | | | | | | | | The client does not have to send (w, h) = (0,0) in dequeuebuffer. It can set the same w, h as the default width and height. Change-Id: I8202f90261ccaebbd35ea28c153a7472f01912f1
* | Testing the GL/ CPU encoding w/ Gralloc buffersPannag Sanketi2011-08-241-67/+111
|/ | | | | | | | | | | | | | | This is the test for Gralloc buffers based encoding. contains a combination of two main changes: 1. GL based encoding tests added to SurfaceMediaSource_test 2. SurfaceMediaSource ::read() colorformat The SurfaceMediaSource::getformat() sets it to OMX_COLOR_FormatAndroidOpaque. The omx encoder needs to interpret that colorformat and reads the format from the Gralloc buffers directly Change-Id: Iee2fe8901384109a4952e1d6c528c59eb01eb5b1
* return correct value from query after connecting a surfaceMathias Agopian2011-08-081-1/+5
| | | | | | | | | | the first time a surface was connected, the values returned by query NATIVE_WINDOW_DEFAULT_{WIDTH|HEIGHT} and NATIVE_WINDOW_TRANSFORM_HINT were wrong until a call to queueBuffer was performed. Bug: 5137366, 5121607 Change-Id: I7ac6b5b0daa876638f6bed7c20f286a6e6d984f6
* Merge "Adding Metadata mode to SurfaceMediaSource"Pannag Sanketi2011-07-251-7/+43
|\
| * Adding Metadata mode to SurfaceMediaSourcePannag Sanketi2011-07-221-7/+43
| | | | | | | | | | | | | | | | | | | | | | | | SurfaceMediaSource operates in metadata mode only, i.e. just the metadata is stored in videobuffers. SurfaceMediaSource passes the Gralloc buffer handle along with a 4 byte 'type' (indicating that the metadata is of type GrallocSource) to the encoder as opposed to the GrallocBuffer itself. Related to bug id: 4529323 Change-Id: I83aebc0dd10f317658cdf70be5802dfc35a1e72d
* | Merge "Connect MediaRecorder Native to SurfaceMediaSource"Pannag Sanketi2011-07-221-18/+27
|\ \ | |/
| * Connect MediaRecorder Native to SurfaceMediaSourcePannag Sanketi2011-07-221-18/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Making a connection from MediaRecorder Native layer to the SurfaceMediaSource for the purpose of encoding GL Frames. This will be called from the java side inside the Mobile Filter Framework. The mediarecorder native layer (client), when set the videosource to option VIDEO_SOURCE_FRAMES, asks the StageFrightRecorder on the mediaserver side to create a SurfaceMediaSource object and pass it back as a sp<ISurfaceTexture> object. Using that, the client side will dequeue and queue buffers. Connecting the GL Frames to the obtained sp<ISurfaceTexture> is not part of this CL. Related to bug id: 4529323 Change-Id: I651bec718dd5b935779e7d7a050b841c2d0b0fcd
* | SurfaceTexture: add the abandon method.Jamie Gennis2011-07-221-6/+7
| | | | | | | | | | | | | | | | This change adds the 'abandon' method to the SurfaceTexture C++ class. This method may be used to put the SurfaceTexture in an abandoned state, causing all ISurfaceTexture methods to fail. Change-Id: Ibd261f7b73f44e2bec36a8508bf92113cfb7cf95
* | SurfaceMediaSource: remove getAllocator methodJamie Gennis2011-07-221-6/+0
|/ | | | | | | | This change removes the getAllocator method from SurfaceMediaSource because that method is no longer a part of the ISurfaceTexture interface. Change-Id: I0e2f0bc3bc1c8cd3c1b4b14246f07b9b4e3066c3