Port of AVA2's CRenderTarget / GrpRenderTargetTexture / renderTarget module. The host gains an RGBA8 offscreen colour pass for D3D colour render targets; mt_preview shows wearable items on every allowed race and monsters with motions, reached by X+click in the inventory and shop and from the wiki. Player races are created as TYPE_PC so their parts exist. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
32 lines
784 B
C++
32 lines
784 B
C++
#pragma once
|
|
// PORT: AVA2 CRenderTargetManager (EterLib/CRenderTargetManager.h).
|
|
#include <unordered_map>
|
|
#include <cstdint>
|
|
|
|
#include "../EterBase/Singleton.h"
|
|
#include <memory>
|
|
#include "CRenderTarget.h"
|
|
|
|
class CRenderTargetManager : public CSingleton<CRenderTargetManager>
|
|
{
|
|
public:
|
|
CRenderTargetManager();
|
|
virtual ~CRenderTargetManager();
|
|
|
|
std::shared_ptr<CRenderTarget> GetRenderTarget(int index);
|
|
bool CreateRenderTarget(int index, int width, int height);
|
|
|
|
void CreateRenderTargetTextures();
|
|
void ReleaseRenderTargetTextures();
|
|
|
|
void RemoveRenderTarget(const int index);
|
|
void Destroy();
|
|
void DeformModels();
|
|
void UpdateModels();
|
|
void RenderBackgrounds();
|
|
void RenderModels();
|
|
|
|
protected:
|
|
std::unordered_map<int, std::shared_ptr<CRenderTarget>> m_renderTargets;
|
|
};
|