mirror of
https://github.com/cjcliffe/CubicSDR.git
synced 2024-11-22 11:49:38 -05:00
Back out wxGLAttributes update until needed.
This commit is contained in:
parent
4a64104050
commit
9ac31040d5
@ -55,9 +55,10 @@ AppFrame::AppFrame() :
|
||||
wxBoxSizer *demodScopeTray = new wxBoxSizer(wxVERTICAL);
|
||||
wxBoxSizer *demodTunerTray = new wxBoxSizer(wxHORIZONTAL);
|
||||
|
||||
// int attribList[] = { WX_GL_RGBA, WX_GL_DOUBLEBUFFER, 0 };
|
||||
wxGLAttributes attribList;
|
||||
attribList.PlatformDefaults().RGBA().DoubleBuffer().EndList();
|
||||
int attribList[] = { WX_GL_RGBA, WX_GL_DOUBLEBUFFER, 0 };
|
||||
//wxGLAttributes attribList;
|
||||
//attribList.PlatformDefaults().RGBA().DoubleBuffer().EndList();
|
||||
//attribList.PlatformDefaults().MinRGBA(8, 8, 8, 8).DoubleBuffer().Depth(16).EndList();
|
||||
|
||||
mainSplitter = new wxSplitterWindow( this, wxID_MAIN_SPLITTER, wxDefaultPosition, wxDefaultSize, wxSP_3DSASH | wxSP_LIVE_UPDATE );
|
||||
mainSplitter->SetSashGravity(10.0/37.0);
|
||||
@ -558,7 +559,7 @@ AppFrame::AppFrame() :
|
||||
waterfallCanvas->setLinesPerSecond(wflps);
|
||||
|
||||
ThemeMgr::mgr.setTheme(wxGetApp().getConfig()->getTheme());
|
||||
|
||||
|
||||
Show();
|
||||
|
||||
#ifdef _WIN32
|
||||
|
@ -24,7 +24,7 @@ EVT_LEAVE_WINDOW(UITestCanvas::OnMouseLeftWindow)
|
||||
EVT_ENTER_WINDOW(UITestCanvas::OnMouseEnterWindow)
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
UITestCanvas::UITestCanvas(wxWindow *parent, const wxGLAttributes& dispAttrs) :
|
||||
UITestCanvas::UITestCanvas(wxWindow *parent, int *dispAttrs) :
|
||||
InteractiveCanvas(parent, dispAttrs) {
|
||||
|
||||
glContext = new UITestContext(this, &wxGetApp().GetContext(this));
|
||||
|
@ -14,7 +14,7 @@
|
||||
|
||||
class UITestCanvas: public InteractiveCanvas {
|
||||
public:
|
||||
UITestCanvas(wxWindow *parent, const wxGLAttributes& dispAttrs);
|
||||
UITestCanvas(wxWindow *parent, int *dispAttrs);
|
||||
~UITestCanvas();
|
||||
|
||||
private:
|
||||
|
@ -24,7 +24,7 @@ EVT_LEAVE_WINDOW(GainCanvas::OnMouseLeftWindow)
|
||||
EVT_ENTER_WINDOW(GainCanvas::OnMouseEnterWindow)
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
GainCanvas::GainCanvas(wxWindow *parent, const wxGLAttributes& dispAttrs) :
|
||||
GainCanvas::GainCanvas(wxWindow *parent, int *dispAttrs) :
|
||||
InteractiveCanvas(parent, dispAttrs) {
|
||||
|
||||
glContext = new PrimaryGLContext(this, &wxGetApp().GetContext(this));
|
||||
|
@ -27,7 +27,7 @@ public:
|
||||
|
||||
class GainCanvas: public InteractiveCanvas {
|
||||
public:
|
||||
GainCanvas(wxWindow *parent, const wxGLAttributes& dispAttrs);
|
||||
GainCanvas(wxWindow *parent, int *dispAttrs);
|
||||
~GainCanvas();
|
||||
|
||||
void setHelpTip(std::string tip);
|
||||
|
@ -17,8 +17,8 @@
|
||||
|
||||
#include <wx/numformatter.h>
|
||||
|
||||
InteractiveCanvas::InteractiveCanvas(wxWindow *parent, const wxGLAttributes& dispAttrs) :
|
||||
wxGLCanvas(parent, dispAttrs ,wxID_ANY, wxDefaultPosition, wxDefaultSize,
|
||||
InteractiveCanvas::InteractiveCanvas(wxWindow *parent, int *dispAttrs) :
|
||||
wxGLCanvas(parent, wxID_ANY, dispAttrs, wxDefaultPosition, wxDefaultSize,
|
||||
wxFULL_REPAINT_ON_RESIZE), parent(parent), shiftDown(false), altDown(false), ctrlDown(false), centerFreq(0), bandwidth(0), lastBandwidth(0), isView(
|
||||
false) {
|
||||
mouseTracker.setTarget(this);
|
||||
|
@ -8,7 +8,7 @@
|
||||
|
||||
class InteractiveCanvas: public wxGLCanvas {
|
||||
public:
|
||||
InteractiveCanvas(wxWindow *parent, const wxGLAttributes& dispAttrs);
|
||||
InteractiveCanvas(wxWindow *parent, int *dispAttrs);
|
||||
~InteractiveCanvas();
|
||||
|
||||
long long getFrequencyAt(float x);
|
||||
|
@ -27,7 +27,7 @@ EVT_LEAVE_WINDOW(MeterCanvas::OnMouseLeftWindow)
|
||||
EVT_ENTER_WINDOW(MeterCanvas::OnMouseEnterWindow)
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
MeterCanvas::MeterCanvas(wxWindow *parent, const wxGLAttributes& dispAttrs) :
|
||||
MeterCanvas::MeterCanvas(wxWindow *parent, int *dispAttrs) :
|
||||
InteractiveCanvas(parent, dispAttrs), level(0), level_min(0), level_max(1), inputValue(0), userInputValue(0), showUserInput(true) {
|
||||
|
||||
glContext = new MeterContext(this, &wxGetApp().GetContext(this));
|
||||
|
@ -14,7 +14,7 @@
|
||||
|
||||
class MeterCanvas: public InteractiveCanvas {
|
||||
public:
|
||||
MeterCanvas(wxWindow *parent, const wxGLAttributes& dispAttrs);
|
||||
MeterCanvas(wxWindow *parent, int *dispAttrs);
|
||||
~MeterCanvas();
|
||||
|
||||
void setLevel(float level_in);
|
||||
|
@ -24,7 +24,7 @@ EVT_LEAVE_WINDOW(ModeSelectorCanvas::OnMouseLeftWindow)
|
||||
EVT_ENTER_WINDOW(ModeSelectorCanvas::OnMouseEnterWindow)
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
ModeSelectorCanvas::ModeSelectorCanvas(wxWindow *parent, const wxGLAttributes& dispAttrs) :
|
||||
ModeSelectorCanvas::ModeSelectorCanvas(wxWindow *parent, int *dispAttrs) :
|
||||
InteractiveCanvas(parent, dispAttrs), numChoices(0), currentSelection(-1), toggleMode(false), inputChanged(false), padX(4.0), padY(4.0), highlightOverride(false) {
|
||||
|
||||
glContext = new ModeSelectorContext(this, &wxGetApp().GetContext(this));
|
||||
|
@ -24,7 +24,7 @@ public:
|
||||
|
||||
class ModeSelectorCanvas: public InteractiveCanvas {
|
||||
public:
|
||||
ModeSelectorCanvas(wxWindow *parent, const wxGLAttributes& dispAttrs);
|
||||
ModeSelectorCanvas(wxWindow *parent, int *dispAttrs);
|
||||
~ModeSelectorCanvas();
|
||||
|
||||
int getHoveredSelection();
|
||||
|
@ -28,7 +28,7 @@ EVT_LEAVE_WINDOW(ScopeCanvas::OnMouseLeftWindow)
|
||||
EVT_ENTER_WINDOW(ScopeCanvas::OnMouseEnterWindow)
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
ScopeCanvas::ScopeCanvas(wxWindow *parent, const wxGLAttributes& dispAttrs) : InteractiveCanvas(parent, dispAttrs), ppmMode(false), ctr(0), ctrTarget(0), dragAccel(0), helpTip("") {
|
||||
ScopeCanvas::ScopeCanvas(wxWindow *parent, int *dispAttrs) : InteractiveCanvas(parent, dispAttrs), ppmMode(false), ctr(0), ctrTarget(0), dragAccel(0), helpTip("") {
|
||||
|
||||
glContext = new ScopeContext(this, &wxGetApp().GetContext(this));
|
||||
inputData.set_max_num_items(2);
|
||||
|
@ -14,7 +14,7 @@
|
||||
|
||||
class ScopeCanvas: public InteractiveCanvas {
|
||||
public:
|
||||
ScopeCanvas(wxWindow *parent, const wxGLAttributes& dispAttrs);
|
||||
ScopeCanvas(wxWindow *parent, int *dispAttrs);
|
||||
~ScopeCanvas();
|
||||
|
||||
void setDeviceName(std::string device_name);
|
||||
|
@ -29,7 +29,7 @@ EVT_RIGHT_DOWN(SpectrumCanvas::OnMouseRightDown)
|
||||
EVT_RIGHT_UP(SpectrumCanvas::OnMouseRightReleased)
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
SpectrumCanvas::SpectrumCanvas(wxWindow *parent, const wxGLAttributes& dispAttrs) :
|
||||
SpectrumCanvas::SpectrumCanvas(wxWindow *parent, int *dispAttrs) :
|
||||
InteractiveCanvas(parent, dispAttrs), waterfallCanvas(NULL) {
|
||||
|
||||
glContext = new PrimaryGLContext(this, &wxGetApp().GetContext(this));
|
||||
|
@ -13,7 +13,7 @@ class WaterfallCanvas;
|
||||
|
||||
class SpectrumCanvas: public InteractiveCanvas {
|
||||
public:
|
||||
SpectrumCanvas(wxWindow *parent, const wxGLAttributes& dispAttrs);
|
||||
SpectrumCanvas(wxWindow *parent, int *dispAttrs);
|
||||
~SpectrumCanvas();
|
||||
|
||||
void attachWaterfallCanvas(WaterfallCanvas *canvas_in);
|
||||
|
@ -30,7 +30,7 @@ EVT_MOUSEWHEEL(TuningCanvas::OnMouseWheelMoved)
|
||||
//EVT_KEY_UP(TuningCanvas::OnKeyUp)
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
TuningCanvas::TuningCanvas(wxWindow *parent, const wxGLAttributes& dispAttrs) :
|
||||
TuningCanvas::TuningCanvas(wxWindow *parent, int *dispAttrs) :
|
||||
InteractiveCanvas(parent, dispAttrs), dragAccum(0), uxDown(0), top(false), bottom(false), freq(-1), bw(-1), center(-1), halfBand(false) {
|
||||
|
||||
glContext = new TuningContext(this, &wxGetApp().GetContext(this));
|
||||
|
@ -17,7 +17,7 @@ public:
|
||||
enum ActiveState {
|
||||
TUNING_HOVER_NONE, TUNING_HOVER_FREQ, TUNING_HOVER_BW, TUNING_HOVER_PPM, TUNING_HOVER_CENTER
|
||||
};
|
||||
TuningCanvas(wxWindow *parent, const wxGLAttributes& dispAttrs);
|
||||
TuningCanvas(wxWindow *parent, int *dispAttrs);
|
||||
~TuningCanvas();
|
||||
|
||||
void setHelpTip(std::string tip);
|
||||
|
@ -34,7 +34,7 @@ EVT_ENTER_WINDOW(WaterfallCanvas::OnMouseEnterWindow)
|
||||
EVT_MOUSEWHEEL(WaterfallCanvas::OnMouseWheelMoved)
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
WaterfallCanvas::WaterfallCanvas(wxWindow *parent, const wxGLAttributes& dispAttrs) :
|
||||
WaterfallCanvas::WaterfallCanvas(wxWindow *parent, int *dispAttrs) :
|
||||
InteractiveCanvas(parent, dispAttrs), dragState(WF_DRAG_NONE), nextDragState(WF_DRAG_NONE), fft_size(0), new_fft_size(0), waterfall_lines(0),
|
||||
dragOfs(0), mouseZoom(1), zoom(1), freqMoving(false), freqMove(0.0), hoverAlpha(1.0) {
|
||||
|
||||
|
@ -18,7 +18,7 @@ public:
|
||||
WF_DRAG_NONE, WF_DRAG_BANDWIDTH_LEFT, WF_DRAG_BANDWIDTH_RIGHT, WF_DRAG_FREQUENCY, WF_DRAG_RANGE
|
||||
};
|
||||
|
||||
WaterfallCanvas(wxWindow *parent, const wxGLAttributes& dispAttrs);
|
||||
WaterfallCanvas(wxWindow *parent, int *dispAttrs);
|
||||
void setup(unsigned int fft_size_in, int waterfall_lines_in);
|
||||
void setFFTSize(unsigned int fft_size_in);
|
||||
~WaterfallCanvas();
|
||||
|
Loading…
Reference in New Issue
Block a user