OGLplus  (0.59.0) a C++ wrapper for rendering APIs

vertex_attrib.hpp File Reference
#include "../bitfield.hpp"
#include "../reflect/map_enumerators.hpp"
#include "../types.hpp"
#include <array>
#include <cstdint>
#include <type_traits>
#include <utility>

Go to the source code of this file.

Classes

class  eagine::shapes::vertex_attrib_variant
 Class designating an vertex attribute variant in a shape generator. More...
 

Namespaces

 eagine
 Common code is placed in this namespace.
 
 eagine::shapes
 Shape generator and loader code is placed in this namespace.
 

Typedefs

using eagine::shapes::vertex_attrib_bits = bitfield< vertex_attrib_kind >
 Alias for vertex_attrib_kind bitfield type.
 
template<std::size_t N>
using eagine::shapes::vertex_attrib_variants = std::array< const vertex_attrib_variant, N >
 Array of several vertex attribute variant instances. More...
 

Enumerations

enum  eagine::shapes::vertex_attrib_kind : std::uint16_t {
  eagine::shapes::vertex_attrib_kind::object_id, eagine::shapes::vertex_attrib_kind::position, eagine::shapes::vertex_attrib_kind::normal, eagine::shapes::vertex_attrib_kind::tangential,
  eagine::shapes::vertex_attrib_kind::bitangential, eagine::shapes::vertex_attrib_kind::pivot, eagine::shapes::vertex_attrib_kind::pivot_pivot, eagine::shapes::vertex_attrib_kind::vertex_pivot,
  eagine::shapes::vertex_attrib_kind::box_coord, eagine::shapes::vertex_attrib_kind::face_coord, eagine::shapes::vertex_attrib_kind::wrap_coord, eagine::shapes::vertex_attrib_kind::color,
  eagine::shapes::vertex_attrib_kind::weight, eagine::shapes::vertex_attrib_kind::occlusion, eagine::shapes::vertex_attrib_kind::polygon_id, eagine::shapes::vertex_attrib_kind::material_id
}
 Shape vertex attribute kind enumeration. More...
 

Functions

static constexpr auto eagine::shapes::all_vertex_attrib_bits () noexcept -> vertex_attrib_bits
 Returns vertex_attrib_bits value with all bits set.
 
static constexpr auto eagine::shapes::operator| (vertex_attrib_kind a, vertex_attrib_kind b) noexcept -> vertex_attrib_bits
 Bitwise-or operator for vertex_attrib_kind bits.
 
static constexpr auto eagine::shapes::operator/ (vertex_attrib_kind attrib, span_size_t variant_index) noexcept -> vertex_attrib_variant
 Operator for constructing of vertex_attrib_variant from kind and index.
 
static constexpr auto eagine::shapes::operator+ (vertex_attrib_variant a) noexcept -> vertex_attrib_variants< 1 >
 Operator for creating of single element array of vertex attrib variant. More...
 
static constexpr auto eagine::shapes::operator+ (vertex_attrib_variant a, vertex_attrib_variant b) noexcept -> vertex_attrib_variants< 2 >
 Operator for creating of two element array of vertex attrib variants. More...
 
template<std::size_t N>
static constexpr auto eagine::shapes::operator+ (const vertex_attrib_variants< N > &a, vertex_attrib_variant b) noexcept -> vertex_attrib_variants< N+1 >
 Operator for concatenation of vertex attrib variants into an array. More...
 
template<std::size_t N>
static auto eagine::shapes::get_attrib_bits (const vertex_attrib_variants< N > &vaals) noexcept -> vertex_attrib_bits
 Extracts vertex attribute kind bits from and vertex attribute variants array. More...
 
static auto eagine::shapes::attrib_values_per_vertex (vertex_attrib_kind attr) noexcept -> span_size_t
 Gets the default number of values per vertex for an attribute kind.
 
static auto eagine::shapes::attrib_values_per_vertex (vertex_attrib_variant vav) noexcept
 Gets the default number of values per vertex for an attribute variant.
 

Detailed Description

Copyright Matus Chochlik. Distributed under the Boost Software License, Version 1.0. See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt


Copyright © 2015-2021 Matúš Chochlík.
<chochlik -at -gmail.com>
Documentation generated on Tue Apr 13 2021 by Doxygen (version 1.8.17).