Gráfico de commits

232 Commits

Autor SHA1 Mensaje Fecha
Rajy Rawther 966f338d96 set min: number of decoded surfaces to non-zero value for ffmpeg based decoding (#627)
[ROCm/rocdecode commit: d9690d1715]
2025-08-08 10:11:10 -04:00
Rajy Rawther 827511a6b5 ffmpeg decode utility class cleanup (#616)
* cleaned up ffmpeg decode utility class to use rocdecode host lib

* added changelog for the PR

* address review comments for FFMPEG dependancy in cmake

* Update CHANGELOG.md

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

* addressed review comments

* update version in Cmake

---------

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

[ROCm/rocdecode commit: 3b280ac7c3]
2025-07-28 09:59:47 -04:00
arvindcheru 0058b85808 Add softlink for rocdecode-host library target (#614)
[ROCm/rocdecode commit: eb487c3204]
2025-07-03 15:35:31 -04:00
Kiriti Gowda 208f918c88 Find rocdecode - Updates for ROCm 7.0 (#610)
* rocDecode - Version 1.0.0

* Find package - config updates

* CMakeLists - Updates and config fix

* CMakelists - updates

* Samples - link to rocdecode_LIBRARY rocdecode::rocdecode

---------

Co-authored-by: Kiriti <kiriti@santiago.amd.com>

[ROCm/rocdecode commit: 23c17cc150]
2025-06-24 17:39:49 -04:00
Lakshmi Kumar ef4250f6d9 Set video_signal_description struct to 0 by default (#605)
* Update avc_parser.cpp

* Update hevc_parser.cpp

[ROCm/rocdecode commit: 9283abc629]
2025-06-19 08:53:53 -04:00
Rajy Rawther 3d335b3e09 Option to disable building of rocdecode host based library (#603)
[ROCm/rocdecode commit: 83734ec42e]
2025-06-12 08:28:44 -04:00
Aryan Salmanpour a480fb183b Utils - Remove the call to rocDecGetDecodeStatus after rocDecGetVideoFrame (#600)
* Utils - Remove the call to rocDecGetDecodeStatus after rocDecGetVideoFrame

* Remove other occurrences of rocDecGetDecodeStatus that are not necessary

* Update the description of the rocDecGetDecodeStatus and rocDecGetVideoFrame APIs

* Add missing including thread in avcodec_videodecoder.h for fixing the Azure build issue

[ROCm/rocdecode commit: bf4922060d]
2025-06-11 11:44:20 -04:00
Aryan Salmanpour 5b1ebe013c Remove the call to vaQuerySurfaceStatus before vaSyncSurface (#599)
[ROCm/rocdecode commit: 089abe7435]
2025-06-09 15:54:28 -04:00
Rajy Rawther 40e072f394 FFMpeg decoder rocdecode integration (#583)
* initial commit

* initial implementation for host based decoder

* minor change

* cmake changes and added new sample

* rocdecDecode sample implementation

* rocdecode sample changes working

* working version of avcodec decoder and sample

* Add end of stream handling for repeated decoding with reconfigure

* reorg files and added changelog

* update readme

* revert file

* remove unused class members

* addressed reviw comment for changelog

* fix sample to work on more video files

* resolved review comments

* bumped version to 0.14.0

* fixed build warnings

* addressed review comments

* addressed review comments

* addressed review comments

* fixed readme to match .cpp file options for parameters

* updated review comments, readme, and added test data for the sample

* fixed bug for saving frame for 10 bit videos

* addressed review comments

* addressed all the new review comments

[ROCm/rocdecode commit: 3ddb12f075]
2025-06-07 13:12:57 -04:00
jeffqjiangNew 6b8c4f82ff VP9 error resilience: Added uncompressed and compressed header size checks. (#592)
* * VP9 error resilience: Added uncompressed and compressed header size checks.

* * Minor format change.

[ROCm/rocdecode commit: 24b0c59d71]
2025-05-21 10:04:16 -04:00
jeffqjiangNew 5c8879aa6c * 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.

[ROCm/rocdecode commit: e3ab17c09e]
2025-05-14 17:12:50 -04:00
jeffqjiangNew d24e374566 * 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.

[ROCm/rocdecode commit: 17ef0c2d56]
2025-05-09 14:35:08 -04:00
jeffqjiangNew 6e1cd70811 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.

[ROCm/rocdecode commit: a861d6f1d2]
2025-05-06 12:02:51 -04:00
jeffqjiangNew 798a4a03f0 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.

[ROCm/rocdecode commit: 41338c40f3]
2025-05-05 12:01:56 -04:00
jeffqjiangNew a8f665e2be * 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.

[ROCm/rocdecode commit: d751b24ed5]
2025-05-01 12:50:28 -04:00
jeffqjiangNew e8981c5848 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.

[ROCm/rocdecode commit: e85ae200e5]
2025-04-25 13:57:37 -04:00
Aryan Salmanpour fe0e639d08 close the drm_fd in the VaContext destructor (#560)
[ROCm/rocdecode commit: ed556199b0]
2025-04-14 19:13:57 -04:00
jeffqjiangNew a65bc49a07 * AVC: Disabled support for gaps in frame_num. (#559)
[ROCm/rocdecode commit: 03f73357c7]
2025-04-14 16:23:15 -04:00
Aryan Salmanpour ad9978f20f Add extra error checking during decoder reconfiguration (#558)
[ROCm/rocdecode commit: 0f89c55157]
2025-04-14 14:36:08 -04:00
jeffqjiangNew d9512d14df 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>

[ROCm/rocdecode commit: 193423300f]
2025-04-12 09:11:33 -04:00
jeffqjiangNew a0dd3fc6b3 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>

[ROCm/rocdecode commit: 3d1a1b638e]
2025-04-09 20:57:52 -04:00
Aryan Salmanpour 20e919c6cf Code Clean up - remove unused API (#552)
* Code Clean up - remove unused API

* clean up

[ROCm/rocdecode commit: d80f807b1a]
2025-04-09 13:49:04 -04:00
jeffqjiangNew 8b5cf557df * 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>

[ROCm/rocdecode commit: 9127f2ccba]
2025-04-07 20:34:01 -04:00
jeffqjiangNew 97d503139d 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.

[ROCm/rocdecode commit: 0cb7c4594c]
2025-04-07 16:16:49 -07:00
jeffqjiangNew a7b5c7df8c * 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)
[ROCm/rocdecode commit: d10eacf05f]
2025-03-31 19:04:34 -04:00
jeffqjiangNew 13e8e15d7b * rocDecode/HEVC error resilience: Added dependant slice error handling. (#547)
[ROCm/rocdecode commit: fc01d72aea]
2025-03-28 16:35:03 -04:00
jeffqjiangNew ae7b72631f 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.

[ROCm/rocdecode commit: 93711b5127]
2025-03-26 08:16:36 -04:00
Lakshmi Kumar 5157e8d7d0 Fix warnings (#536)
* fix warnings

* remove warning

---------

Co-authored-by: Kiriti Gowda <kiritigowda@gmail.com>

[ROCm/rocdecode commit: 0b1865e8b8]
2025-03-20 09:12:16 -04:00
jeffqjiangNew ede21fffa0 HEVC: Added DPB size change handling through decoder reconfiguration. (#531)
* * rocDecode/HEVC: Added DPB size change handling through decoder reconfiguration.

* * rocDecode/HEVC: Minor fix.

[ROCm/rocdecode commit: 5988eb16b6]
2025-03-18 17:19:01 -04:00
Kiriti Gowda 26a67fb210 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>

[ROCm/rocdecode commit: 6b026af151]
2025-03-17 12:38:01 -04:00
Aryan Salmanpour 68dee64275 Remove unused VA_CHECK_VERSION (#530)
[ROCm/rocdecode commit: d8e285ce1b]
2025-03-13 10:43:57 -04:00
jeffqjiangNew aacd035b6d 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.

[ROCm/rocdecode commit: ab7546930f]
2025-03-13 09:29:25 -04:00
jeffqjiangNew cd98621eb9 * 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)
[ROCm/rocdecode commit: ac74540c19]
2025-03-12 17:49:52 -04:00
jeffqjiangNew 23309b2e4c 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.

[ROCm/rocdecode commit: 263b57fde9]
2025-03-10 09:15:12 -04:00
jeffqjiangNew aa1bb2e94f 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.

[ROCm/rocdecode commit: 27adeb8c47]
2025-03-05 08:44:59 -05:00
jeffqjiangNew ef7c4c900c * rocDecoder/Bitstream reader: Added stream type detection optimization. (#522)
- During stream type evaluation, when we have a high confidence score, we stop and finalize, to avoid unnecessary exhaustive type search.

[ROCm/rocdecode commit: 5f779a6eb7]
2025-03-03 09:31:49 -05:00
jeffqjiangNew eb2aae5c39 VP9: Added VP9 IVF container detection and picture data parsing support to bitstream reader. (#519)
* * rocDecode/VP9: Added VP9 IVF containter detection and picture data parsing.

* * rocDecode/VP9 bitstream reader: Wording changes based on review comment.

* * rocDecode/VP9 IVF parser: Updated change log based on review comment.

* * rocDecode/VP9 IVF parser: Bumped up rocDecode version to 0.11.0.

* * rocDecode/VP9: Added VP9 IVF containter detection and picture data parsing.

* * rocDecode/VP9 bitstream reader: Wording changes based on review comment.

* * rocDecode/VP9 IVF parser: Updated change log based on review comment.

* * rocDecode/VP9 IVF parser: Bumped up rocDecode version to 0.11.0.

* * rocDecode/VP9 IVF parsing: Minor name correction.

[ROCm/rocdecode commit: a5863bceba]
2025-02-28 18:11:10 -05:00
jeffqjiangNew 4e8f655fde * rocDecode: Fix a typo in new sequence callback function name. (#520)
[ROCm/rocdecode commit: a78f6730c8]
2025-02-25 20:43:46 -05:00
jeffqjiangNew c8a7b82794 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.

[ROCm/rocdecode commit: 2af7bbf4e7]
2025-02-12 17:18:09 -05:00
Aryan Salmanpour 08a70a5ae4 remove unused code (#504)
[ROCm/rocdecode commit: 320d1422af]
2025-02-03 13:21:43 -05:00
Aryan Salmanpour 2f754d1ffb Eliminate the use of std::fs (#497)
[ROCm/rocdecode commit: bca75cf2b7]
2025-01-27 08:10:11 -05:00
jeffqjiangNew 6b61183723 Create separate VA display for each decoder instance. (#496)
* * rocDecode: Experiment per decode instance va display.

* * rocDecode/Perf: Removed comments.

* * rocDecode/VA context: Minor changes based on review comment.

[ROCm/rocdecode commit: 46a344259b]
2025-01-23 15:28:41 -08:00
jeffqjiangNew 4ac1c26cfc * rocDecode/HEVC: Added short term RPS parsing error handling. (#495)
[ROCm/rocdecode commit: dec6dacbc9]
2025-01-22 12:47:01 -05:00
Aryan Salmanpour df70c8eb87 Optimize finding the compute partition mode (#493)
[ROCm/rocdecode commit: 6ada77a9ad]
2025-01-18 10:12:02 -05:00
Aryan Salmanpour a6d3c91163 code cleanup - remove unnecessary check (#492)
[ROCm/rocdecode commit: fe0fee01d0]
2025-01-16 14:06:28 -05:00
jeffqjiangNew f963a7c3a0 Added the new GPU VA context class to handle VA connections to GPU. Removed the hard coded HW decoder capability info. (#415)
* * rocDecode: Removed the hard coded HW decoder capability info.
 - We now probe HW decoder capabilities through VA-API from the driver.

* * rocDecode: Added number of decoder prob and a few missing tear down calls.

* * rocDecode/HW cap change: Added a new singleton class, GpuVaContext, to handle HIP and VA initialization and VA attributes probe for both HW capability check and decoder initialization.

* * rocDecode/HW caps: Removed GpuVaContext class out of vaapi_videodecoder.h and into a new file. Removed debug logs. Removed roc_decoder_caps.h.

* * rocDecode/HW caps: Fixed a crash issue with multi-thread cases. Called to vaInitialize() and vaTerminte() should be paired.

* * rocDecode/HW caps: Added multi-GPU support.

* * rocDecode/HW cap: Moved GpuVaContext class implementation back to VAAPI layer.

* * rocDecode/HW cap: Added changed based on review comments.

* * rocDecode/HW cap: Added changes based on review comments.

* * rocDecode/HW cap: GPU VA context class name change based on review comment.

---------

Co-authored-by: Kiriti Gowda <kiritigowda@gmail.com>

[ROCm/rocdecode commit: ef06f12dfa]
2025-01-10 14:44:06 -05:00
Aryan Salmanpour 43711e5e62 code clean up (#490)
[ROCm/rocdecode commit: 6477cd1100]
2025-01-09 10:38:54 -05:00
jeffqjiangNew 9d96ca1354 * 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.

[ROCm/rocdecode commit: 9c113d5ee9]
2025-01-07 20:43:49 -05:00
jeffqjiangNew 733f676b3b * 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.

[ROCm/rocdecode commit: 888940f52c]
2025-01-06 12:33:12 -05:00
Aryan Salmanpour c597fb2a4c Update Copyright year to 2025 (#486)
* Update Copyright year to 2025

* update year to 2025

[ROCm/rocdecode commit: 3624040ce7]
2025-01-05 16:25:39 -05:00