Coin Logo http://www.sim.no/
http://www.coin3d.org/

SoGLBigImage.h
1 #ifndef COIN_SOGLBIGIMAGE_H
2 #define COIN_SOGLBIGIMAGE_H
3 
4 /**************************************************************************\
5  *
6  * This file is part of the Coin 3D visualization library.
7  * Copyright (C) by Kongsberg Oil & Gas Technologies.
8  *
9  * This library is free software; you can redistribute it and/or
10  * modify it under the terms of the GNU General Public License
11  * ("GPL") version 2 as published by the Free Software Foundation.
12  * See the file LICENSE.GPL at the root directory of this source
13  * distribution for additional information about the GNU GPL.
14  *
15  * For using Coin with software that can not be combined with the GNU
16  * GPL, and for taking advantage of the additional benefits of our
17  * support services, please contact Kongsberg Oil & Gas Technologies
18  * about acquiring a Coin Professional Edition License.
19  *
20  * See http://www.coin3d.org/ for more information.
21  *
22  * Kongsberg Oil & Gas Technologies, Bygdoy Alle 5, 0257 Oslo, NORWAY.
23  * http://www.sim.no/ sales@sim.no coin-support@coin3d.org
24  *
25 \**************************************************************************/
26 
27 #include <Inventor/SbBasic.h>
28 #include <Inventor/SbVec2s.h>
29 #include <Inventor/SbVec2f.h>
30 #include <Inventor/misc/SoGLImage.h>
31 
32 class COIN_DLL_API SoGLBigImage : public SoGLImage {
33  typedef SoGLImage inherited;
34 
35 public:
36 
37  SoGLBigImage();
38  virtual void unref(SoState * state = NULL);
39 
40  static SoType getClassTypeId(void);
41  virtual SoType getTypeId(void) const ;
42 
43  virtual void setData(const SbImage * image,
44  const Wrap wraps = REPEAT,
45  const Wrap wrapt = REPEAT,
46  const float quality = 0.5f,
47  const int border = 0,
48  SoState * createinstate = NULL);
49 
50  virtual void setData(const SbImage * image,
51  const Wrap wraps,
52  const Wrap wrapt,
53  const Wrap wrapr,
54  const float quality = 0.5f,
55  const int border = 0,
56  SoState * createinstate = NULL);
57 
58  int initSubImages(const SbVec2s & subimagesize) const;
59  void handleSubImage(const int idx, SbVec2f & start, SbVec2f & end,
60  SbVec2f & tcmul);
61  void applySubImage(SoState * state, const int idx, const float quality,
62  const SbVec2s & projsize);
63  SbBool exceededChangeLimit(void);
64  static int setChangeLimit(const int limit);
65 
66  // will return NULL to avoid that SoGLTextureImageElement will
67  // update the texture state.
68  virtual SoGLDisplayList * getGLDisplayList(SoState * state);
69 
70 
71 protected:
72  virtual void unrefOldDL(SoState * state, const uint32_t maxage);
73 
74 public:
75  static void initClass(void);
76 
77 private:
78  virtual ~SoGLBigImage();
79 
80  class SoGLBigImageP * pimpl;
81  friend class SoGLBigImageP;
82 };
83 
84 #endif // !COIN_SOGLBIGIMAGE_H
The SbVec2f class is a 2 dimensional vector with floating point coordinates.This vector class is used...
Definition: SbVec2f.h:39
Wrap
Definition: SoGLImage.h:54
static void initClass(void)
Definition: SoGLImage.cpp:799
virtual SoGLDisplayList * getGLDisplayList(SoState *state)
Definition: SoGLImage.cpp:1233
The SoState class manages the Coin scenegraph traversal state data.The SoState class is used by actio...
Definition: SoState.h:35
void setData(const unsigned char *bytes, const SbVec2s &size, const int numcomponents, const Wrap wraps=REPEAT, const Wrap wrapt=REPEAT, const float quality=0.5f, const int border=0, SoState *createinstate=NULL)
Definition: SoGLImage.cpp:1134
The SoGLBigImage class is used to handle 2D OpenGL textures of any size.
Definition: SoGLBigImage.h:32
virtual SoType getTypeId(void) const
Definition: SoGLImage.cpp:852
static SoType getClassTypeId(void)
Definition: SoGLImage.cpp:838
virtual void unrefOldDL(SoState *state, const uint32_t maxage)
Definition: SoGLImage.cpp:1358
The SoGLDisplayList class stores and manages OpenGL display lists.The TEXTURE_OBJECT type is not dire...
Definition: SoGLDisplayList.h:34
virtual void unref(SoState *state=NULL)
Definition: SoGLImage.cpp:1192
The SoGLImage class is used to handle OpenGL 2D/3D textures.
Definition: SoGLImage.h:44
The SbImage class is an abstract datatype for 2D and 3D images.Be aware that this class is an extensi...
Definition: SbImage.h:37
The SbVec2s class is a 2 dimensional vector with short integer coordinates.This vector class is used ...
Definition: SbVec2s.h:41
The SoType class is the basis for the run-time type system in Coin.Many of the classes in the Coin li...
Definition: SoType.h:50

Copyright © 1998-2010 by Kongsberg Oil & Gas Technologies. All rights reserved.

Generated on Fri Sep 9 2016 for Coin by Doxygen 1.8.5.