gramods
Loading...
Searching...
No Matches
YuvDecodeTexture.hh
1
2
3#ifndef GRAMODS_GRAPHICS_YUVDECODETEXTURE
4#define GRAMODS_GRAPHICS_YUVDECODETEXTURE
5
6// Required before gmCore/OFactory.hh for some compilers
7#include <gmCore/io_float.hh>
8#include <gmCore/io_eigen.hh>
9
10#include <gmGraphics/Texture.hh>
11
12#include <gmCore/OFactory.hh>
13
14#include <memory>
15
16BEGIN_NAMESPACE_GMGRAPHICS;
17
21class YuvDecodeTexture
22 : public gmGraphics::Texture {
23
24public:
25
26 YuvDecodeTexture();
27
31 std::optional<TextureData> updateTexture(size_t frame_number,
32 Eye eye) override;
33
37 void setTexture(std::shared_ptr<Texture> texture);
38
47 void setYuvToRgb(Eigen::Matrix3f m);
48
55
61 void traverse(Visitor *visitor) override;
62
63 GM_OFI_DECLARE;
64
65private:
66
67 struct Impl;
68 std::unique_ptr<Impl> _impl;
69};
70
71END_NAMESPACE_GMGRAPHICS;
72
73#endif
The base of classes providing texture data for rendering.
Definition Texture.hh:18
void traverse(Visitor *visitor) override
Propagates the specified visitor.
Definition YuvDecodeTexture.cpp:157
void setUvRange(gmCore::float2 v)
Sets the range of the UV values.
Definition YuvDecodeTexture.cpp:153
void setYuvToRgb(Eigen::Matrix3f m)
Sets the conversion matrix from YUV space to RGB.
Definition YuvDecodeTexture.cpp:149
void setTexture(std::shared_ptr< Texture > texture)
Sets the texture to decode.
Definition YuvDecodeTexture.cpp:145
std::optional< TextureData > updateTexture(size_t frame_number, Eye eye) override
Definition YuvDecodeTexture.cpp:141
std::array< float, 2 > float2
Array of 2 float.
Definition io_float.hh:12
The visitor of a design pattern for automatic traversal.
Definition Object.hh:75
An indexed eye that can be rendered.
Definition Eye.hh:20
Definition YuvDecodeTexture.cpp:18