Граф коммитов

142 Коммитов

Автор SHA1 Сообщение Дата
jeffqjiangNew 24b0c59d71 VP9 error resilience: Added uncompressed and compressed header size checks. (#592)
* * VP9 error resilience: Added uncompressed and compressed header size checks.

* * Minor format change.
2025-05-21 10:04:16 -04:00
jeffqjiangNew e3ab17c09e * VP9 error resilience: Added syntax error handling. (#587)
- Added VP9 stream stream syntax error detection and handling.
 - Updated change log.
 - Bumped rocDecode version to 0.13.1.
2025-05-14 17:12:50 -04:00
jeffqjiangNew 17ef0c2d56 * AV1 error resilience: Added invalid stream syntax element checks in various places. (#582)
- Added checks for allowed values for various stream syntax elements, according to AV1 specification.
2025-05-09 14:35:08 -04:00
jeffqjiangNew a861d6f1d2 Error resilience: Added a few error handling measures. (#581)
* * Error resilience: Added a few error handling measures.
 - AV1: Added check flags to sequence header and frame header to indicate if the headers are parsed without errors. The flags are used to check if the parsing process which refers to the headers can proceed or stop.
 - AV1: Added divide by 0 check on tile columns in tile group parsing.
 - AV1: Added invalid OBU size check in AV1 elementary stream parsing in bitstream reader.
 - All codecs: Added divide by 0 check in display aspect ratio calculation.

* * Error resilience: Fixed a typo in an error message.
2025-05-06 12:02:51 -04:00
jeffqjiangNew 41338c40f3 AV1 error resilience: Added tile size error detection and handling. (#580)
* * AV1 error resilience: Added tile size error detection and handling. Also added additional update to change log for PR#574.

* * Wording change in change log.

* * Updated change log based on review comments.
2025-05-05 12:01:56 -04:00
jeffqjiangNew d751b24ed5 * Roc decoder utility: Do not throw exceptions on picture decode or decoder reconfig errors. (#577)
- This allows the decoder to be able to handle more AV1 error streams.
2025-05-01 12:50:28 -04:00
jeffqjiangNew e85ae200e5 AV1 error resilience: Treated OBU header syntax errors as non-critical. Added invalid OBU size detection and handling. (#570)
* * AV1 error resilience: Treated OBU header syntax errors as non-critical. Added invalid OBU size detection and handling.

* * AV1 error resilience: Minor change.
2025-04-25 13:57:37 -04:00
jeffqjiangNew 03f73357c7 * AVC: Disabled support for gaps in frame_num. (#559) 2025-04-14 16:23:15 -04:00
jeffqjiangNew 193423300f AVC error resilience: Treat reference list setup errors as non-critical. Also minor wording correction in sample script output. (#557)
* * AVC error resilience: Treat reference list setup errors as non-critical. Also minor wordking correction in sample script output.

* * AVC error resilience: Minor change.

---------

Co-authored-by: Kiriti Gowda <kiritigowda@gmail.com>
2025-04-12 09:11:33 -04:00
jeffqjiangNew 3d1a1b638e AVC: Added support for in stream DPB buffer size change. (#553)
* * AVC: Added support for in stream DPB buffer size change.

* * AVC: Updated change log.

---------

Co-authored-by: Kiriti Gowda <kiritigowda@gmail.com>
2025-04-09 20:57:52 -04:00
Aryan Salmanpour d80f807b1a Code Clean up - remove unused API (#552)
* Code Clean up - remove unused API

* clean up
2025-04-09 13:49:04 -04:00
jeffqjiangNew 9127f2ccba * AVC: Fixed an issue in video size change cases, where the remaining decoded buffers of the previous video size in DPB are not output. (#550)
- We need to flush DPB before decoder reconfiguration.

Co-authored-by: Kiriti Gowda <kiritigowda@gmail.com>
2025-04-07 20:34:01 -04:00
jeffqjiangNew 0cb7c4594c AVC error resilience: Added bitstream syntax error handling. (#549)
* * AVC error resilience: Added syntax error detection in SPS, PPS, and slice header parsing.

* * AVC error resilience: Added NAL unit size check before parsing.

* * AVC error resilience: Added parsing error handling.

* * AVC error resilience: Updated change log.
2025-04-07 16:16:49 -07:00
jeffqjiangNew d10eacf05f * HEVC error resilience: Adjusted the range check for the total reference picture number so more errors can be detected. Also fixed a build warning of avc_parser.cpp in debug mode. (#548) 2025-03-31 19:04:34 -04:00
jeffqjiangNew fc01d72aea * rocDecode/HEVC error resilience: Added dependant slice error handling. (#547) 2025-03-28 16:35:03 -04:00
jeffqjiangNew 93711b5127 HEVC Error resilience: Added invalid syntax detection in SPS, PPS, and slice header parsing. (#542)
* * rocDecode/HEVC Error resilience: Added invaid syntax detection in SPS, PPS, and slice header parsing.

* * rocDecode/HEVC error resilience: Minor indent change.
2025-03-26 08:16:36 -04:00
Lakshmi Kumar 0b1865e8b8 Fix warnings (#536)
* fix warnings

* remove warning

---------

Co-authored-by: Kiriti Gowda <kiritigowda@gmail.com>
2025-03-20 09:12:16 -04:00
jeffqjiangNew 5988eb16b6 HEVC: Added DPB size change handling through decoder reconfiguration. (#531)
* * rocDecode/HEVC: Added DPB size change handling through decoder reconfiguration.

* * rocDecode/HEVC: Minor fix.
2025-03-18 17:19:01 -04:00
Kiriti Gowda 6b026af151 CMake config - updates and fixes (#532)
* CMake Config - updates and fixes

* Version - Updates

* Changelog - updates

* Update CHANGELOG.md

Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>

---------

Co-authored-by: spolifroni-amd <Sandra.Polifroni@amd.com>
2025-03-17 12:38:01 -04:00
jeffqjiangNew ab7546930f HEVC: Added bit depth change support in decoder reconfiguration. (#527)
* * rocDecode/HEVC: Added bit depth change support in decoder reconfiguration.

* * rocDecode/HEVC: Removed a comment line.

* * rocDecode/HEVC: Updated change log.

* * rocDecode/HEVC: Used the reserved space in RocdecReconfigureDecoderInfo structure for bit_depth_minus_8 field to be backward compatible. Added bit depth to the new sequence file name when we dump output in decoder reconfiguration case.

* * rocDecode/HEVC: Added bit depth change support in decoder reconfiguration.

* * rocDecode/HEVC: Removed a comment line.

* * rocDecode/HEVC: Updated change log.

* * rocDecode/HEVC: Used the reserved space in RocdecReconfigureDecoderInfo structure for bit_depth_minus_8 field to be backward compatible. Added bit depth to the new sequence file name when we dump output in decoder reconfiguration case.

* * rocDecode/HEVC: Changes based on review comments.

* * rocDecode: Fixed a bug related to 422 surface format assignment.

* * rocDecode: Fixed build warnings with some sample apps.
2025-03-13 09:29:25 -04:00
jeffqjiangNew ac74540c19 * rocDecode/HEVC error resilience: Fixed a vulnerability with active PPS id. We should not assign the current active PPS id to an invalid value. (#529) 2025-03-12 17:49:52 -04:00
jeffqjiangNew 263b57fde9 Added syntax error handling in VPS parsing. (#526)
* * rocDecode/HEVC: Added error handling in VPS parsing.

* * rocDecode/HEVC: Updated change log.

* * rocDecode/Error resilience: Improved syntax error check logging: add the parameter name.
2025-03-10 09:15:12 -04:00
jeffqjiangNew 27adeb8c47 Error resilience: Added HEVC slice syntax error handle for some corrupted streams. (#525)
* * rocDecode/Error resilience: Added HEVC slice syntax error handle for some corrupted streams.
 - Detect out of range total reference numbers.

* * rocDecode/Error resilience: Added additional checks for HEVC reference parameters.

* * rocDecode/Error resilence: Corrected checked range.
2025-03-05 08:44:59 -05:00
jeffqjiangNew a78f6730c8 * rocDecode: Fix a typo in new sequence callback function name. (#520) 2025-02-25 20:43:46 -05:00
jeffqjiangNew 2af7bbf4e7 VP9: Added support for video size change (scaling down) on inter frames. (#508)
* * rocDecode/VP9: Added support for video size change (scaling down) on inter frames.
 - A new reconfigure mode is added, where we keep the existing VAAPI surfaces and context, and work on the smaller images and store the images in the surfaces.

* * rocDecode/VP9 resize: Added changes based on review comments.
2025-02-12 17:18:09 -05:00
jeffqjiangNew dec6dacbc9 * rocDecode/HEVC: Added short term RPS parsing error handling. (#495) 2025-01-22 12:47:01 -05:00
jeffqjiangNew 9c113d5ee9 * rocDecode/VP9: Increased DPB buffer size to handle streams with the maximum number of the reference frames allowed. (#488)
- DPB buffer size was set to NUM_REF_FRAMES(8) which can not handle streams with 8 reference frames. We increase DPB size from 8 to 10 (same strategy as AV1) to be able to handle these streams.
2025-01-07 20:43:49 -05:00
jeffqjiangNew 888940f52c * rocDecode/VP9: Fixed issues with filter parameters. (#487)
- Fixed a condition check in loop filter frame init process.
 - Removed the redundant conversion in interpolation filter assignment in VAAPI. The conversion has been done already when we parse the interpolation filter syntax.
2025-01-06 12:33:12 -05:00
Aryan Salmanpour 3624040ce7 Update Copyright year to 2025 (#486)
* Update Copyright year to 2025

* update year to 2025
2025-01-05 16:25:39 -05:00
jeffqjiangNew 5336913a09 * rocDecode/HEVC: Added in stream DPB buffer size change detection and handling. (#482) 2024-12-19 17:29:52 -05:00
Aryan Salmanpour 3dfb669f57 Add support for rocDecode APIs dispatch table (#462) 2024-11-27 16:14:30 -05:00
jeffqjiangNew 3e6f18c636 VP9: Inter decode is up and running. (#460)
* * rocDecode/VP9: Inter decode is up and running.
 - Added reference list setup for VA-API.
 - Added update reference frame process (8.10).
 - Added set up past independence function.
 - Added DPB and decode pool management.
 - Added display management.
 - Added super frame detection and parsing.
 - Added VA-API parameter logging functions for debugging purposes.

* * rocDecode/VP9: Minor change: removed an extra newline.

* * rocDecode/VP9: Removed todo comments. No functional changes.

* * rocDecode/VP9: Minor changes based on review comments.

* * rocDecode/VP9: Minor changes based on review comment.
2024-11-25 13:51:25 -05:00
jeffqjiangNew 27e9ed23ed HEVC: Cut HEVC parser creation time from about 40 milliseconds to about 50 microseconds. (#458)
* * rocDecode/HEVC: Cut HEVC parser creation time from about 40 milliseconds to about 50 microseconds.

* * rocDecode/HEVC: Added necessary parameter init in parser constructor.

---------

Co-authored-by: Aryan Salmanpour <aryan.salmanpour@amd.com>
2024-11-19 15:10:35 -05:00
jeffqjiangNew 85faa096e5 * rocDecode/HEVC: Fixed an issue in RPS decode function. (#455)
- In searching for a short term reference picture in DPB, we need to make sure it is used.
2024-11-15 15:41:50 -05:00
jeffqjiangNew 3eb6bc2192 Added initial code for VP9 support. (#442)
* * rocDecode/VP9: Initial code for VP9.
 - Added structures for VA-API.
 - Added defines for uncompressed header and parsing functions.

* * rocDecode/VP9: Added decode frame call to VA-API.

* * rocDecode/VP9: Added new sequence notification function.

* * rocDecode/VP9: Intra decode started to work.

* * rocDecode/VP9: Minor changes based on review comments.

---------

Co-authored-by: Kiriti Gowda <kiritigowda@gmail.com>
2024-11-14 10:17:46 -05:00
jeffqjiangNew b3f8fec41b * rocDecode/HEVC: Added empty NAL detection. (#452) 2024-11-13 13:28:29 -05:00
Rajy Rawther 69ec7af8bd Added bitstream validation code for HEVC parser (#450)
* fix for while loop hang

* fix for while loop hang

* add more data validation code in parser

* minor change

* addressed review comments

* fix conformance failures with new code

* added more checks
2024-11-11 17:33:17 -05:00
Rajy Rawther 5820f38592 fix for while loop hang (#447) 2024-11-06 14:41:57 -05:00
jeffqjiangNew d9b235db5a * rocDecode/AV1: Fixed an errror in get Q index function during code inspection. (#438) 2024-10-24 11:51:22 -04:00
Rajy Rawther 29bfe5e3bd Add new API rocDecParserMarkFrameForReuse() for Parser (#430)
* added new API to release video frame for decoder and parser

* removed ReleseFrame() from low level parser classes

* Removed rocDecReleaseFrame() from decoder and added in parser

* address review comments

* revert un-necessary files

* minor fix

* remove unused function

* minor formatting fix
2024-10-09 13:29:08 -04:00
jeffqjiangNew 6253248188 Added real decode speed report to set it apart from the current output speed report in sample apps (#409)
* * rocDecode: Added real decode speed report.
 - The current decode speed report is actually output/display speed report.
 - Due to AV1's extensive use of alternate reference frames that are not display, AV1 decoded frame count and output/displayed frame count can be quite different, making the current speed report not an accurate decode speed measurement.
 - We now added the actual decode speed report, besides the existing speed report, now called output/display FPS.

* * rocDecode: Added real decode speed report.
 - The current decode speed report is actually output/display speed report.
 - Due to AV1's extensive use of alternate reference frames that are not display, AV1 decoded frame count and output/displayed frame count can be quite different, making the current speed report not an accurate decode speed measurement.
 - We now added the actual decode speed report, besides the existing speed report, now called output/display FPS.

* * rocDecode/Sample script: Added missing changes for sample_mode 0 case.
2024-08-20 17:43:33 -04:00
jeffqjiangNew a863ee26a9 * rocDecode/AV1: Performance improvement: prevent synchronous decode submissions. (#406)
- Set the display delay to DECODE_BUF_POOL_EXTENSION (2) to avoid immediate output/display of a decoded frame.
2024-08-12 10:29:43 -04:00
jeffqjiangNew 30ee6787b2 AV1: Fixed an issue with multiple tile group OBUs per picture cases. (#404)
* * rocDecode/AV1: Fixed an issue with multiple tile group OBUs per picture cases.
 - We now use the single base pointer for all tiles in all tile group OBUs and submit them once per picture.

* * rocDecode/AV1: Fixed a typo.
2024-08-07 10:16:17 -04:00
jeffqjiangNew 6a75dc4dcf * rocDecode/AV1: Fixed a bug in set frame refs process that triggers a conformance error check later. (#400) 2024-07-29 17:16:21 -04:00
jeffqjiangNew d0924490a8 * rocDecode/AV1: Fixed a surface size issue in upscaling cases. (#399) 2024-07-26 12:24:32 -04:00
jeffqjiangNew 4f8191edc0 Added the missing presentation time stamp (pts) to decode return info for displayed pictures. (#398)
* * rocDecode: Added the missing pts to decode return info for decoded pictures.

* * rocDecode: Added the missing pts to decode return info for decoded pictures.
2024-07-25 16:53:20 -04:00
jeffqjiangNew 96944030aa * rocDecode/AV1: Added support for getting frame size from reference frames case. Fixed the data type of several quantization parameters. (#397) 2024-07-25 14:55:14 -04:00
jeffqjiangNew 96c65d74a6 Enabled AV1 decode by default. (#391)
* * rocDecode/AV1: Enabled AV1 decode by default.

* * rocDecode/AV1: Added changes suggested in code review.
 - Bumped up rocDecode version to 0.7.0.
 - Added AV1 support statement in readme file.
2024-07-22 12:32:12 -04:00
jeffqjiangNew ac82d17e9f * rocDecode/AV1: Added support for film grain synthesis and several other fixes. (#389)
- Added film grain parameter saving and loading procedures.
 - Added buffer management for film grain synthesis output.
 - Fixed the corruption issue with 10-bit film grain streams. We need to see surface attibutes based on pixel format when creating VAAPI surfaces.
 - Added missing global motion, loop filter and segmentation parameter loading in load reference frame procedure.
 - Fixed an issue with one tile streams.
 - Fixed an issue with un-initialized frame header structure after frame decode.
 - Fixed a bug with decode buffer status update.
2024-07-19 21:01:36 -04:00
jeffqjiangNew a36dd186df AV1: Added a few changes to enable general testing (non-film-grain). (#383)
* * rocDecode/AV1: Added a few changes to enable general testing (non-film-grain).
 - Added show existing frame support.
 - Added load_previous() function.
 - Added more operations to reference frame update process.
 - Added reference frame loading process.
 - Added decode frame wrapup process.
 - Added DPB recycling.
 - Added DPB content logging funcion for debugging purposes.

* * rocDecode/AV1: Removed a line which was added accidentally in the previous commit.
2024-07-15 10:40:59 -04:00