Files
NBEngine/engine/NBGraphics/src/VertexData.cpp
T

16 lines
405 B
C++

#include <NBGraphics/VertexData.hpp>
namespace nb {
VertexData::VertexData(
std::shared_ptr<Buffer> data_,
const std::vector<VertexAttribute>& attrs_
) : data(data_), attributes(attrs_) {}
VertexData::VertexData(
const ByteVector& data_,
const std::vector<VertexAttribute>& attrs_
) : data(std::make_shared<Buffer>(GL_ARRAY_BUFFER, data_)),
attributes(attrs_) {}
} // namespace nb