dholroyd / h264-reader

Rust reader for H264 bitsream syntax
Apache License 2.0
72 stars 25 forks source link

New PicParamSetId to perform proper bounds check #64

Closed dholroyd closed 6 months ago

dholroyd commented 6 months ago

Using a single ParamSetId had the problem that Ids for pic_parameter_set and seq_parameter_set have different maximum allowed values. This change removes that original type and replaces it with seperate PicParamSetId and SeqParamSetId types.

SeqParamSetId enforces a limit of 31 as before, but PicParamSetId enforces a limit of 255.

Fixes #56