VR-Forces 4.6 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
DtOsgTextureBufferObjectApplyAttribute.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 2014 MAK Technologies, Inc.
3 ** All rights reserved.
4 ******************************************************************************/
5 
9 
10 #pragma once
11 
12 #include <vrvOsg/vrvOsg.h>
13 
14 #include <map>
15 
16 #include <osg/StateAttribute>
17 
18 namespace osg
19 {
20  class State;
21 }
22 
23 namespace makVrv
24 {
25  class DtGlTextureBufferObject;
26 
27  class DT_DLL_VRVOSG TextureBufferObjectApplyAttribute : public osg::StateAttribute
28  {
29  public:
31 
32  void addTextureBuffferObject(size_t index, DtGlTextureBufferObject* texture);
33  DtGlTextureBufferObject* getTextureBufferObject(size_t index);
34  void removeTextureBufferObject(size_t index, DtGlTextureBufferObject* texture);
35 
36  TextureBufferObjectApplyAttribute(const TextureBufferObjectApplyAttribute& copy, const osg::CopyOp& copyOp =
37  osg::CopyOp::SHALLOW_COPY);
38 
40 
41  virtual void apply(osg::State& state) const;
42 
43  virtual int compare(const StateAttribute& sa) const;
44 
45  virtual void releaseGLObjects(osg::State* state/* =0 */) const;
46 
47  META_StateAttribute(osg, TextureBufferObjectApplyAttribute, osg::StateAttribute::Type(TRANSFORMFEEDBACKBUFFERBINDING+2))
48  private:
49  typedef std::map<size_t, DtGlTextureBufferObject*> MapTexUnitToTextureBufferObjects;
50  MapTexUnitToTextureBufferObjects myMapTexUnitToTextures;
51  };
52 }

Document ID: Generated on Thu Apr 12 03:15:37 EDT 2018 from SVN revision 187986
Copyright © 2005-2018 VT MÄK. All Rights Reserved (www.mak.com)