2004-01-15 05:26:47 +08:00
|
|
|
/*
|
|
|
|
* ZoneMinder Jpeg Interface, $Date$, $Revision$
|
2008-07-25 17:33:23 +08:00
|
|
|
* Copyright (C) 2001-2008 Philip Coombes
|
2004-01-15 05:26:47 +08:00
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU General Public License
|
|
|
|
* as published by the Free Software Foundation; either version 2
|
|
|
|
* of the License, or (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program; if not, write to the Free Software
|
2016-12-26 23:23:16 +08:00
|
|
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
2004-01-15 05:26:47 +08:00
|
|
|
*/
|
|
|
|
|
2005-10-18 05:45:06 +08:00
|
|
|
#include <setjmp.h>
|
|
|
|
|
2004-01-15 05:26:47 +08:00
|
|
|
#include "jinclude.h"
|
|
|
|
#include "jpeglib.h"
|
|
|
|
#include "jerror.h"
|
|
|
|
|
2011-06-21 17:19:10 +08:00
|
|
|
// Stop complaints about deuplicate definitions
|
|
|
|
#undef HAVE_STDLIB_H
|
|
|
|
#undef HAVE_STDDEF_H
|
|
|
|
|
|
|
|
extern "C"
|
|
|
|
{
|
2016-12-29 17:31:05 +08:00
|
|
|
/* Stuff for overridden error handlers */
|
2005-10-18 05:45:06 +08:00
|
|
|
struct zm_error_mgr
|
|
|
|
{
|
2016-04-04 22:11:48 +08:00
|
|
|
struct jpeg_error_mgr pub;
|
|
|
|
jmp_buf setjmp_buffer;
|
2005-10-18 05:45:06 +08:00
|
|
|
};
|
|
|
|
|
|
|
|
typedef struct zm_error_mgr *zm_error_ptr;
|
|
|
|
|
|
|
|
void zm_jpeg_error_exit( j_common_ptr cinfo );
|
2005-11-20 02:31:59 +08:00
|
|
|
void zm_jpeg_emit_message( j_common_ptr cinfo, int msg_level );
|
2005-10-18 05:45:06 +08:00
|
|
|
|
2004-06-30 22:32:45 +08:00
|
|
|
// Prototypes for memory compress/decompression object */
|
2010-01-20 22:43:54 +08:00
|
|
|
void zm_jpeg_mem_src(j_decompress_ptr cinfo, const JOCTET *inbuffer, int inbuffer_size );
|
|
|
|
void zm_jpeg_mem_dest(j_compress_ptr cinfo, JOCTET *outbuffer, int *outbuffer_size );
|
2011-07-05 23:23:02 +08:00
|
|
|
|
2011-07-06 23:39:16 +08:00
|
|
|
void zm_use_std_huff_tables( j_decompress_ptr cinfo );
|
2011-06-21 17:19:10 +08:00
|
|
|
}
|