summaryrefslogtreecommitdiff
path: root/vp9/vp9_dx_iface.c
AgeCommit message (Collapse)Author
2015-01-05Properly validate data sizeYaowu Xu
With "show_existing_frame" frames: Minimum data size for profile 0 and 1 is 1 byte (8bits) Minimum data size for profile 2 and 3 is 2 bytes (9bits) Otherwise: Minimum data size is 8 bytes. This resolves the VP9 failure in fuzzing test build #56. Change-Id: I146d9d37688f535dd68d24aacc76d464ccffdf04
2014-12-15Revert "Revert "Add support for setting byte alignment.""Frank Galligan
This reverts commit 91471d6aad285ff10e7582e485d8adadd1986fe2. Fixes the compile issues if post_proc is enabled. Change-Id: Ib40a15ce2c194f9b5adfa65a17ab01ddf60f5a59
2014-12-15Revert "Add support for setting byte alignment."Paul Wilkins
Fails to compile. Bad calls to vp9_alloc_frame_buffer and vp9_realloc_frame_buffer in postproc.c This reverts commit 399823b6f50fb7465f62822d1395e2192e7b07fc. Change-Id: I29f0e173f8e185d3a303cfdb17813e1eccb51e3a
2014-12-12Add support for setting byte alignment.Frank Galligan
Add support for setting byte alignment on the Y, U, and V plane of the reference buffers. The byte alignment must be a power of 2, from 32 to 1024. A value of 0 sets legacy alignment. Change-Id: I7c1399622f7aa68e123646369216b32047dda73d
2014-12-12vp9_dx_iface.c uses CONFIG_VP9_POSTPROC but config.h not includedJim Bankoski
Change-Id: Id316b3786214bf1028992968955da917e3f2d4a3
2014-09-29Miscellaneous decoder changes for high bitdepthDeb Mukherjee
Also includes yv12 config changes. Change-Id: Iacf40d8bf486815b54c32a127ce3cd4516b7e44f
2014-09-04Removing sz member from vpx_codec_priv. Dmitry Kovalev
Change-Id: I811526a9ee9f237604f72abe7fc677e39e0f457f
2014-09-03Consistent allocation of vpx_codec_alg_priv_t.Dmitry Kovalev
Change-Id: I5a03496de035fbcf31e4527cd25fcae4627a57a0
2014-09-02Adds config opt for highbitdepth + misc. vpxDeb Mukherjee
Adds config parameter vp9_highbitdepth, to support highbitdepth profiles. Also includes most vpx level high bit-depth functions. However encode/decode in the highbitdepth profiles will not work until the rest of the code is in place. Change-Id: I34c53b253c38873611057a6cbc89a1361b8985a6
2014-08-28Removing alg_priv from vpx_codec_priv struct.Dmitry Kovalev
In order to understand memory layout consider the declaration of the following structs. The first one is a part of our API: struct vpx_codec_ctx { // ... struct vpx_codec_priv *priv; }; The second one is defined in vpx_codec_internal.h: struct vpx_codec_priv { // ... }; The following struct is defined 4 times for encoder/decoder VP8/VP9: struct vpx_codec_alg_priv { struct vpx_codec_priv base; // ... }; Private data allocation for the given ctx: struct vpx_codec_ctx *ctx = <get> struct vpx_codec_alg_priv *alg_priv = <allocate> ctx->priv = (struct vpx_codec_priv *)alg_priv; The cast works because vpx_codec_alg_priv has a vpx_codec_priv instance as a first member 'base'. Change-Id: I10d1afc8c9a7dfda50baade8c7b0296678bdb0d0
2014-08-21Merge "Replacing NOT_IMPLMENTED with NULL."Dmitry Kovalev
2014-08-20Replacing NOT_IMPLMENTED with NULL.Dmitry Kovalev
We don’t need to introduce new macro for the null value. Change-Id: I59dbae25feeebb4e8359095801aecc8bb17d7764
2014-08-20Removing iface pointer from vpx_codec_priv.Dmitry Kovalev
The iface pointer is already in vpx_codec_ctx struct. Change-Id: I9fffe27c613a7c94476f185a1e5a53ff6d99f1c6
2014-08-19Merge "[spatial svc]Add a few different encode frame tests."Minghai Shang
2014-08-18[spatial svc]Add a few different encode frame tests.Minghai Shang
1. Clean the code for encode frame tests 2. Add encode w/ and w/o alt reference frame test 3. Add encode SNR layers test 4. Add encode multiple layers but decode partial layers test Change-Id: Ibd2c9bc02525db584a6f931a98405f2d851b3cd6
2014-08-12VP8D_GET_FRAME_CORRUPTED: check frame pointerJames Zern
if the decode of the first frame fails, frame_to_show may not be set. fixes a crash in vpxdec with corrupt data. Change-Id: I5ab9476d005778a13fd42a39d05876bb6c90a93c
2014-08-08Merge "Common encode/decode function to get reference frame"Adrian Grange
2014-08-08Merge "Removing legacy XMA features from libvpx."Dmitry Kovalev
2014-08-08Common encode/decode function to get reference frameAdrian Grange
Replaced encoder and decoder functions to get a pointer to a reference frame with a common function, vp9_get_ref_frame, and simplified it. Change-Id: Icb206fcce8caace3bfd1db3dbfa318dde79043ee
2014-08-07Merge "Changes hdr for profiles > 1 for intraonly frames"Deb Mukherjee
2014-08-07Changes hdr for profiles > 1 for intraonly framesDeb Mukherjee
Specifies the bit-depth, color sampling and colorspace for intra only frames for profiles > 0 Also adds checks to ensure that profile 1 and 3 are exclusively used for non 420 streams. Change-Id: Icfb15fa1acccbce8f757c78fa8a2f60591360745
2014-08-06Make the api behavior conform to api spec.Hangyu Kuang
When no more data is available, vpx_codec_decode should be called with NULL as data and 0 as data_sz. vpx_codec_get_frame iterates over a list of the frames available for display. The iterator storage should be initialized to NULL to start the iteration. Iteration is complete when this function returns NULL. Also change the unit test to conform to the api spec. Change-Id: I4b258b309f5df3d37d10c82f01492c0394181c2a
2014-08-05Removing legacy XMA features from libvpx.Dmitry Kovalev
Change-Id: I60ffee7cf78e748792fa6d109322ec32f92e40a9
2014-07-31Changes interface to avoid uninitialized warnings in vp9_cx_iface.c.Jim Bankoski
Change-Id: I1092239e21c1cde188ee2dcb765f4c6fc8c5cdec
2014-07-21Remove unfinished VP9 alpha channel.Alex Converse
Change-Id: Ic5d3a3a0dac10b49495771886a31e793bb78b5ca
2014-07-17Separates profile 2 into 2 profiles 2 and 3Deb Mukherjee
Separates HBD profile int two profiles (2 and 3) consistent with the highbitdepth branch. This patch is ported from the original highbitdepth branch patch: https://gerrit.chromium.org/gerrit/#/c/70460/ Two of the invalid file tests needed to be updated. Change-Id: I6a4acd2f7a60b1fb4cbcc8e0dad4eab4248431e3
2014-07-08Fix decoder handling of intra-only framesAdrian Grange
This patch fixes bug 633: https://code.google.com/p/webm/issues/detail?id=633 The first decoded frame does not have to be a keyframe, it could be an inter-frame that is coded intra-only. This patch fixes the handling of intra-only frames. A test vector has also been added that encodes 3 intra-only frames at the start of the clip. The test vector was generated using the code in the following patch: https://gerrit.chromium.org/gerrit/#/c/70680/ Change-Id: Ib40b1dbf91aae2bc047e23c626eaef09d1860147
2014-06-27Revert "Revert "Revert 3 patches from Hangyu to get Chrome to build:""James Zern
This reverts commit b336356198b8ada50fbb59f04f11cefceaf5ff95. This causes a hang in: VP9/InvalidFileTest.ReturnCode/3 the change to test/user_priv_test.cc remains with a minor update Change-Id: I4a8a272ca37ea329b0f413f0b1cd827a238bd9fd
2014-06-25Revert "Revert 3 patches from Hangyu to get Chrome to build:"hkuang
This patch reverts the previous revert from Jim and also add a variable user_priv in the FrameWorker to save the user_priv passed from the application. In the decoder_get_frame function, the user_priv will be binded with the img. This change is needed or it will fail the unit test added here: https://gerrit.chromium.org/gerrit/#/c/70610/ This reverts commit 9be46e4565f553460a1bbbf58d9f99067d3242ce. Change-Id: I376d9a12ee196faffdf3c792b59e6137c56132c1
2014-06-23Merge "error check vp9 superframe parsing"Jim Bankoski
2014-06-23error check vp9 superframe parsingJim Bankoski
This patch insures that the last byte of a chunk that contains a valid superframe marker byte, actually has a proper superframe index. If not it returns an error. As part of doing that the file : vp90-2-15-fuzz-flicker.webm now fails to decode properly and moves to the invalid file test from the test vector suite. Change-Id: I5f1da7eb37282ec0c6394df5c73251a2df9c1744
2014-06-21Revert 3 patches from Hangyu to get Chrome to build:Jim Bankoski
Avoids failures: MSE_ClearKey/EncryptedMediaTest.Playback_VP9Video_WebM/0 MSE_ClearKey_Prefixed/EncryptedMediaTest.Playback_VP9Video_WebM/0 MSE_ExternalClearKey_Prefixed/EncryptedMediaTest.Playback_VP9Video_WebM/0 MSE_ExternalClearKey/EncryptedMediaTest.Playback_VP9Video_WebM/0 MSE_ExternalClearKeyDecryptOnly/EncryptedMediaTest.Playback_VP9Video_WebM/0 MSE_ExternalClearKeyDecryptOnly_Prefixed/EncryptedMediaTest.Playback_VP9Video_WebM/0 SRC_ExternalClearKey/EncryptedMediaTest.Playback_VP9Video_WebM/0 SRC_ExternalClearKey_Prefixed/EncryptedMediaTest.Playback_VP9Video_WebM/0 SRC_ClearKey_Prefixed/EncryptedMediaTest.Playback_VP9Video_WebM/0 Patches are This reverts commit 9bc040859b0ca6869d31bc0efa223e8684eef37a This reverts commit 6f5aba069a2c7ffb293ddce70219a9ab4a037441 This reverts commit 9bc040859b0ca6869d31bc0efa223e8684eef37a I1f250441 Revert "Refactor the vp9_get_frame code for frame parallel." Ibfdddce5 Revert "Delay decreasing reference count in frame-parallel decoding." I00ce6771 Revert "Introduce FrameWorker for decoding." Need better testing in libvpx for these commits Change-Id: Ifa1f279b0cabf4b47c051ec26018f9301c1e130e
2014-06-20Merge "fix peek_si to enable 1 byte show existing frames."Jim Bankoski
2014-06-20Introduce FrameWorker for decoding.hkuang
When decoding in serial mode, there will be only one FrameWorker doing decoding. When decoding in parallel mode, there will be several FrameWorkers doing decoding in parallel. Change-Id: If53fc5c49c7a0bf5e773f1ce7008b8a62fdae257
2014-06-19fix peek_si to enable 1 byte show existing frames.Jim Bankoski
The test for this is in test vector code ( show existing frames will fail ). I can't check it in disabled as I'm changing the generic test code to do this: https://gerrit.chromium.org/gerrit/#/c/70569/ Change-Id: I5ab324f0cb7df06316a949af0f7fc089f4a3d466
2014-06-19Add superframe support for frame parallel decoding.hkuang
A superframe is a bunch of frames that bundled as one frame. It is mostly used to combine one or more non-displayable frames and one displayable frame. For frame parallel decoding, libvpx decoder will only support decoding one normal frame or a super frame with superframe index. If an application pass a superframe without superframe index or a chunk of displayable frames without superframe index to libvpx decoder, libvpx will not decode it in frame parallel mode. But libvpx decoder still could decode it in serial mode. Change-Id: I04c9f2c828373d64e880a8c7bcade5307015ce35
2014-06-18Merge "Removing decode_one_iter() function."Dmitry Kovalev
2014-06-16Merge "Fix out of boundary memory read in fuzz test on vpxdec"Jingning Han
2014-06-13Fix out of boundary memory read in fuzz test on vpxdecJingning Han
This commit fixes frame header decoding for superframe index, to prevent out of boundary memory read triggered by fuzz test vector. It resolves a chromium security violation issue crbug.com/376802. The issue was introduced in the change: Add VPXD_SET_DECRYPTOR support to the VP9 decoder. cl-id I88f86c8ff9af34e0b6531028b691921b54c2fc48 where the buffer was read before validation check on index offset applied. A test vector is added accordingly. Change-Id: I41c988e776bbdd1033312a668e03a3dbcf44ca99
2014-06-13Delay decreasing reference count in frame-parallel decoding.hkuang
The current decoding scheme will decrease the reference count of the output frame when finish decoding. Then the application could copy the frame from the decoder buffer to application buffer. In frame-parallel decoding, a decoded frame will not be outputted until several frames later which depends on thread numbers. So the decoded frame's reference count should be decreased only after application finish copying the frame out. But due to the limitation of vpx_codec_get_frame, decoder could not know when application finish decoding. So use a index last_show_frame to release the last output frame's reference count. Change-Id: I403ee0d01148ac1182e5a2d87cf7dcc302b51e63
2014-06-11Initially add frame_parallel_decode flag.hkuang
Stub flag temporarily set to 0 until frame parallel decoding implementations are finished. Change-Id: I8ab768138e8f8f8eb809875703b2502ea0fe7cea
2014-05-30Refactor the vp9_get_frame code for frame parallel.hkuang
In frame parallel decoding mode, there will be still several frames inside the decoder when application stop calling vpx_codec_decode to decode frames. The application will need to keep calling vpx_codec_get_frame to get all the remaining decoded frames in the decoder. Change-Id: I2ce8260a91282f045bb9a6093ff8a606b1990f14
2014-05-28Fixing -Wextra warnings in vp9_{cx, dx}_iface.c.Dmitry Kovalev
Change-Id: I0abad32551dc534d3db27424c118e4b2f6b50f37
2014-05-27Removing ctrl_id parameter from vpx_codec_control_fn_t.Dmitry Kovalev
Change-Id: I2b61c8c17ded1074dea92b4f6ad9be84d128b52a
2014-05-21Removing decoded_key_frame flag.Dmitry Kovalev
Change-Id: I79576920efb7f3f6f197d386727409759d8bda8d
2014-05-21Merge "Deadline is not supported in VP9 decoder, removing it completely."Dmitry Kovalev
2014-05-19Merge "Making vp9_initialize_dec() static."Dmitry Kovalev
2014-05-16Merge "Removing redundant decoder_init flag."Dmitry Kovalev
2014-05-16Merge "Fix post-processor macros & remove vizualization"Adrian Grange
2014-05-15Removing redundant decoder_init flag.Dmitry Kovalev
Change-Id: Ieee7a7e3c40d6bcc9fa4df8d10ee9620995aa691