Photon Engine C API 2.0.0-beta
A physically based renderer.
Loading...
Searching...
No Matches
api_helpers.h
Go to the documentation of this file.
1#pragma once
2
3#include "ph_c_core_types.h"
4
5#include <Utility/TSpan.h>
6#include <Core/Renderer/ERegionStatus.h>
7
8#include <cstddef>
9#include <bit>
10
11namespace ph { class PictureMeta; }
12namespace ph { class ByteBuffer; }
13namespace ph { class RenderRegionStatus; }
14
15namespace ph
16{
17
18bool is_reversing_bytes_needed(PhEndian desiredEndianness);
19
20PhFrameRegionStatus to_frame_region_status(ERegionStatus regionStatus);
21void to_frame_region_info(const RenderRegionStatus& regionStatus, PhFrameRegionInfo* out_regionInfo);
22
23PictureMeta make_picture_meta(const PhFrameSaveInfo& saveInfo);
24
34template<typename T>
36 std::size_t numArrayElements,
37 ByteBuffer& buffer,
38 bool allowBufferGrowth = false);
39
40}// end namespace ph
41
42#include "Api/api_helpers.ipp"
Definition api_helpers.cpp:8
PhFrameRegionStatus to_frame_region_status(ERegionStatus regionStatus)
Definition api_helpers.ipp:25
void to_frame_region_info(const RenderRegionStatus &regionStatus, PhFrameRegionInfo *out_regionInfo)
Definition api_helpers.ipp:40
bool is_reversing_bytes_needed(PhEndian desiredEndianness)
Definition api_helpers.ipp:16
TSpan< T > make_array_from_buffer(std::size_t numArrayElements, ByteBuffer &buffer, bool allowBufferGrowth=false)
Make an array of default constructed objects of type T.
Definition api_helpers.ipp:55
PictureMeta make_picture_meta(const PhFrameSaveInfo &saveInfo)
Definition api_helpers.cpp:10
PhFrameRegionStatus
Definition ph_c_core_types.h:51
PhEndian
Indicates the endianness. This type is not for detecting endianness of the current platform,...
Definition ph_c_core_types.h:35
Definition ph_c_core_types.h:65
Definition ph_c_core_types.h:82