summaryrefslogtreecommitdiff
path: root/slideshow
diff options
context:
space:
mode:
authorEmmanuel Gil Peyrot <emmanuel.peyrot@collabora.com>2015-11-19 17:18:51 +0000
committerTor Lillqvist <tml@collabora.com>2015-11-19 19:21:34 +0200
commitf41358a71f4a6641141d90c33cdd763f9c4d3395 (patch)
tree0d3ef5776d312510f149f04d31baab40e3f275cc /slideshow
parent42a950178c32317ccd42a37de4a56bbdd753a1af (diff)
slideshow: Rename getVertices into getVertex, to match its only usage
Diffstat (limited to 'slideshow')
-rw-r--r--slideshow/source/engine/OGLTrans/generic/OGLTrans_TransitionImpl.cxx10
-rw-r--r--slideshow/source/engine/OGLTrans/generic/OGLTrans_TransitionImpl.hxx2
2 files changed, 6 insertions, 6 deletions
diff --git a/slideshow/source/engine/OGLTrans/generic/OGLTrans_TransitionImpl.cxx b/slideshow/source/engine/OGLTrans/generic/OGLTrans_TransitionImpl.cxx
index e9c92148b62c..529034fce81c 100644
--- a/slideshow/source/engine/OGLTrans/generic/OGLTrans_TransitionImpl.cxx
+++ b/slideshow/source/engine/OGLTrans/generic/OGLTrans_TransitionImpl.cxx
@@ -818,13 +818,13 @@ std::shared_ptr<OGLTransitionImpl> makeHelix( sal_uInt16 nRows )
Tile.pushTriangle(glm::vec2( 1.0 , iPDn ) , glm::vec2( 1.0 , iDn ) , glm::vec2( 0.0 , iPDn ));
- Tile.Operations.push_back( makeSRotate( glm::vec3( 0 , 1 , 0 ) , ( Tile.getVertices()[1] + Tile.getVertices()[3] )/2.0f , 180 ,
+ Tile.Operations.push_back( makeSRotate( glm::vec3( 0 , 1 , 0 ) , ( Tile.getVertex(1) + Tile.getVertex(3) )/2.0f , 180 ,
true, std::min(std::max(static_cast<double>(i - nRows/2.0)*invN/2.0,0.0),1.0),
std::min(std::max(static_cast<double>(i + nRows/2.0)*invN/2.0,0.0),1.0) ) );
aLeavingSlide.push_back(Tile);
- Tile.Operations.push_back( makeSRotate( glm::vec3( 0 , 1 , 0 ) , ( Tile.getVertices()[1] + Tile.getVertices()[3] )/2.0f , -180 , false,0.0,1.0) );
+ Tile.Operations.push_back( makeSRotate( glm::vec3( 0 , 1 , 0 ) , ( Tile.getVertex(1) + Tile.getVertex(3) )/2.0f , -180 , false,0.0,1.0) );
aEnteringSlide.push_back(Tile);
@@ -867,10 +867,10 @@ std::shared_ptr<OGLTransitionImpl> makeNByMTileFlip( sal_uInt16 n, sal_uInt16 m
aTile.pushTriangle(x21, x11, x12);
aTile.pushTriangle(x22, x21, x12);
- aTile.Operations.push_back(makeSRotate( glm::vec3(0 , 1, 0), (aTile.getVertices()[1] + aTile.getVertices()[3]) / 2.0f, 180 , true, x11.x * x11.y / 2.0f , ((x22.x * x22.y) + 1.0f) / 2.0f));
+ aTile.Operations.push_back(makeSRotate( glm::vec3(0 , 1, 0), (aTile.getVertex(1) + aTile.getVertex(3)) / 2.0f, 180 , true, x11.x * x11.y / 2.0f , ((x22.x * x22.y) + 1.0f) / 2.0f));
aLeavingSlide.push_back(aTile);
- aTile.Operations.push_back(makeSRotate( glm::vec3(0 , 1, 0), (aTile.getVertices()[1] + aTile.getVertices()[3]) / 2.0f, -180, false, x11.x * x11.y / 2.0f , ((x22.x * x22.y) + 1.0f) / 2.0f));
+ aTile.Operations.push_back(makeSRotate( glm::vec3(0 , 1, 0), (aTile.getVertex(1) + aTile.getVertex(3)) / 2.0f, -180, false, x11.x * x11.y / 2.0f , ((x22.x * x22.y) + 1.0f) / 2.0f));
aEnteringSlide.push_back(aTile);
}
}
@@ -1901,7 +1901,7 @@ std::shared_ptr<OGLTransitionImpl> makeGlitter()
Primitive aHexagon;
createHexagon(aHexagon, x, y, NX, NY);
- glm::vec3 aCenter = aHexagon.getVertices()[2];
+ glm::vec3 aCenter = aHexagon.getVertex(2);
float fRandom = comphelper::rng::uniform_real_distribution(-0.25, std::nextafter(0.2, DBL_MAX));
diff --git a/slideshow/source/engine/OGLTrans/generic/OGLTrans_TransitionImpl.hxx b/slideshow/source/engine/OGLTrans/generic/OGLTrans_TransitionImpl.hxx
index a14694fbb1f4..37df57e86e56 100644
--- a/slideshow/source/engine/OGLTrans/generic/OGLTrans_TransitionImpl.hxx
+++ b/slideshow/source/engine/OGLTrans/generic/OGLTrans_TransitionImpl.hxx
@@ -311,7 +311,7 @@ public:
@return
the list of vertices
*/
- const std::vector<glm::vec3>& getVertices() const {return Vertices;}
+ const glm::vec3& getVertex(int n) const {return Vertices[n];}
/** list of Operations to be performed on this primitive.These operations will be called in the order they were pushed back in. In OpenGL this effectively uses the operations in the opposite order they were pushed back.