The fade of the screen: a wipe whose level goes to its target at a rate, and the edges of the picture it shows, in pixels of the 320 by 240 screen.
More...
#include <frontend.h>
The fade of the screen: a wipe whose level goes to its target at a rate, and the edges of the picture it shows, in pixels of the 320 by 240 screen.
The same level fades the sound effects.
◆ SetTarget()
| void coastline::ScreenFade::SetTarget |
( |
float | to, |
|
|
float | seconds ) |
SetFadeTarget() of the console.
- Parameters
-
| to | The level to fade to. |
| seconds | The time of a fade across the whole range. |
◆ FadingIn()
| bool coastline::ScreenFade::FadingIn |
( |
| ) |
const |
- Returns
- Whether the fade moves towards the whole picture.
◆ FadingOut()
| bool coastline::ScreenFade::FadingOut |
( |
| ) |
const |
- Returns
- Whether the fade moves towards black.
◆ Complete()
| bool coastline::ScreenFade::Complete |
( |
| ) |
const |
- Returns
- Whether the level has arrived at its target.
◆ Update()
| void coastline::ScreenFade::Update |
( |
float | seconds | ) |
|
Advance the fade by a frame.
- Parameters
-
| seconds | The time of the frame. |
◆ Draw()
| void coastline::ScreenFade::Draw |
( |
SceneRenderer & | renderer | ) |
const |
Draw the black of the wipe left and right of the picture, across the whole frame.
- Parameters
-
| renderer | The renderer of the frame. |
◆ level
| float coastline::ScreenFade::level = 0.0f |
From 0 for black to 1 for the whole picture.
◆ target
| float coastline::ScreenFade::target = 0.0f |
The level the fade moves to.
◆ rate
| float coastline::ScreenFade::rate = 0.0f |
The change of the level in a second.
◆ autoReverse
| bool coastline::ScreenFade::autoReverse = false |
Whether a fade out waits for the fade in to finish.
◆ skipFrame
| bool coastline::ScreenFade::skipFrame = false |
Whether the next frame leaves the level as it is.
◆ left
| int coastline::ScreenFade::left = 0 |
The left edge of the picture.
◆ right
| int coastline::ScreenFade::right = 0 |
The right edge of the picture.
The documentation for this struct was generated from the following file: