AGX Dynamics  2.37.2.0
Image.h
Go to the documentation of this file.
1 /*
2 Copyright 2007-2024. Algoryx Simulation AB.
3 
4 All AGX source code, intellectual property, documentation, sample code,
5 tutorials, scene files and technical white papers, are copyrighted, proprietary
6 and confidential material of Algoryx Simulation AB. You may not download, read,
7 store, distribute, publish, copy or otherwise disseminate, use or expose this
8 material unless having a written signed agreement with Algoryx Simulation AB, or having been
9 advised so by Algoryx Simulation AB for a time limited evaluation, or having purchased a
10 valid commercial license from Algoryx Simulation AB.
11 
12 Algoryx Simulation AB disclaims all responsibilities for loss or damage caused
13 from using this software, unless otherwise stated in written agreements with
14 Algoryx Simulation AB.
15 */
16 
17 #ifndef AGXIO_IMAGE_H
18 #define AGXIO_IMAGE_H
19 
20 #include <agx/agxPhysics_export.h>
21 
22 #include <agx/Referenced.h>
23 
24 namespace agxIO
25 {
26 
27 
33  {
34  public:
35 
39  COLUMN_MAJOR
40  };
41 
42  Image();
43 
47  unsigned int getWidth() const;
48 
52  unsigned int getHeight() const;
53 
57  unsigned int getChannels() const;
58 
62  unsigned char* getData();
63  const unsigned char* getData() const;
64 
65  int getImageDataMode() const;
66 
70  void setImage(const unsigned int& width, const unsigned int& height,
71  const unsigned int& channels, const int& mode, unsigned char* data);
72  protected:
73 
74  unsigned int m_width;
75  unsigned int m_height;
76  unsigned int m_channels;
77 
78  unsigned char* m_data;
79 
81 
82  virtual ~Image();
83  };
84 
86 }
87 
88 #endif
89 
ImageDataMode
Specify row/column mode.
Definition: Image.h:37
The agxIO namespace contains classes for reading, writing and finding files.
Definition: Material.h:41
agx::ref_ptr< Image > ImageRef
Definition: Image.h:28
#define AGXPHYSICS_EXPORT
#define AGX_DECLARE_POINTER_TYPES(type)
Definition: Referenced.h:254
Base class providing referencing counted objects.
Definition: Referenced.h:119
Pixel data is stored by row.
Definition: Image.h:38
unsigned int m_width
Definition: Image.h:74
int m_imageDataMode
Definition: Image.h:80
unsigned char * m_data
Definition: Image.h:78
unsigned int m_height
Definition: Image.h:75
unsigned int m_channels
Definition: Image.h:76
Class to represent Images.
Definition: Image.h:32