linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/2] RK3288 VP8 decoding support
@ 2019-07-02 17:00 Ezequiel Garcia
  2019-07-02 17:00 ` [PATCH v2 1/2] media: uapi: Add VP8 stateless decoder API Ezequiel Garcia
  2019-07-02 17:00 ` [PATCH v2 2/2] media: hantro: Add support for VP8 decoding on rk3288 Ezequiel Garcia
  0 siblings, 2 replies; 16+ messages in thread
From: Ezequiel Garcia @ 2019-07-02 17:00 UTC (permalink / raw)
  To: linux-media, Hans Verkuil
  Cc: kernel, Nicolas Dufresne, Tomasz Figa, linux-rockchip,
	Heiko Stuebner, Jonas Karlman, Philipp Zabel, Boris Brezillon,
	Paul Kocialkowski, Alexandre Courbot, fbuergisser, linux-kernel,
	Ezequiel Garcia

This patchset adds support for Hantro G1 VP8 stateless decoding,
as available on RK3288 SoC.

In order to support VP8 stateless decoding, a new pixel format
is introduced V4L2_PIX_FMT_VP8_FRAME, to be used with a new control
V4L2_CID_MPEG_VIDEO_VP8_FRAME_HEADER.

As suggested by Boris on this new version of the uAPI all the structures
and fields have 8-bytes alignment.

In addition, I've checked once again the VP8 spec [1] and did a few
changes:

* Moved 1-bit fields to a bit in the appropriate flags fields.
* Dropped dequant_factors[4][3][2], I really couldn't find this field
  or anything similar in the spec. It's not mentioned anywhere in
  Chromium or FFMPEG, so I decided to drop it.

I have verified the current uAPI and it now matches the VP8 specification
completely, with the exception of the "macroblock_bit_offset" field.

This field is present in VAAPI's VP8 interface as "macroblock_offset"
and is required to find the start of the first macroblock.

[1] https://www.rfc-editor.org/rfc/rfc6386.html
[2] http://intel.github.io/libva/va__dec__vp8_8h_source.html

Thanks,
Ezequiel

Changes from v1:
* Move 1-bit fields to flags in the respective structures.
* Add padding fields to make all structures 8-byte aligned.
* Reorder fields where needed to avoid padding as much as possible.
* Fix documentation as needed.
* Place operators at the end of each line, as suggested by Boris.

Changes from RFC:
* Verify the various ABIs.
* Move entropy coder state fields to a struct.
* Move key_frame field to the flags.
* Remove unneeded first_part_offset field.
* Add documentation.

As before, the ABI has been verified with Maxime Ripard's tools:

https://gitlab.collabora.com/ezequiel/v4l2-ctrl-abi-check

Pawel Osciak (1):
  media: uapi: Add VP8 stateless decoder API

ZhiChao Yu (1):
  media: hantro: Add support for VP8 decoding on rk3288

 Documentation/media/uapi/v4l/biblio.rst       |  10 +
 .../media/uapi/v4l/ext-ctrls-codec.rst        | 323 ++++++++++
 .../media/uapi/v4l/pixfmt-compressed.rst      |  20 +
 drivers/media/v4l2-core/v4l2-ctrls.c          |   8 +
 drivers/media/v4l2-core/v4l2-ioctl.c          |   1 +
 drivers/staging/media/hantro/Makefile         |   4 +-
 drivers/staging/media/hantro/hantro.h         |   5 +
 drivers/staging/media/hantro/hantro_drv.c     |   6 +
 .../staging/media/hantro/hantro_g1_vp8_dec.c  | 552 ++++++++++++++++++
 drivers/staging/media/hantro/hantro_hw.h      |  17 +
 drivers/staging/media/hantro/hantro_v4l2.c    |   1 +
 drivers/staging/media/hantro/hantro_vp8.c     | 188 ++++++
 drivers/staging/media/hantro/rk3288_vpu_hw.c  |  22 +-
 include/media/v4l2-ctrls.h                    |   3 +
 include/media/vp8-ctrls.h                     | 110 ++++
 15 files changed, 1268 insertions(+), 2 deletions(-)
 create mode 100644 drivers/staging/media/hantro/hantro_g1_vp8_dec.c
 create mode 100644 drivers/staging/media/hantro/hantro_vp8.c
 create mode 100644 include/media/vp8-ctrls.h

-- 
2.20.1


^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2019-07-07 14:24 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-07-02 17:00 [PATCH v2 0/2] RK3288 VP8 decoding support Ezequiel Garcia
2019-07-02 17:00 ` [PATCH v2 1/2] media: uapi: Add VP8 stateless decoder API Ezequiel Garcia
2019-07-03  9:19   ` Tomasz Figa
2019-07-03 12:30   ` Boris Brezillon
2019-07-03 14:29   ` Philipp Zabel
2019-07-04 12:39     ` Ezequiel Garcia
2019-07-03 17:39   ` Nicolas Dufresne
2019-07-04 13:00     ` Ezequiel Garcia
2019-07-04 13:06       ` Boris Brezillon
2019-07-02 17:00 ` [PATCH v2 2/2] media: hantro: Add support for VP8 decoding on rk3288 Ezequiel Garcia
2019-07-03 12:32   ` Boris Brezillon
2019-07-03 14:26   ` Philipp Zabel
2019-07-04  7:19     ` Boris Brezillon
2019-07-04 12:32       ` Ezequiel Garcia
2019-07-04 12:36         ` Boris Brezillon
2019-07-07 14:24       ` Kees Cook

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).