dynpip rearrangment
This commit is contained in:
1 parent
f08fc1c8d3
commit
2fe40c8d90
35 files changed
+111
-37
No files matched your search
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -0,0 +1,41 @@
|
||||
/*
|
||||
# ______ ____ ___
|
||||
# | \/ ____| |___|
|
||||
# | | | \ | |
|
||||
#-----------------------------------------------------------------------
|
||||
# Copyright 2022, tyra - https://github.com/h4570/tyra
|
||||
# Licenced under Apache License 2.0
|
||||
# Sandro Sobczyński <sandro.sobczynski@gmail.com>
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <tamtypes.h>
|
||||
#include "./bag/dynpip_bag.hpp"
|
||||
#include "renderer/core/renderer_core.hpp"
|
||||
|
||||
namespace Tyra {
|
||||
|
||||
class DynPipCore {
|
||||
public:
|
||||
DynPipCore();
|
||||
~DynPipCore();
|
||||
|
||||
void init(RendererCore* t_core);
|
||||
|
||||
/** Render 3D via "bags" */
|
||||
void render(DynPipBag* data);
|
||||
|
||||
/**
|
||||
* - Uploads standard VU1 programs.
|
||||
* - Sends static "Tyra Renderer3D" VU1 data.
|
||||
* - Sets double buffers exactly for "Tyra Renderer3D"
|
||||
* Should be called if VU1 was used by your non standard programs.
|
||||
*/
|
||||
void reinitStandardVU1Programs();
|
||||
|
||||
private:
|
||||
RendererCore* rendererCore;
|
||||
};
|
||||
|
||||
} // namespace Tyra
|
||||
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -12,7 +12,8 @@
|
||||
|
||||
#include <tamtypes.h>
|
||||
#include "../renderer_3d_pipeline.hpp"
|
||||
#include "./dynpip_options.hpp"
|
||||
#include "./core/dynpip_options.hpp"
|
||||
#include "./core/dynpip_core.hpp"
|
||||
#include "renderer/core/renderer_core.hpp"
|
||||
#include "renderer/3d/mesh/dynamic/dynamic_mesh.hpp"
|
||||
|
||||
@@ -23,10 +24,16 @@ class DynamicPipeline : public Renderer3DPipeline {
|
||||
DynamicPipeline();
|
||||
~DynamicPipeline();
|
||||
|
||||
DynPipCore core;
|
||||
|
||||
void init(RendererCore* core);
|
||||
|
||||
void onUse();
|
||||
|
||||
/**
|
||||
* Render 3D via "meshes".
|
||||
* This render() method is a bridge to core.render() method.
|
||||
*/
|
||||
void render(DynamicMesh* mesh, const DynPipOptions* options = nullptr);
|
||||
};
|
||||
|
||||
|
||||
+4
-4
@@ -19,14 +19,14 @@
|
||||
|
||||
namespace Tyra {
|
||||
|
||||
class StaPipelineCore {
|
||||
class StaPipCore {
|
||||
public:
|
||||
StaPipelineCore();
|
||||
~StaPipelineCore();
|
||||
StaPipCore();
|
||||
~StaPipCore();
|
||||
|
||||
void init(RendererCore* t_core);
|
||||
|
||||
/** Render 3D data via "bags" */
|
||||
/** Render 3D via "bags" */
|
||||
void render(StaPipBag* data, StaPipBagPackagesBBox* bbox = nullptr);
|
||||
|
||||
/** Get max vert count of VU1 qbuffer (for optimizations) */
|
||||
@@ -15,7 +15,7 @@
|
||||
#include "./stapip_options.hpp"
|
||||
#include "renderer/core/renderer_core.hpp"
|
||||
#include "renderer/3d/mesh/dynamic/dynamic_mesh.hpp"
|
||||
#include "./core/static_pipeline_core.hpp"
|
||||
#include "./core/stapip_core.hpp"
|
||||
|
||||
namespace Tyra {
|
||||
|
||||
@@ -24,6 +24,8 @@ class StaticPipeline : public Renderer3DPipeline {
|
||||
StaticPipeline();
|
||||
~StaticPipeline();
|
||||
|
||||
StaPipCore core;
|
||||
|
||||
void init(RendererCore* core);
|
||||
|
||||
void onUse();
|
||||
@@ -35,7 +37,6 @@ class StaticPipeline : public Renderer3DPipeline {
|
||||
void render(DynamicMesh* mesh, const StaPipOptions* options = nullptr);
|
||||
|
||||
private:
|
||||
StaPipelineCore core;
|
||||
RendererCore* rendererCore;
|
||||
Vec4* colorsCache;
|
||||
|
||||
|
||||
Reference in new issue
Block a user