private void CheckFlush(int newVertices) { if (_renderer.GetMaxVertices() - _renderer.GetNumVertices() >= newVertices) { return; } GLType type = _currType; End(); Begin(type); }
private void Make(GLBatch batch) { device = GL.device; if (vectors == null) { ver = batch.GetMaxVertices(); vectors = new List <Vector3>(ver); } if (colors == null) { col = batch.GetMaxVertices() / 4; colors = new List <Color>(col); } if (coords == null) { tex = batch.GetMaxVertices() / 2; coords = new List <Vector2>(tex); } this.glbase = batch.Base; this.maxCount = batch.GetMaxVertices(); }
private void Make(GLBatch batch) { device = GL.device; if (vectors == null) { ver = batch.GetMaxVertices(); vectors = new List<Vector3>(ver); } if (colors == null) { col = batch.GetMaxVertices() / 4; colors = new List<Color>(col); } if (coords == null) { tex = batch.GetMaxVertices() / 2; coords = new List<Vector2>(tex); } this.glbase = batch.Base; this.maxCount = batch.GetMaxVertices(); }