|
DUDS
|
Distributed Update of Data from Something
|
Writes text, expecting a typical Linux terminal, to simulate a bit-per-pixel graphic display. More...
#include <SimulatedBppDisplay.hpp>
Public Member Functions | |
| SimulatedBppDisplay () | |
| Creates the object with an invalid display size. More... | |
| SimulatedBppDisplay (const duds::ui::graphics::ImageDimensions &id) | |
| Initializes the object to a usable state. More... | |
| SimulatedBppDisplay (unsigned int w, unsigned int h) | |
| Initializes the object to a usable state. More... | |
| void | configure (const duds::ui::graphics::ImageDimensions &id) |
| Initializes the object to a usable state. More... | |
| void | configure (unsigned int w, unsigned int h) |
| Initializes the object to a usable state. More... | |
Public Member Functions inherited from duds::hardware::display::BppGraphicDisplay | |
| const duds::ui::graphics::ImageDimensions & | dimensions () const |
| Returns the dimensions of the frame buffer. More... | |
| const duds::ui::graphics::BppImage & | frame () const |
| Provides access to the image in the frame buffer. More... | |
| int | height () const |
| Returns the height of the frame buffer. More... | |
| int | width () const |
| Returns the width of the frame buffer. More... | |
| void | write (const duds::ui::graphics::BppImage *img) |
| Writes the new image to the display. More... | |
| void | write (const std::shared_ptr< const duds::ui::graphics::BppImage > &img) |
| Writes the new image to the display. More... | |
Private Member Functions | |
| virtual void | outputFrame (const duds::ui::graphics::BppImage *img) |
| Writes out only the changed portions of the image to the display, and updates the image in frmbuf to match. More... | |
Private Attributes | |
| bool | bottom = false |
| True after rendering a frame to denote output is at the bottom of the frame. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from duds::hardware::display::BppGraphicDisplay | |
| BppGraphicDisplay ()=default | |
| Construct with an empty frame buffer. More... | |
| BppGraphicDisplay (const duds::ui::graphics::ImageDimensions &dim) | |
| Construct with a frame buffer of the specified size. More... | |
Protected Attributes inherited from duds::hardware::display::BppGraphicDisplay | |
| duds::ui::graphics::BppImage | frmbuf |
| The frame buffer. More... | |
Writes text, expecting a typical Linux terminal, to simulate a bit-per-pixel graphic display.
Intended for testing.
Definition at line 20 of file SimulatedBppDisplay.hpp.
| duds::hardware::devices::displays::SimulatedBppDisplay::SimulatedBppDisplay | ( | ) |
Creates the object with an invalid display size.
Definition at line 18 of file SimulatedBppDisplay.cpp.
| duds::hardware::devices::displays::SimulatedBppDisplay::SimulatedBppDisplay | ( | const duds::ui::graphics::ImageDimensions & | id | ) |
Initializes the object to a usable state.
| id | The dimensions of the display in "pixels" (really characters). It will work poorly if it doesn't fit on the display. |
Definition at line 20 of file SimulatedBppDisplay.cpp.
|
inline |
Initializes the object to a usable state.
| w | The width of the display in "pixels" (really characters). It will work poorly if it doesn't fit on the display. |
| h | The height of the display in "pixels" (really characters). It will work poorly if it doesn't fit on the display. |
Definition at line 52 of file SimulatedBppDisplay.hpp.
| void duds::hardware::devices::displays::SimulatedBppDisplay::configure | ( | const duds::ui::graphics::ImageDimensions & | id | ) |
Initializes the object to a usable state.
| id | The dimensions of the display in "pixels" (really characters). It will work poorly if it doesn't fit on the display. |
| DisplaySizeError | Either the width or height is zero. |
Definition at line 25 of file SimulatedBppDisplay.cpp.
Referenced by configure(), and SimulatedBppDisplay().
|
inline |
Initializes the object to a usable state.
| w | The width of the display in "pixels" (really characters). It will work poorly if it doesn't fit on the display. |
| h | The height of the display in "pixels" (really characters). It will work poorly if it doesn't fit on the display. |
| DisplaySizeError | Either the width or height is zero. |
Definition at line 71 of file SimulatedBppDisplay.hpp.
|
privatevirtual |
Writes out only the changed portions of the image to the display, and updates the image in frmbuf to match.
| img | The new image to show. |
Implements duds::hardware::display::BppGraphicDisplay.
Definition at line 36 of file SimulatedBppDisplay.cpp.
|
private |
True after rendering a frame to denote output is at the bottom of the frame.
Definition at line 25 of file SimulatedBppDisplay.hpp.
Referenced by configure(), and outputFrame().