OpenSceneGraph 3.6.5
MultiTextureControl
Go to the documentation of this file.
1/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield
2 *
3 * This library is open source and may be redistributed and/or modified under
4 * the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
5 * (at your option) any later version. The full license is in LICENSE file
6 * included with this distribution, and on the openscenegraph.org website.
7 *
8 * This library is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * OpenSceneGraph Public License for more details.
12*/
13
14#ifndef OSGFX_MULTITEXTURECONTROL
15#define OSGFX_MULTITEXTURECONTROL
16
17#include <osg/Group>
18
19#include <osgFX/Export>
20
21namespace osgFX
22{
28 public:
29
32
34
36
39 const TextureWeights* getTextureWeights() const { return _textureWeights.get(); }
40
41 void setTextureWeight(unsigned int unit, float weight);
42 float getTextureWeight(unsigned int unit) const { return (unit<_textureWeights->size()) ? (*_textureWeights)[unit] : 0.0f; }
43 unsigned int getNumTextureWeights() const { return _textureWeights->size(); }
44
45 void setUseTexEnvCombine(bool flag) { _useTexEnvCombine = flag; }
46 bool getUseTexEnvCombine() const { return _useTexEnvCombine; }
47
50
51 protected:
52
54 MultiTextureControl& operator = (const MultiTextureControl&) { return *this; }
55
57
59
62
63 };
64
65}
66
67#endif
TemplateArray< GLfloat, Array::FloatArrayType, 1, GL_FLOAT > FloatArray
Definition Array:421
The osgFX library is a NodeKit that extends the core scene graph to provide a special effects framewo...
Definition AnisotropicLighting:25
Copy Op(erator) used to control whether shallow or deep copy is used during copy construction and clo...
Definition CopyOp:41
@ SHALLOW_COPY
Definition CopyOp:47
General group node which maintains a list of children.
Definition Group:29
Smart pointer for handling referenced counted objects.
Definition ref_ptr:32
MultiTextureControl(const MultiTextureControl &copy, const osg::CopyOp &copyop=osg::CopyOp::SHALLOW_COPY)
void setUseTextureWeightsUniform(bool flag)
Definition MultiTextureControl:48
unsigned int getNumTextureWeights() const
Definition MultiTextureControl:43
virtual ~MultiTextureControl()
Definition MultiTextureControl:53
bool getUseTextureWeightsUniform() const
Definition MultiTextureControl:49
META_Node(osgFX, MultiTextureControl)
osg::FloatArray TextureWeights
Definition MultiTextureControl:35
void setTextureWeights(TextureWeights *twl)
Definition MultiTextureControl:37
bool _useTextureWeightsUniform
Definition MultiTextureControl:61
void setTextureWeight(unsigned int unit, float weight)
osg::ref_ptr< TextureWeights > _textureWeights
Definition MultiTextureControl:58
bool getUseTexEnvCombine() const
Definition MultiTextureControl:46
float getTextureWeight(unsigned int unit) const
Definition MultiTextureControl:42
TextureWeights * getTextureWeights()
Definition MultiTextureControl:38
bool _useTexEnvCombine
Definition MultiTextureControl:60
void setUseTexEnvCombine(bool flag)
Definition MultiTextureControl:45
const TextureWeights * getTextureWeights() const
Definition MultiTextureControl:39
#define OSGFX_EXPORT
Definition Export:27

osg logo
Generated at Sun Jul 20 2025 00:00:00 for the OpenSceneGraph by doxygen 1.14.0.