Photon Engine 2.0.0-beta
A physically based renderer.
|
#include "Math/TVector2.h"
#include "Utility/utility.h"
#include "Math/math.h"
#include <Common/primitive_type.h>
#include <array>
#include <cstddef>
#include <stdexcept>
#include <format>
Go to the source code of this file.
Namespaces | |
namespace | ph |
The root for all renderer implementations. | |
namespace | ph::pixel_texture |
Enumerations | |
enum class | ph::pixel_texture::EWrapMode { ph::pixel_texture::Repeat = 0 , ph::pixel_texture::ClampToEdge , ph::pixel_texture::FlippedClampToEdge } |
enum class | ph::pixel_texture::ESampleMode { ph::pixel_texture::Nearest = 0 , ph::pixel_texture::Bilinear , ph::pixel_texture::Trilinear } |
enum class | ph::pixel_texture::EPixelLayout { ph::pixel_texture::RGBA = 0 , ph::pixel_texture::R , ph::pixel_texture::G , ph::pixel_texture::B , ph::pixel_texture::Monochromatic , ph::pixel_texture::A , ph::pixel_texture::RG , ph::pixel_texture::RGB , ph::pixel_texture::BGR , ph::pixel_texture::ARGB , ph::pixel_texture::ABGR , ph::pixel_texture::BGRA } |
Pixel layout of pixel texture. Represent the ordering of pixel components with respect to a color space. The characters RGB does not mean the pixel is in RGB color space. It simply represents pixel components, using R, G, B as placeholders. More... | |
Functions | |
float64 | ph::pixel_texture::uv_to_st_scalar (const float64 inputUV, const EWrapMode wrapMode) |
Transform (u, v) coordinates to (s, t) in [0, 1] according to wrap mode. This overload operates on single channel only. The transformation will preserve texel density as it originally is (e.g, no scaling effect). | |
math::Vector2D | ph::pixel_texture::uv_to_st (const math::Vector2D &inputUV, const EWrapMode wrapModeS, const EWrapMode wrapModeT) |
Transform (u, v) coordinates to (s, t) in [0, 1] according to wrap mode. The transformation will preserve texel density as it originally is (e.g, no scaling effect). | |
std::size_t | ph::pixel_texture::num_pixel_elements (const EPixelLayout layout) |
std::size_t | ph::pixel_texture::alpha_channel_index (const EPixelLayout layout) |