mirror of
https://github.com/eried/portapack-mayhem.git
synced 2025-12-15 15:59:39 -05:00
Prepare for display orientation part 1 (#2661)
This commit is contained in:
parent
6f6d863a14
commit
a1d7cf2b86
85 changed files with 405 additions and 334 deletions
|
|
@ -51,9 +51,6 @@ namespace ui {
|
|||
#define LOOKING_GLASS_SINGLEPASS 2
|
||||
// one spectrum line number of bins
|
||||
#define SPEC_NB_BINS 256
|
||||
// screen dimensions
|
||||
#define SCREEN_W 240
|
||||
#define SCREEN_H 320
|
||||
|
||||
class GlassView : public View {
|
||||
public:
|
||||
|
|
@ -155,8 +152,8 @@ class GlassView : public View {
|
|||
uint8_t min_color_power{0}; // Filter cutoff level.
|
||||
uint32_t pixel_index{0};
|
||||
|
||||
std::array<Color, SCREEN_W> spectrum_row{};
|
||||
std::array<uint8_t, SCREEN_W> spectrum_data{};
|
||||
std::vector<Color> spectrum_row{};
|
||||
std::vector<uint8_t> spectrum_data{};
|
||||
ChannelSpectrumFIFO* fifo{};
|
||||
|
||||
int32_t steps = 1;
|
||||
|
|
@ -168,7 +165,7 @@ class GlassView : public View {
|
|||
rf::Frequency max_freq_hold = 0;
|
||||
rf::Frequency last_max_freq = 0;
|
||||
int16_t max_freq_power = -1000;
|
||||
uint8_t bin_length = SCREEN_W;
|
||||
uint8_t bin_length = screen_width;
|
||||
uint8_t offset = 0;
|
||||
uint8_t ignore_dc = 0;
|
||||
|
||||
|
|
@ -222,7 +219,7 @@ class GlassView : public View {
|
|||
{}};
|
||||
|
||||
ButtonWithEncoder button_beep_squelch{
|
||||
{240 - 8 * 8, 2 * 16 + 4, 8 * 8, 1 * 8},
|
||||
{screen_width - 8 * 8, 2 * 16 + 4, 8 * 8, 1 * 8},
|
||||
""};
|
||||
|
||||
TextField field_marker{
|
||||
|
|
@ -293,15 +290,15 @@ class GlassView : public View {
|
|||
}};
|
||||
|
||||
Button button_jump{
|
||||
{SCREEN_W - 4 * 8, 5 * 16, 4 * 8, 16},
|
||||
{screen_width - 4 * 8, 5 * 16, 4 * 8, 16},
|
||||
"JMP"};
|
||||
|
||||
Button button_rst{
|
||||
{SCREEN_W - 9 * 8, 5 * 16, 4 * 8, 16},
|
||||
{screen_width - 9 * 8, 5 * 16, 4 * 8, 16},
|
||||
"RST"};
|
||||
|
||||
Text freq_stats{
|
||||
{0 * 8, 5 * 16, SCREEN_W - 10 * 8, 8},
|
||||
{0 * 8, 5 * 16, screen_width - 10 * 8, 8},
|
||||
""};
|
||||
|
||||
MessageHandlerRegistration message_handler_spectrum_config{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue