primitive_assembly: Add getters for internal state
This commit is contained in:
parent
06815ec905
commit
15d14be3cc
@ -71,6 +71,16 @@ void PrimitiveAssembler<VertexType>::Reconfigure(PipelineRegs::TriangleTopology
|
||||
this->topology = topology;
|
||||
}
|
||||
|
||||
template <typename VertexType>
|
||||
bool PrimitiveAssembler<VertexType>::IsEmpty() const {
|
||||
return buffer_index == 0 && strip_ready == false;
|
||||
}
|
||||
|
||||
template <typename VertexType>
|
||||
PipelineRegs::TriangleTopology PrimitiveAssembler<VertexType>::GetTopology() const {
|
||||
return topology;
|
||||
}
|
||||
|
||||
// explicitly instantiate use cases
|
||||
template struct PrimitiveAssembler<Shader::OutputVertex>;
|
||||
|
||||
|
@ -45,6 +45,16 @@ struct PrimitiveAssembler {
|
||||
*/
|
||||
void Reconfigure(PipelineRegs::TriangleTopology topology);
|
||||
|
||||
/**
|
||||
* Is our internal state empty?
|
||||
*/
|
||||
bool IsEmpty() const;
|
||||
|
||||
/**
|
||||
* What is our triangle topology?
|
||||
*/
|
||||
PipelineRegs::TriangleTopology GetTopology() const;
|
||||
|
||||
private:
|
||||
PipelineRegs::TriangleTopology topology;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user