MrSID Decode SDK for Raster Reference Manual  9.5.5.5244
lti_imageWriter.h
Go to the documentation of this file.
1 //
2 // This code is property of Celartem, Inc dba Extensis.
3 // Copyright (c) 1995-2023. All rights reserved.
4 // Use permitted only under license from Extensis.
5 //
6 /* PUBLIC */
7 
8 #ifndef LTI_IMAGEWRITER_H
9 #define LTI_IMAGEWRITER_H
10 
11 // lt_lib_mrsid_core
12 #include "lti_types.h"
13 
14 #include <stdlib.h>
15 
16 LT_BEGIN_LIZARDTECH_NAMESPACE
17 
18 
27 {
28  LT_DISALLOW_COPY_CONSTRUCTOR(LTIImageWriter);
29 public:
30  virtual ~LTIImageWriter();
31 
48  virtual LT_STATUS write(const LTIScene& scene);
49 
64  virtual LT_STATUS writeBegin(const LTIScene& scene) = 0;
65 
79  virtual LT_STATUS writeStrip(LTISceneBuffer& stripBuffer,
80  const LTIScene& stripScene) = 0;
81 
93  virtual LT_STATUS writeEnd(void) = 0;
94 
106  virtual LT_STATUS deleteOutput(void) = 0;
107 
119 
128 
139  virtual lt_uint32 getDefaultStripHeight(void) const;
140 
150  virtual lt_int64 getEncodingCost(const LTIScene& scene) const;
151 
167 
183 
184 
191  const LTIImageStage *getSourceImageStage(void) const;
192 
207 
222 
233  virtual LT_STATUS setEncodingApplication(const char *name,
234  const char *version,
235  const char *comment = nullptr);
236 protected:
248 
250 
251 private:
252  LT_STATUS checkDelegates(const LTIScene& fullScene,
253  const LTIScene* currScene,
254  bool atEnd);
255 
256  lt_uint32 m_stripHeight;
257 
258  LTIProgressDelegate* m_progressDelegate;
259  LTIInterruptDelegate* m_interruptDelegate;
260 };
261 
262 
263 LT_END_LIZARDTECH_NAMESPACE
264 
265 
266 #endif // LTI_IMAGEWRITER_H
lt_uint32 LT_STATUS
An integral status code.
Definition: lt_status.h:30
unsigned int lt_uint32
unsigned 32-bit integer
Definition: lt_types.h:44
long long int lt_int64
signed 64-bit integer
Definition: lt_types.h:57
This file contains a number of enums, typedefs, etc, that are used throughout the MrSID SDK.
interrupt delegate (callback) base class
Definition: lti_delegates.h:35
progress delegate (callback) base class
Definition: lti_delegates.h:68
abstract class for decoding from an image
abstract class for implementing an image writer
virtual LT_STATUS deleteOutput(void)=0
clean up a failed encode (write) operation
virtual lt_int64 getEncodingCost(const LTIScene &scene) const
get the cost to encode the scene
virtual LT_STATUS writeEnd(void)=0
complete an encode (write) operation
lt_uint32 getStripHeight(void) const
get the stripheight for the encode
LT_STATUS init(LTIImageStage *imageStage)
initialization function
virtual LT_STATUS writeBegin(const LTIScene &scene)=0
begin an encode (write) operation
virtual LT_STATUS setEncodingApplication(const char *name, const char *version, const char *comment=nullptr)
set name and version of the creating application
LT_STATUS setStripHeight(lt_uint32 stripHeight)
set the stripheight for the encode
virtual LT_STATUS writeStrip(LTISceneBuffer &stripBuffer, const LTIScene &stripScene)=0
encode one strip of the scene
void setProgressDelegate(LTIProgressDelegate *delegate)
set progress delegate
LTIImageStage * m_image
virtual LT_STATUS write(const LTIScene &scene)
write (encode) a scene to the output format
LTIProgressDelegate * getProgressDelegate(void) const
get progress delegate
LT_STATUS writeCleanup(LT_STATUS sts)
virtual lt_uint32 getDefaultStripHeight(void) const
get the preferred stripheight for the encode
const LTIImageStage * getSourceImageStage(void) const
get the source image stage
LTIInterruptDelegate * getInterruptDelegate(void) const
get interrupt delegate
virtual ~LTIImageWriter()
LTIImageWriter(void)
void setInterruptDelegate(LTIInterruptDelegate *delegate)
set interrupt delegate
representation of a scene
Definition: lti_scene.h:60
class to hold data passed between image stages

Extensis