HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
IMG_FileFilterWindow.h
Go to the documentation of this file.
1 /*
2  * PROPRIETARY INFORMATION. This software is proprietary to
3  * Side Effects Software Inc., and is not to be reproduced,
4  * transmitted, or disclosed in any way without written permission.
5  *
6  * NAME: IMG_FileFilterWindow ( IMG Library, C++)
7  *
8  * COMMENTS:
9  *
10  * Implements data windowing abstraction for files.
11  *
12  */
13 
14 #pragma once
15 
16 #ifndef IMG_FILE_FILTER_WINDOW_H
17 #define IMG_FILE_FILTER_WINDOW_H
18 
19 class PXL_FillParms;
20 
21 #include <UT/UT_Rect.h>
22 #include <UT/UT_IntArray.h>
23 #include <UT/UT_ValArray.h>
24 
25 #include "IMG_FileFilter.h"
26 
28 {
29 public:
30  IMG_FileFilterWindow(IMG_File *file_to_filter);
31  virtual ~IMG_FileFilterWindow();
32 
33  virtual const char *className() const { return "IMG_FileFilterWindow"; }
34 
35  void initWindow(const UT_DimRect &user_area);
36 
37  virtual const void *readPlaneScanline(int y, const IMG_Plane &pi);
38 
39  virtual int writePlaneScanline(const void *data, int y,
40  const IMG_Plane &pi);
41 
42  virtual void computeCommonData();
43 
44  virtual int getDeepPixelSamples(int x, int y);
45  virtual bool getDeepPixelPlaneData(int x, int y,
46  const IMG_Plane &plane,
47  float *data);
48  virtual bool getDeepPixelData(int x, int y, float * const *data);
49  virtual bool readDeepPixelData(int x, int y,
51  virtual bool writeDeepPixelData(int x, int y,
52  const PXL_DeepSampleListPtr &p);
53 private:
54 
55  void fillBG(void *buffer, const IMG_Plane &pi,
56  PXL_FillParms *parms);
57  void fillScan(void *buffer, const void *input,
58  const IMG_Plane &pi,
59  IMG_Stat &stat, IMG_Stat &istat);
60  void clearScan(void *buffer, const IMG_Plane &pi);
61 
62  virtual void finishedScanline(int scan);
63 
64  bool computeXY(int &x, int &y);
65 
66  UT_DimRect myInWindow;
67  UT_DimRect myOutWindow;
68  bool myDisjointFlag;
69  fpreal myBGColor[4];
70  bool myStreakFlag;
71 
72  UT_ValArray<PXL_FillParms *> myPlaneFill;
73  UT_ValArray<PXL_FillParms *> myPlaneFillLeft;
74  UT_ValArray<PXL_FillParms *> myPlaneFillRight;
75  UT_IntArray myPlaneScanline;
76 };
77 
78 #endif
virtual const char * className() const
virtual void finishedScanline(int scan)
virtual bool readDeepPixelData(int x, int y, PXL_DeepSampleList &p)
Read a deep pixel.
virtual void computeCommonData()
virtual bool writeDeepPixelData(int x, int y, const PXL_DeepSampleListPtr &p)
virtual int writePlaneScanline(const void *data, int y, const IMG_Plane &pi)
GLint y
Definition: glcorearb.h:102
Describes the format and layout of a single plane in an image The plane specifies the format and name...
Definition: IMG_Plane.h:44
GLuint buffer
Definition: glcorearb.h:659
#define IMG_API
Definition: IMG_API.h:10
virtual bool getDeepPixelData(int x, int y, float *const *data)
Generic interface for reading and writing image files. This class handles the reading and writing of ...
Definition: IMG_File.h:54
GLboolean * data
Definition: glcorearb.h:130
virtual int getDeepPixelSamples(int x, int y)
double fpreal
Definition: SYS_Types.h:270
GLint GLenum GLint x
Definition: glcorearb.h:408
Contains the details of a specific image file, used by IMG_File. This class contains all the high-lev...
Definition: IMG_Stat.h:40
virtual bool getDeepPixelPlaneData(int x, int y, const IMG_Plane &plane, float *data)
virtual const void * readPlaneScanline(int y, const IMG_Plane &pi)