Changeset View
Changeset View
Standalone View
Standalone View
ps/trunk/source/graphics/CinemaPath.h
/* Copyright (C) 2016 Wildfire Games. | /* Copyright (C) 2017 Wildfire Games. | ||||
* This file is part of 0 A.D. | * This file is part of 0 A.D. | ||||
* | * | ||||
* 0 A.D. is free software: you can redistribute it and/or modify | * 0 A.D. is free software: you can redistribute it and/or modify | ||||
* it under the terms of the GNU General Public License as published by | * it under the terms of the GNU General Public License as published by | ||||
* the Free Software Foundation, either version 2 of the License, or | * the Free Software Foundation, either version 2 of the License, or | ||||
* (at your option) any later version. | * (at your option) any later version. | ||||
* | * | ||||
* 0 A.D. is distributed in the hope that it will be useful, | * 0 A.D. is distributed in the hope that it will be useful, | ||||
▲ Show 20 Lines • Show All 46 Lines • ▼ Show 20 Lines | |||||
class CCinemaPath : private CCinemaData, public TNSpline | class CCinemaPath : private CCinemaData, public TNSpline | ||||
{ | { | ||||
public: | public: | ||||
CCinemaPath() : m_TimeElapsed(0), m_PreviousNodeTime(0) {} | CCinemaPath() : m_TimeElapsed(0), m_PreviousNodeTime(0) {} | ||||
CCinemaPath(const CCinemaData& data, const TNSpline& spline, const TNSpline& targetSpline); | CCinemaPath(const CCinemaData& data, const TNSpline& spline, const TNSpline& targetSpline); | ||||
// Sets camera position to calculated point on spline | // Sets camera position to calculated point on spline | ||||
void MoveToPointAt(float t, float nodet, const CVector3D& startRotation, CCamera* camera); | void MoveToPointAt(float t, float nodet, const CVector3D& startRotation, CCamera* camera) const; | ||||
// Distortion mode functions-change how ratio is passed to distortion style functions | // Distortion mode functions-change how ratio is passed to distortion style functions | ||||
float EaseIn(float t) const; | float EaseIn(float t) const; | ||||
float EaseOut(float t) const; | float EaseOut(float t) const; | ||||
float EaseInOut(float t) const; | float EaseInOut(float t) const; | ||||
float EaseOutIn(float t) const; | float EaseOutIn(float t) const; | ||||
// Distortion style functions | // Distortion style functions | ||||
▲ Show 20 Lines • Show All 69 Lines • Show Last 20 Lines |
Wildfire Games · Phabricator