Basic Image AlgorithmS Library
2.8.0
|
Helper class for creating primitives. More...
#include <OpenGLFramework/Utils/Primitives.hh>
Static Public Member Functions | |
static void | AddPlain2DQuadVertices (float *supplementedArray, unsigned int offset, unsigned int stride) |
Vertex Order: 3–2 | | 0–1 . More... | |
static void | AddPlain2DTextureCoordinates (float *supplementedArray, unsigned int offset, unsigned int stride, bool flip=false) |
Vertex Order: 3–2 | | 0–1 . More... | |
static void | AddRelativeQuadPatches (const unsigned int referenceWidth, const unsigned int referenceHeight, const std::vector< unsigned int > &posX, const std::vector< unsigned int > &posY, const unsigned int hw, BIAS::glfVertexBuffer &vb, BIAS::glfElementBuffer &eb, const bool flip) |
Calculates 2D patches in the image plane suited for rendering with identity rendering parameters, patches are valid for a reference resolution and symmetrically centered around a pixel position. More... | |
static void | AddRelativeQuadPatchOverImageLine (const unsigned int referenceWidth, const unsigned int referenceHeight, const unsigned int linePos, const unsigned int hw, BIAS::glfVertexBuffer &vb, BIAS::glfElementBuffer &eb, const bool flip) |
Adds a patch suited for rendering with identity rendering parameters that exactly fits over an image line in the image plane. More... | |
static void | LocalNormalizedPointCloud (const BIAS::ProjectionParametersPerspective &ppp, BIAS::glfVertexBuffer &vb, BIAS::glfElementBuffer &eb, bool normalizeZ, bool invertS) |
static void | LocalNormalizedTriangleMesh (const BIAS::ProjectionParametersPerspective &pppSource, BIAS::glfVertexBuffer &vb, BIAS::glfElementBuffer &eb, bool normalizeZ, bool invertS) |
static void | LocalNormalizedTriangleStrip (const BIAS::ProjectionParametersPerspective &pppSource, BIAS::glfVertexBuffer &vb, BIAS::glfElementBuffer &eb, bool normalizeZ=false) |
static void | LocalNormalizedVertexCloud (const BIAS::ProjectionParametersPerspective &ppp, BIAS::glfVertexBuffer &vb, bool normalizeZ, bool invertS) |
Generates a vertex list of textured 3d vertices. More... | |
static void | LocalPerspectivePatches (const BIAS::ProjectionParametersPerspective &ppp, const std::vector< unsigned int > &posX, const std::vector< unsigned int > &posY, const unsigned int hw, glfVertexBuffer &vb, glfElementBuffer &eb) |
static void | LocalPerspectivePatchOverLine (const BIAS::ProjectionParametersPerspective &ppp, const unsigned int posY, const unsigned int hw, glfVertexBuffer &vb, glfElementBuffer &eb) |
Patch encloses a region around a complete image line. More... | |
static void | LocalPerspectiveQuad (const BIAS::ProjectionParametersPerspective &ppp, BIAS::glfVertexBuffer &vb, BIAS::glfElementBuffer &eb) |
static void | PlainQuad2DWithTexture2D (BIAS::glfVertexBuffer &vb, BIAS::glfElementBuffer &eb, bool flip=false) |
Vertex Order: 3–2 | | 0–1 . More... | |
Helper class for creating primitives.
Definition at line 43 of file Primitives.hh.
|
static |
Vertex Order:
3–2
| |
0–1
.
Vertex Coordinates:
(-1, 1) – (1, 1)
| |
| |
| |
(-1,-1) – (1, -1)
Definition at line 287 of file Primitives.cpp.
|
static |
Vertex Order:
3–2
| |
0–1
.
unflipped texture coordinates:
(0,1) – (1,1)
| |
| |
(0,0) – (1,0)
Definition at line 315 of file Primitives.cpp.
|
static |
Calculates 2D patches in the image plane suited for rendering with identity rendering parameters, patches are valid for a reference resolution and symmetrically centered around a pixel position.
Definition at line 107 of file Primitives.cpp.
References BIAS::glfVertexFormat::AddAttribute(), BIAS::glfVertexFormat::ATTRIB_POSITION, BIAS::glfVertexFormat::ATTRIB_TEXCOORD, BIAS::glfVertexBuffer::Create(), and BIAS::glfElementBuffer::Create().
Referenced by AddRelativeQuadPatchOverImageLine(), and BIAS::SimpleMultiPassFragmentShader::EvaluateOnlyPatches().
|
static |
Adds a patch suited for rendering with identity rendering parameters that exactly fits over an image line in the image plane.
Definition at line 39 of file Primitives.cpp.
References BIAS::glfVertexFormat::AddAttribute(), AddRelativeQuadPatches(), BIAS::glfVertexFormat::ATTRIB_POSITION, BIAS::glfVertexFormat::ATTRIB_TEXCOORD, BIAS::glfVertexBuffer::Create(), and BIAS::glfElementBuffer::Create().
Referenced by BIAS::SimpleMultiPassFragmentShader::EvaluateOnlyLine().
|
static |
Definition at line 577 of file Primitives.cpp.
References BIAS::glfElementBuffer::Create(), and BIAS::ProjectionParametersBase::GetImageSize().
|
static |
Definition at line 635 of file Primitives.cpp.
References BIAS::glfElementBuffer::Create(), and BIAS::ProjectionParametersBase::GetImageSize().
|
static |
Definition at line 595 of file Primitives.cpp.
References BIAS::glfElementBuffer::Create(), and BIAS::ProjectionParametersBase::GetImageSize().
|
static |
Generates a vertex list of textured 3d vertices.
Their vertex coordinates can be interpreted as the optical ray directions belonging to their respective pixel centers in camera coordinates. The vertex array is constructed row wise starting with the top pixel row.
Definition at line 532 of file Primitives.cpp.
References BIAS::glfVertexFormat::AddAttribute(), BIAS::glfVertexFormat::ATTRIB_POSITION, BIAS::glfVertexFormat::ATTRIB_TEXCOORD, BIAS::glfVertexBuffer::Create(), BIAS::ProjectionParametersBase::GetImageSize(), BIAS::HomgPoint2D, and BIAS::ProjectionParametersPerspective::UnProjectLocal().
|
static |
Definition at line 401 of file Primitives.cpp.
References BIAS::glfVertexFormat::AddAttribute(), BIAS::glfVertexFormat::ATTRIB_POSITION, BIAS::glfVertexBuffer::Create(), BIAS::glfElementBuffer::Create(), BIAS::ProjectionParametersBase::GetImageSize(), BIAS::HomgPoint2D::Set(), and BIAS::ProjectionParametersPerspective::UnProjectLocal().
|
static |
Patch encloses a region around a complete image line.
Definition at line 467 of file Primitives.cpp.
References BIAS::glfVertexFormat::AddAttribute(), BIAS::glfVertexFormat::ATTRIB_POSITION, BIAS::glfVertexBuffer::Create(), BIAS::glfElementBuffer::Create(), BIAS::ProjectionParametersBase::GetImageSize(), BIAS::HomgPoint2D::Set(), and BIAS::ProjectionParametersPerspective::UnProjectLocal().
|
static |
Definition at line 343 of file Primitives.cpp.
References BIAS::glfVertexFormat::AddAttribute(), BIAS::glfVertexFormat::ATTRIB_POSITION, BIAS::glfVertexBuffer::Create(), BIAS::glfElementBuffer::Create(), BIAS::ProjectionParametersBase::GetImageSize(), BIAS::HomgPoint2D::Set(), and BIAS::ProjectionParametersPerspective::UnProjectLocal().
|
static |
Vertex Order:
3–2
| |
0–1
.
Vertex Coordinates:
(-1, 1) – (1, 1)
| |
| |
| |
(-1,-1) – (1, -1)
unflipped texture coordinates:
(0,1) – (1,1)
| |
| |
(0,0) – (1,0)
Generates the quad.
Definition at line 263 of file Primitives.cpp.
References BIAS::glfVertexFormat::AddAttribute(), BIAS::glfVertexFormat::ATTRIB_POSITION, BIAS::glfVertexFormat::ATTRIB_TEXCOORD, BIAS::glfVertexBuffer::Create(), and BIAS::glfElementBuffer::Create().
Referenced by BIAS::PlainPerPixelProcessing::InitPrimitiveData_(), BIAS::PerPixelProcessingBase::InitPrimitiveData_(), and BIAS::TemplateSpecializedBatch::InitPrimitiveData_().