linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Hsia-Jun Li <Randy.Li@synaptics.com>
To: Nicolas Dufresne <nicolas.dufresne@collabora.com>
Cc: "Paul Kocialkowski" <paul.kocialkowski@bootlin.com>,
	linux-kernel@vger.kernel.org, linux-media@vger.kernel.org,
	"Hans Verkuil" <hverkuil@xs4all.nl>,
	"Sakari Ailus" <sakari.ailus@iki.fi>,
	"Andrzej Pietrasiewicz" <andrzej.p@collabora.com>,
	"Michael Tretter" <m.tretter@pengutronix.de>,
	"Jernej Škrabec" <jernej.skrabec@gmail.com>,
	"Chen-Yu Tsai" <wens@csie.org>,
	"Samuel Holland" <samuel@sholland.org>,
	"Thomas Petazzoni" <thomas.petazzoni@bootlin.com>,
	ayaka <ayaka@soulik.info>
Subject: Re: Stateless Encoding uAPI Discussion and Proposal
Date: Thu, 31 Aug 2023 17:32:28 +0800	[thread overview]
Message-ID: <250358e5-d6bb-1941-8d93-023531626145@synaptics.com> (raw)
In-Reply-To: <e5b416f54fb18363c88813ab3240e6f9c48081f9.camel@collabora.com>



On 8/30/23 23:18, Nicolas Dufresne wrote:
> CAUTION: Email originated externally, do not click links or open attachments unless you recognize the sender and know the content is safe.
> 
> 
> Le mercredi 23 août 2023 à 11:04 +0800, Hsia-Jun Li a écrit :
>>> It was suggested so far to leave h264 slice headers writing to the driver. This
>>> is motivated by H264 slice header not being byte aligned in size, so the
>> H.264, H.265 has the byte_alignment() in nalu. You don't need skip bits
>> feature which could be found in H1.
> 
> As you said so, I rechecked the H.264 grammar.
> 
> ...
>    slice_header( )
>    slice_data( )
> ...
> 
> There is lot of variable size items in the slice_header() syntax and no padding
> bits. And no padding at the start of any of the slice_data types. So no, the
> slice_header() syntax in H.264 is not byte aligned like you are claiming here.
> Its important to be super accurate about these things, as it will cause errors
> to be made. Please always double check.
To make a summary of the IRC.
H.264 and VP8 have no such alignment to byte padding bits.
While H.265 has that in 7.3.6.1 General slice segment header syntax.
Also, from 6.1 Frame syntax of AV1, I think frame_header_obu contains 
all the thing that software should prepare for a stateless encoder.
VP9 also has the trailing_bits() after uncompressed_header() (6.1
Frame syntax) would meet the byte alignment.

We may suggest we could use the hardware write-back or write offset bit 
functions which could be widely existed due the non-alignment bitstream 
syntax of the H.264 and VP8.

With such a hardware capability, we could save a cache operation than 
doing that in the kernel.
> 
> Nicolas

-- 
Hsia-Jun(Randy) Li

  reply	other threads:[~2023-08-31  9:32 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-07-11 17:12 Stateless Encoding uAPI Discussion and Proposal Paul Kocialkowski
2023-07-11 18:18 ` Nicolas Dufresne
2023-07-12 14:07   ` Paul Kocialkowski
2023-07-25  3:33     ` Hsia-Jun Li
2023-07-25 12:15       ` Paul Kocialkowski
2023-07-26  2:49         ` Hsia-Jun Li
2023-07-26 19:53           ` Nicolas Dufresne
2023-07-27  2:45             ` Hsia-Jun Li
2023-07-27 17:10               ` Nicolas Dufresne
2023-07-26  8:18   ` Hans Verkuil
2023-08-09 14:43     ` Paul Kocialkowski
2023-08-09 17:24       ` Andrzej Pietrasiewicz
2023-07-21 18:19 ` Michael Grzeschik
2023-07-24 14:03   ` Nicolas Dufresne
2023-07-25  9:09     ` Paul Kocialkowski
2023-07-26 20:02       ` Nicolas Dufresne
2023-08-10 13:44 ` Paul Kocialkowski
2023-08-10 14:34   ` Nicolas Dufresne
2023-08-11 20:08     ` Paul Kocialkowski
2023-08-21 15:13       ` Nicolas Dufresne
2023-08-22  8:30         ` Hsia-Jun Li
2023-08-22 20:31           ` Nicolas Dufresne
2023-08-23  3:04             ` Hsia-Jun Li
2023-08-30 15:10               ` Nicolas Dufresne
2023-08-30 16:51                 ` Randy Li
2023-08-30 15:18               ` Nicolas Dufresne
2023-08-31  9:32                 ` Hsia-Jun Li [this message]
2023-08-23  8:05         ` Paul Kocialkowski
2023-11-15 13:19           ` Paul Kocialkowski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=250358e5-d6bb-1941-8d93-023531626145@synaptics.com \
    --to=randy.li@synaptics.com \
    --cc=andrzej.p@collabora.com \
    --cc=ayaka@soulik.info \
    --cc=hverkuil@xs4all.nl \
    --cc=jernej.skrabec@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=m.tretter@pengutronix.de \
    --cc=nicolas.dufresne@collabora.com \
    --cc=paul.kocialkowski@bootlin.com \
    --cc=sakari.ailus@iki.fi \
    --cc=samuel@sholland.org \
    --cc=thomas.petazzoni@bootlin.com \
    --cc=wens@csie.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).