Browse Source

SceneGraph: Camera::setViewport() and draw() don't need to be virtual.

If you need to override this functionality, simply call the subclass
implementation directly instead of calling it through a Camera
pointer/reference.
pull/272/head
Vladimír Vondruš 8 years ago
parent
commit
d004db6075
  1. 4
      doc/changelog.dox
  2. 4
      src/Magnum/SceneGraph/Camera.h

4
doc/changelog.dox

@ -263,6 +263,10 @@ See also:
working to fail with an assertion. See the new
@ref Math::Matrix3::rotationShear() and @ref Math::Matrix4::rotationShear()
accessors for a possible solution.
- @ref SceneGraph::Camera::setViewport() and @ref SceneGraph::Camera::draw()
are no longer @cpp virtual @ce functions. If you need to override their
functionality, simply call the subclass implementation directly instead of
calling it through a @ref SceneGraph::Camera.
- @ref Shaders::Flat::bindTexture(), @ref Shaders::Phong::bindAmbientTexture(),
@ref Shaders::Phong::bindDiffuseTexture(),
@ref Shaders::Phong::bindSpecularTexture() and

4
src/Magnum/SceneGraph/Camera.h

@ -184,14 +184,14 @@ template<UnsignedInt dimensions, class T> class Camera: public AbstractFeature<d
* according to aspect ratio policy.
* @see @ref setAspectRatioPolicy()
*/
virtual void setViewport(const Vector2i& size);
void setViewport(const Vector2i& size);
/**
* @brief Draw
*
* Draws given group of drawables.
*/
virtual void draw(DrawableGroup<dimensions, T>& group);
void draw(DrawableGroup<dimensions, T>& group);
private:
/** Recalculates camera matrix */

Loading…
Cancel
Save