Browse Source

minor refactor

af/merge-core
Anton Firszov 9 years ago
parent
commit
5b203b8ad3
  1. 1
      src/ImageSharp.Formats.Jpeg/Components/Decoder/Bytes.cs
  2. 2
      src/ImageSharp.Formats.Jpeg/JpegDecoderCore.cs

1
src/ImageSharp.Formats.Jpeg/Components/Decoder/Bytes.cs

@ -182,6 +182,7 @@ namespace ImageSharp.Formats.Jpg
return errorCode;
}
[MethodImpl(MethodImplOptions.AggressiveInlining)]
public DecoderErrorCode ReadByteAsIntUnsafe(Stream inputStream, out int result)
{
DecoderErrorCode errorCode = DecoderErrorCode.NoError;

2
src/ImageSharp.Formats.Jpeg/JpegDecoderCore.cs

@ -8,6 +8,7 @@ namespace ImageSharp.Formats
using System.Buffers;
using System.IO;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Threading.Tasks;
using ImageSharp.Formats.Jpg;
@ -380,7 +381,6 @@ namespace ImageSharp.Formats
if (code <= huffmanTree.MaxCodes[i])
{
// ValuesAsInt[huffmanTree.Indices[i] + code - huffmanTree.MinCodes[i]];
result = huffmanTree.GetValue(code, i);
return DecoderErrorCode.NoError;
}

Loading…
Cancel
Save