Commit Graph
5 Commits
Author SHA1 Message Date
AZLisme 7843323dc2 fix(videodec): read owned metadata for internal callers 2026-10-27 06:16:45 +08:00
boykopovar f38d29fd08 refactor(sdk): add canonical headers for remaining libraries 2026-10-24 23:17:42 +03:00
Rookie b6dc6a5d4d feat(libSceVideodec): implement sceVideodecQueryResourceInfo
Validate the configuration and resource information as
sceVideodecCreateDecoder does, map the configuration the same way and
report the memory and frame buffer requirements that
sceVideodec2QueryDecoderMemoryInfo gives for it.
2026-10-22 14:32:24 +01:00
Slick Daddy 51c6b38978 fix(libSceVideodec): take the coded picture size the decoder reports
Videodec2 opens FFmpeg with apply_cropping = 0, so the frame it reports is
the coded picture and its crop fields describe the cropping rectangle. The
coded size was derived from the frame size and the crop, which counted the
crop a second time when it added up to a multiple of 16: a picture cropped
four units at the top and four at the bottom was reported 16 rows taller
than the coded picture, and every picture was then refused for a frame
buffer that was sized for the coded picture. The frame size is the coded
size, so the crop only fills the crop offsets.

The fixture's sequence parameter set is also decoded with a crop of four
units at the top and four at the bottom now, which covers the case in the
guest test.
2026-10-21 01:13:00 +03:00
Slick Daddy abf83aa4a8 feat(libSceVideodec): implement the video decoder on top of libSceVideodec2
libSceVideodec's five exports were stubs that threw. Decoder creation,
decoding, flushing, resetting and deleting are implemented with the
structure layouts of shadPS4's PS4 library, and the decode runs through
libSceVideodec2, which decodes H.264 with FFmpeg. The picture is copied
into the caller's frame buffer with the pitch aligned to 64 and the coded
height, the chroma after the luma rows, and the picture information holds
the timestamps and the crop offsets.

A guest test decodes the H.264 fixture through the library and checks the
pictures against the reference hashes.
2026-10-20 00:17:11 +03:00