Browse Source

Verify HEVC filtering across profile matrix

pull/2633/head
James Jackson-South 4 days ago
parent
commit
1c72927598
  1. 6
      tests/ImageSharp.Tests/Formats/Heif/Hevc/HevcPictureDecoderTests.cs

6
tests/ImageSharp.Tests/Formats/Heif/Hevc/HevcPictureDecoderTests.cs

@ -98,10 +98,14 @@ public class HevcPictureDecoderTests
ConvertAnnexBStillPicture(annexB, bitDepth, chromaFormat, out byte[] configurationData, out byte[] itemData);
HevcCodecConfiguration configuration = new(configurationData);
HevcImageItemBitstream bitstream = new(itemData, configuration);
using HevcPictureDecoder decoder = new(Configuration.Default, bitstream.SliceSegments[0].PictureParameterSet);
HevcSliceSegmentHeader sliceHeader = bitstream.SliceSegments[0];
HevcSequenceParameterSet sequenceParameterSet = sliceHeader.PictureParameterSet.SequenceParameterSet;
using HevcPictureDecoder decoder = new(Configuration.Default, sliceHeader.PictureParameterSet);
decoder.Decode(bitstream);
Assert.True(sequenceParameterSet.SampleAdaptiveOffsetEnabled);
Assert.False(sliceHeader.DeblockingFilterDisabled);
Assert.Equal(bitDepth, decoder.Picture.BitDepthLuma);
Assert.Equal(chromaFormat, decoder.Picture.ChromaFormat);
int expectedLength = decoder.Picture.GetWidth(HevcPlane.Y) * decoder.Picture.GetHeight(HevcPlane.Y) * (bitDepth > 8 ? 2 : 1);

Loading…
Cancel
Save