25 lines
667 B
C
25 lines
667 B
C
|
#pragma once
|
||
|
|
||
|
#include "Renderable.h"
|
||
|
#include "Texture.h"
|
||
|
#include "Sampler.h"
|
||
|
|
||
|
namespace charcoal
|
||
|
{
|
||
|
template <typename VertexType, typename IndexType>
|
||
|
class TextureRenderable : public Renderable<VertexType, IndexType>
|
||
|
{
|
||
|
public:
|
||
|
TextureRenderable(const Renderable<VertexType, IndexType>::MeshType* mesh, Texture* texture, Sampler* sampler, const DrawMode& draw_mode)
|
||
|
: Renderable<VertexType, IndexType>(mesh, draw_mode), m_p_texture(texture), m_p_sampler(sampler)
|
||
|
{}
|
||
|
|
||
|
const Texture* get_texture() const { return m_p_texture; }
|
||
|
|
||
|
const Sampler* get_sampler() const { return m_p_sampler; }
|
||
|
|
||
|
private:
|
||
|
Texture* m_p_texture;
|
||
|
Sampler* m_p_sampler;
|
||
|
};
|
||
|
}
|