Add LINE to make functions as last primitive

This commit is contained in:
2023-10-03 20:44:08 +02:00
parent 246fd80ed9
commit b9cfbaec6b
2 changed files with 23 additions and 4 deletions

View File

@@ -149,6 +149,25 @@ namespace JabyEngine {
}
// ###################################################################
static constexpr GPU::internal::SingleLine<GPU::Vertex> LINE_F(const GPU::Color24& color, const GPU::Vertex& start_point, const GPU::Vertex& end_point) {
return GPU::LINE_F::create(color, start_point, end_point);
}
template<typename...ARGS>
static constexpr GPU::internal::MultiLine<GPU::Vertex, sizeof...(ARGS)> LINE_F(const GPU::Color24& color, const GPU::Vertex& start_point, const ARGS&...rest) {
return GPU::LINE_F::create(color, start_point, rest...);
}
static constexpr GPU::internal::SingleLine<GPU::ColorVertex> LINE_G(const GPU::ColorVertex& start_point, const GPU::ColorVertex& end_point) {
return GPU::LINE_G::create(start_point, end_point);
}
template<typename...ARGS>
static constexpr GPU::internal::MultiLine<GPU::ColorVertex, sizeof...(ARGS)> LINE_G(const GPU::ColorVertex& start_point, const ARGS&...rest) {
return GPU::LINE_G::create(start_point, rest...);
}
// ###################################################################
// ###################################################################
// ###################################################################