// MobileGL - MobileGL/MG_State/GLState/VertexArrayState/VertexArrayState.h // Copyright (c) 2025-2026 MobileGL-Dev // Licensed under the GNU Lesser General Public License v3.0: // https://www.gnu.org/licenses/gpl-3.0.txt // https://www.gnu.org/licenses/lgpl-3.0.txt // SPDX-License-Identifier: LGPL-3.0-only // End of Source File Header #pragma once #include #include "VertexArrayObject.h" #include namespace MobileGL { namespace MG_State { namespace GLState { class VertexArrayState { public: VertexArrayState(); const SharedPtr& GetVertexArrayObject(Uint index); void GenerateNames(Uint number, Vector& arrays); void Bind(Uint index); const SharedPtr& CreateVertexArrayObject(Uint index); void MarkVertexArrayForDeletion(Uint index); Bool ValidateName(Uint index) const; Bool ValidateVertexArrayObject(Uint index) const; const SharedPtr& GetBoundVertexArray(); Vector>& GetAllVertexArrays(); private: Vector> m_vertexArrays; IndexGenerator m_indexGenerator; SharedPtr m_boundVertexArray; }; } // namespace GLState } // namespace MG_State } // namespace MobileGL