Browse Source

Rename params

pull/3119/head
James Jackson-South 4 weeks ago
parent
commit
67b9713ae0
  1. 6
      src/ImageSharp/Formats/Bmp/BmpDecoderCore.cs
  2. 8
      src/ImageSharp/Formats/Webp/WebpAnimationDecoder.cs

6
src/ImageSharp/Formats/Bmp/BmpDecoderCore.cs

@ -1470,9 +1470,9 @@ internal sealed class BmpDecoderCore : ImageDecoderCore
/// Reads the embedded ICC profile from the BMP V5 info header.
/// </summary>
/// <param name="stream">The <see cref="BufferedReadStream"/> containing image data.</param>
/// <param name="metadata">The image metadata.</param>
/// <param name="imageMetadata">The image metadata.</param>
/// <param name="infoHeaderStart">The stream position where the info header begins.</param>
private void ReadIccProfile(BufferedReadStream stream, ImageMetadata metadata, long infoHeaderStart)
private void ReadIccProfile(BufferedReadStream stream, ImageMetadata imageMetadata, long infoHeaderStart)
{
byte[] iccProfileData = new byte[this.infoHeader.ProfileSize];
stream.Position = infoHeaderStart + this.infoHeader.ProfileData;
@ -1485,7 +1485,7 @@ internal sealed class BmpDecoderCore : ImageDecoderCore
IccProfile profile = new(iccProfileData);
if (profile.CheckIsValid())
{
metadata.IccProfile = profile;
imageMetadata.IccProfile = profile;
}
else
{

8
src/ImageSharp/Formats/Webp/WebpAnimationDecoder.cs

@ -375,7 +375,7 @@ internal class WebpAnimationDecoder : IDisposable
private void ReadOptionalChunk(
BufferedReadStream stream,
WebpChunkType chunkType,
ImageMetadata metadata,
ImageMetadata imageMetadata,
bool ignoreMetadata)
{
switch (chunkType)
@ -384,13 +384,13 @@ internal class WebpAnimationDecoder : IDisposable
// While ICC profiles are optional, an invalid ICC profile cannot be ignored because it must
// precede the frame data, and we cannot safely skip it without successfully reading its size.
WebpChunkParsingUtils.ReadIccProfile(stream, metadata, ignoreMetadata);
WebpChunkParsingUtils.ReadIccProfile(stream, imageMetadata, ignoreMetadata);
break;
case WebpChunkType.Exif:
this.executeAncillarySegmentAction(() => WebpChunkParsingUtils.ReadExifProfile(stream, metadata, ignoreMetadata));
this.executeAncillarySegmentAction(() => WebpChunkParsingUtils.ReadExifProfile(stream, imageMetadata, ignoreMetadata));
break;
case WebpChunkType.Xmp:
this.executeAncillarySegmentAction(() => WebpChunkParsingUtils.ReadXmpProfile(stream, metadata, ignoreMetadata));
this.executeAncillarySegmentAction(() => WebpChunkParsingUtils.ReadXmpProfile(stream, imageMetadata, ignoreMetadata));
break;
}
}

Loading…
Cancel
Save