TheAtlasEngine
 
Loading...
Searching...
No Matches
atlas::vk::vk_renderer Class Reference

Something to consider for mesh loading. More...

#include <vk_renderer.hpp>

Inheritance diagram for atlas::vk::vk_renderer:
atlas::render_context

Public Member Functions

 vk_renderer (const window_settings &p_settings, uint32_t p_image_size, const std::string &p_tag)
 
- Public Member Functions inherited from atlas::render_context
void preload (const VkRenderPass &p_renderpass)
 responsibility is to preload any data that is necessary to be loaded before being rendered
 
void begin_frame (const ::vk::command_buffer &p_current, const window_settings &p_settings, const VkRenderPass &p_renderpass, const VkFramebuffer &p_framebuffer, const glm::mat4 &p_proj_view)
 indicator of when the start of the frame is
 
void end_frame ()
 Intended to use to indicate when to end recording to the GPU in the current frame.
 
void set_background_color (const std::array< float, 4 > &p_color)
 sets the background color and request that change to the graphics API
 
void current_scene_context (ref< scene > p_scene)
 

Detailed Description

Something to consider for mesh loading.

How will meshes get loaded?

There are a few ways for considering for the base approach, which are: TODO: These are things to think about how this may happen because I want to make this lightweight in the sense the data isnt continuously being modified. Taking a looking at minimizing the loading state of vulkan implementation-specific meshes

  • While also making the way how mesh components are being added the same as before

Something to avoid is the entities containing the geometry data itself but being able to reference to their respective geometry data that are getting submitted to the GPU

  • Batching ID's into hash table that contains the actual geometry data
    • Using ID to search up the mesh loaded and cached into the map, then reuse that geometry whenever the uniforms are changed
    • This way we aren't reloading in the same mesh multiple times, treating the hash table as a slot of the mesh contained within that scene
    • Potentially std::map<std::string, std::map<std::string, vk::mesh_metadata>> m_geometries
      • Idea is the std::string is the geometries within this scene, the data format is: <scene_str, <mesh_str, mesh_metadata>>

Member Function Documentation

◆ background_color()

void atlas::vk::vk_renderer::background_color ( const std::array< float, 4 > &  p_color)
overrideprivatevirtual

Implements atlas::render_context.

◆ current_scene()

void atlas::vk::vk_renderer::current_scene ( ref< scene )
overrideprivatevirtual

Implements atlas::render_context.

◆ post_frame()

void atlas::vk::vk_renderer::post_frame ( )
overrideprivatevirtual

Implements atlas::render_context.

◆ preload_assets()

void atlas::vk::vk_renderer::preload_assets ( const VkRenderPass &  p_renderpass)
overrideprivatevirtual

Implements atlas::render_context.

◆ start_frame()

void atlas::vk::vk_renderer::start_frame ( const ::vk::command_buffer &  p_current,
const window_settings p_settings,
const VkRenderPass &  p_renderpass,
const VkFramebuffer &  p_framebuffer,
const glm::mat4 &  p_proj_view 
)
overrideprivatevirtual

Implements atlas::render_context.


The documentation for this class was generated from the following file: