Pioneer
Loading...
Searching...
No Matches
src
scenegraph
ColorMap.h
Go to the documentation of this file.
1
// Copyright © 2008-2024 Pioneer Developers. See AUTHORS.txt for details
2
// Licensed under the terms of the GPL v3. See licenses/GPL-3.txt
3
4
#ifndef _SCENEGRAPH_COLORMAP_H
5
#define _SCENEGRAPH_COLORMAP_H
6
/*
7
* Color look-up texture generator for newmodel pattern system
8
*/
9
#include "
Color.h
"
10
#include "
graphics/Texture.h
"
11
12
namespace
Graphics
{
13
class
Renderer;
14
}
15
16
namespace
SceneGraph
{
17
18
class
ColorMap
{
19
public
:
20
ColorMap
();
21
Graphics::Texture
*
GetTexture
();
22
void
Generate
(
Graphics::Renderer
*r,
const
Color
&a,
const
Color
&b,
const
Color
&c);
23
void
SetSmooth
(
bool
);
24
25
private
:
26
void
AddColor(
int
width,
const
Color
&c, std::vector<Uint8> &out);
27
28
bool
m_smooth;
29
RefCountedPtr<Graphics::Texture>
m_texture;
30
};
31
32
}
// namespace SceneGraph
33
34
#endif
Color.h
Texture.h
Graphics::Renderer
Definition:
Renderer.h:45
Graphics::Texture
Definition:
Texture.h:103
RefCountedPtr
Definition:
RefCounted.h:36
SceneGraph::ColorMap
Definition:
ColorMap.h:18
SceneGraph::ColorMap::SetSmooth
void SetSmooth(bool)
Definition:
ColorMap.cpp:50
SceneGraph::ColorMap::Generate
void Generate(Graphics::Renderer *r, const Color &a, const Color &b, const Color &c)
Definition:
ColorMap.cpp:30
SceneGraph::ColorMap::ColorMap
ColorMap()
Definition:
ColorMap.cpp:10
SceneGraph::ColorMap::GetTexture
Graphics::Texture * GetTexture()
Definition:
ColorMap.cpp:15
Graphics
Definition:
Background.h:14
SceneGraph
Definition:
CityOnPlanet.h:32
Color4ub
Definition:
Color.h:66
Generated by
1.9.6