A render view instance, responsible for the generation of view packets based on internal logic and given config.
More...
#include <renderer_types.h>
|
const char * | name |
| The name of the view. More...
|
|
u16 | width |
| The current width of this view. More...
|
|
u16 | height |
| The current height of this view. More...
|
|
u8 | renderpass_count |
| The number of renderpasses used by this view. More...
|
|
renderpass * | passes |
| An array of renderpasses used by this view. More...
|
|
const char * | custom_shader_name |
| The name of the custom shader used by this view, if there is one. More...
|
|
void * | internal_data |
| The internal, view-specific data for this view. More...
|
|
b8(* | on_registered )(struct render_view *self) |
| A pointer to a function to be called when this view is registered with the view system. More...
|
|
void(* | on_destroy )(struct render_view *self) |
| A pointer to a function to be called when this view is destroyed. More...
|
|
void(* | on_resize )(struct render_view *self, u32 width, u32 height) |
| A pointer to a function to be called when the owner of this view (such as the window) is resized. More...
|
|
b8(* | on_packet_build )(const struct render_view *self, struct frame_data *p_frame_data, struct viewport *v, struct camera *c, void *data, struct render_view_packet *out_packet) |
| Builds a render view packet using the provided view and meshes. More...
|
|
void(* | on_packet_destroy )(const struct render_view *self, struct render_view_packet *packet) |
| Destroys a render view packet. More...
|
|
b8(* | on_render )(const struct render_view *self, const struct render_view_packet *packet, struct frame_data *p_frame_data) |
| Uses the given view and packet to render the contents therein. More...
|
|
b8(* | attachment_target_regenerate )(struct render_view *self, u32 pass_index, struct render_target_attachment *attachment) |
| Regenerates the resources for the given attachment at the provided pass index. More...
|
|
A render view instance, responsible for the generation of view packets based on internal logic and given config.
◆ attachment_target_regenerate
Regenerates the resources for the given attachment at the provided pass index.
- Parameters
-
self | A pointer to the view to use. |
pass_index | The index of the renderpass to generate for. |
attachment | A pointer to the attachment whose resources are to be regenerated. |
- Returns
- True on success; otherwise false.
◆ custom_shader_name
const char* custom_shader_name |
The name of the custom shader used by this view, if there is one.
◆ height
The current height of this view.
◆ internal_data
The internal, view-specific data for this view.
◆ name
◆ on_destroy
A pointer to a function to be called when this view is destroyed.
- Parameters
-
self | A pointer to the view being destroyed. |
◆ on_packet_build
Builds a render view packet using the provided view and meshes.
- Parameters
-
self | A pointer to the view to use. |
frame_data | A pointer to the current frame's data. |
v | A pointer to the viewport to be used. |
c | A pointer to the camera to be used. |
data | Freeform data used to build the packet. |
out_packet | A pointer to hold the generated packet. |
- Returns
- True on success; otherwise false.
◆ on_packet_destroy
Destroys a render view packet.
- Parameters
-
self | A pointer to the view to use. |
packet | A pointer to the packet to be destroyed. |
◆ on_registered
A pointer to a function to be called when this view is registered with the view system.
- Parameters
-
self | A pointer to the view being registered. |
- Returns
- True on success; otherwise false.
◆ on_render
Uses the given view and packet to render the contents therein.
- Parameters
-
self | A pointer to the view to use. |
packet | A pointer to the packet whose data is to be rendered. |
p_frame_data | A pointer to the current frame's data. |
- Returns
- True on success; otherwise false.
◆ on_resize
A pointer to a function to be called when the owner of this view (such as the window) is resized.
- Parameters
-
self | A pointer to the view being resized. |
width | The new width in pixels. |
width | The new height in pixels. |
◆ passes
An array of renderpasses used by this view.
◆ renderpass_count
The number of renderpasses used by this view.
◆ width
The current width of this view.
The documentation for this struct was generated from the following file: