Commit Graph

16 Commits

Author SHA1 Message Date
jeffqjiangNew a48fc69caf * rocDecode/AVC: Fixed a bug in more RBSP data check function. (#263) 2024-02-27 17:37:32 -05:00
jeffqjiangNew 244eb517ab * rocDecode/AVC: Added error handling for no slice data cases. (#261)
- At the end of some streams, the demuxer sends a picture payload of NAL units that do not contain slice data. In such cases, we return gracefully without causing a decoder error.
2024-02-27 09:03:29 -05:00
jeffqjiangNew f9c226ca84 AVC: Added adaptive memory control decoded reference picture marking process and a few fixes. (#256)
* * rocDecode/AVC: Added adaptive memory control decoded reference picture marking process. Other changes include:
 - Replaced part of reference list modification implementation with a cleaner and more correct logic. It was found that the steps suggested
in the spec resulted errors on some streams.
 - Fixed an issue in reference picture list construction. We still need to do picture number calculation (8.2.4.1) for I pictures.
 - Fixed a bug in VAAPI slice parameter setup for ref list 1 for B pictures.

* * rocDecode/AVC: Fixed the scaling list setup for VAAPI.
 - Put the scaling list in zig-zag scan order.

* * rocDecode/AVC: Added adaptive memory control decoded reference picture marking process. Other changes include:
 - Replaced part of reference list modification implementation with a cleaner and more correct logic. It was found that the steps suggested
in the spec resulted errors on some streams.
 - Fixed an issue in reference picture list construction. We still need to do picture number calculation (8.2.4.1) for I pictures.
 - Fixed a bug in VAAPI slice parameter setup for ref list 1 for B pictures.

* * rocDecode/AVC: Fixed the scaling list setup for VAAPI.
 - Put the scaling list in zig-zag scan order.

* * rocDecode/AVC: Replaced Todo comments with error messages, based on code review.
2024-02-26 10:07:40 -05:00
jeffqjiangNew 4709c0981f AVC: Added reference picture list modification. (#254)
* * rocDecode/AVC: Added reference picture list modification.

* * rocDecode/AVC: Removed a debug log.

---------

Co-authored-by: Aryan Salmanpour <aryan.salmanpour@amd.com>
2024-02-22 08:53:29 -05:00
jeffqjiangNew 9b006616ed * rocDecode/AVC: Added SEI message extraction support. Also merged common AVC and HEVC SEI support code to super class. (#250) 2024-02-15 08:42:51 -05:00
jeffqjiangNew ca3333f7b9 AVC: Added DPB management, decoded picture output and display callback. (#244)
* * rocDecode/AVC: Added display callback implementation.

* *rocDecode/AVC: Fixed a few issues with decoded buffer output and bumping from DPB.

* * rocDecode: Name changes based on code review.

---------

Co-authored-by: Kiriti Gowda <kiritigowda@gmail.com>
2024-02-14 18:06:43 -05:00
jeffqjiangNew c496dfd3f2 * rocDecode/AVC: Added support for multiple slice parameter buffer submission for AVC multi-slice streams. (#234) 2024-02-12 10:22:42 -05:00
jeffqjiangNew 00127f16f1 Implemented proper slice parameter buffer submission for multiple slice streams. (#226)
* * rocDecode: Implemented proper slice parameter buffer submission for multiple slice streams.
 - We were submitting single slice parameter buffer for multiple slice streams. This works for other APIs but not for VAAPI, which requires to send slice parameter buffer once per slice.
 - At step 1, all the multi-slice structures are fixed sized (256). Will make them dynamic in the next step.
 - With this change, all 135 HEVC conformance streams now pass.

* * rocDecode: Multiple slice change step 2: make the fixed size slice info structure lists dynamic.

* * rocDecode: Minor changes in comments. No functional changes.

* *rocDecode: Changed INIT_SLICE_PARAM_LIST_NUM from 256 back to 16. 256 was set during debug process.

* * rocDecode: Add suggest changes from code review.

* * rocDecode: Moved slice_params_buf_id_ initialization to class VaapiVideoDecoder declaration, as suggested by code review.
2024-02-09 15:09:49 -05:00
jeffqjiangNew 300be009de * rocDecode/AVC: Added initial B frame support. (#214)
- Basic B frames are decoded clean now.
2024-02-01 09:58:00 -05:00
jeffqjiangNew 90cddfe655 * rocDecode/AVC: Fixed a few issues with P frame. (#212)
- Moved decoded reference picture marking after decode picture submission, according to the spec.
 - Fixed several errors in the decoding process.
 - Added two debug functions to log out DPB content and VAAPI buffer info.
 - P frames look good now.
2024-01-31 09:10:41 -05:00
jeffqjiangNew 6bd8509bec AVC: Added several steps in slice decoding process (8.2) (#208)
* * rocDecode/AVC: Added decode picture callback from parser to decoder and VAAPI decode submission.

* * rocDecode/AVC: Minor changes based on code review comments.

* * rocDecode/AVC: Removed a redundant line.

* * rocDecode/AVC: Added picture order count calculation.

* * rocDecode/AVC: Added initial implementation of reference list setup.

* * rocDecode/AVC: Added decoded reference picture marking.

* * rocDecode/AVC: Minor changes based on code review.
2024-01-29 12:09:36 -05:00
jeffqjiangNew cd6401750e Changed rocDecode API header variable naming to Google C++ style. (#196)
* * rocDecode: Changed rocDecode API header variable naming to Google C++ style.

* * rocDecode: Unified AVC/H264 naming to AVC. Minor naming changes on HEVC related names.

* * rocDecode: Minor comment fix based on code review.
2024-01-24 18:03:46 -05:00
jeffqjiangNew 426067898c AVC: Added decode picture callback from parser to decoder and VAAPI decode submission. (#190)
* * rocDecode/AVC: Added decode picture callback from parser to decoder and VAAPI decode submission.

* * rocDecode/AVC: Minor changes based on code review comments.

* * rocDecode/AVC: Removed a redundant line.

* * rocDecode/AVC: Condensed several lines based on code review feedback.
2024-01-23 17:30:29 -08:00
jeffqjiangNew cf82317396 Fixed display aspect ratio calculation for both AVC and HEVC. (#187)
* * rocDecode: Fixed display aspect ratio calculation.
 - We were assigning sample aspect ration (SAR) from VUI directly to display aspect ratio (DAR). Now we follow the correct procedure.

* * rocDecode: Fixed an error in display aspect ratio calculation. Should include sample aspect ratio in the final step.
2024-01-18 11:31:54 -08:00
jeffqjiangNew a7bb9953c6 Added new sequence notification callback for AVC. (#184)
* * rocDecode/AVC: Added new sequence notification callback.

* * rocDecode/AVC: Removed the commented out code.

* * rocDecode/AVC: Changed function name to better describe the operation.

* * rocDecode/AVC: Minor formatting change.
2024-01-17 14:24:58 -05:00
jeffqjiangNew 395a1249c1 Added initial AVC parser. (#176)
* * rocDecode/AVC: Added initial AVC parser.
 - Added AVC SPS, PPS and slice header parsing functions.
 - Merged common parsing code from AVC and HEVC parsers to their super class.

* * rocDecode/AVC: Formating changes. No functional changes.
2024-01-16 20:57:40 -05:00