having a little trouble with vector
1 2 3 4 5 6 7 8 9
|
void Square::updateSquare(Vertex position, float size)
{
this->accessVertices().push_back(
Vertex(
position._x - size/2,
position._y - size/2,
position._z
)
);
|
This is part of a member function of a class. It doesnt seem to be increasing the size of vector.
accessVertices is a function which returns the vector which is a protected member of the base class which this class is inherited from.
Any clue why vector size is remaining 0 even after multiple objects are been pushed in?
Does accessVertices() by any chance return the vector by value?
Yes it does! Much appreciado my good friend, fixed ^_^
Topic archived. No new replies allowed.