BitMiracle.LibJpeg.Classic.Internal.jpeg_marker_reader.jpeg_set_marker_processor C# (CSharp) Method

jpeg_set_marker_processor() public method

Install a special processing method for COM or APPn markers.
public jpeg_set_marker_processor ( int marker_code, jpeg_decompress_struct routine ) : void
marker_code int
routine jpeg_decompress_struct
return void
        public void jpeg_set_marker_processor(int marker_code, jpeg_decompress_struct.jpeg_marker_parser_method routine)
        {
            if (marker_code == (int)JPEG_MARKER.COM)
                m_process_COM = routine;
            else if (marker_code >= (int)JPEG_MARKER.APP0 && marker_code <= (int)JPEG_MARKER.APP15)
                m_process_APPn[marker_code - (int)JPEG_MARKER.APP0] = routine;
            else
                m_cinfo.ERREXIT(J_MESSAGE_CODE.JERR_UNKNOWN_MARKER, marker_code);
        }