digiKam
jpegwin.h
Go to the documentation of this file.
1 /* ============================================================
2  *
3  * This file is a part of digiKam project
4  * https://www.digikam.org
5  *
6  * Date : 2008-11-22
7  * Description : some workaround functions to read jpeg
8  * files without relying on libjpeg
9  *
10  * Copyright (C) 2008 by Patrick Spendrin <ps ml at gmx dot de>
11  *
12  * This program is free software; you can redistribute it
13  * and/or modify it under the terms of the GNU General
14  * Public License as published by the Free Software Foundation;
15  * either version 2, or (at your option)
16  * any later version.
17  *
18  * This program is distributed in the hope that it will be useful,
19  * but WITHOUT ANY WARRANTY; without even the implied warranty of
20  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21  * GNU General Public License for more details.
22  *
23  * ============================================================ */
24 
25 #ifndef DIGIKAM_JPEG_WIN_H
26 #define DIGIKAM_JPEG_WIN_H
27 
28 // C+ includes
29 
30 #include <cstdio>
31 #include <cstdlib>
32 
33 // Local includes
34 
35 extern "C"
36 {
37 #include "iccjpeg.h"
38 }
39 
40 namespace Digikam
41 {
42 
43 namespace JPEGUtils
44 {
45 
46 typedef struct
47 {
48  struct jpeg_source_mgr pub;
49  JOCTET eoi[2];
51 
52 void init_source (j_decompress_ptr cinfo);
53 boolean fill_input_buffer (j_decompress_ptr cinfo);
54 void skip_input_data (j_decompress_ptr cinfo, long nbytes);
55 void term_source (j_decompress_ptr cinfo);
56 void jpeg_memory_src (j_decompress_ptr cinfo, const JOCTET* buffer, size_t bufsize);
57 
58 } // namespace JPEGUtils
59 
60 } // namespace Digikam
61 
62 #endif // DIGIKAM_JPEG_WIN_H
boolean fill_input_buffer(j_decompress_ptr cinfo)
Definition: jpegwin.cpp:42
void term_source(j_decompress_ptr)
Definition: jpegwin.cpp:73
void skip_input_data(j_decompress_ptr cinfo, long nbytes)
Definition: jpegwin.cpp:56
void init_source(j_decompress_ptr)
Definition: jpegwin.cpp:38
void jpeg_memory_src(j_decompress_ptr cinfo, const JOCTET *buffer, size_t bufsize)
Definition: jpegwin.cpp:77
Definition: datefolderview.cpp:43