- best i can do for now, screnshots can be sized, but size cannot exceed max viewable on screen resolution
This commit is contained in:
parent
1622b9b046
commit
d8092d25f6
|
@ -294,6 +294,7 @@ MainWindow::MainWindow( std::pair<string,vector<string> > unitToLoad,
|
|||
//getGlPlatformExtensions();
|
||||
|
||||
int args[] = { WX_GL_RGBA, WX_GL_DOUBLEBUFFER, WX_GL_MIN_ALPHA, 8 }; // to prevent flicker
|
||||
//int args[] = { WX_GL_RGBA, WX_GL_MIN_ALPHA, 0 }; // to prevent flicker
|
||||
glCanvas = new GlCanvas(this, args);
|
||||
|
||||
#if wxCHECK_VERSION(2, 9, 1)
|
||||
|
@ -570,6 +571,15 @@ void MainWindow::onPaint(wxPaintEvent &event) {
|
|||
setupStartupSettings();
|
||||
}
|
||||
|
||||
//wxClientDC &dc = event.GetDC();
|
||||
// wxPaintDC dc(this);
|
||||
// if(overrideSize.first > 0 && overrideSize.second > 0) {
|
||||
// wxRect r(0,0,100,100);
|
||||
// dc.SetDeviceClippingRegion(r);
|
||||
// // Then I destroy the clipping region
|
||||
// dc.DestroyClippingRegion();
|
||||
// }
|
||||
|
||||
// notice that we use GetSize() here and not GetClientSize() because
|
||||
// the latter doesn't return correct results for the minimized windows
|
||||
// (at least not under Windows)
|
||||
|
@ -1989,6 +1999,10 @@ END_EVENT_TABLE()
|
|||
|
||||
bool App::OnInit() {
|
||||
SystemFlags::VERBOSE_MODE_ENABLED = false;
|
||||
//Renderer::windowW = 1920;
|
||||
//Renderer::windowH = 1440;
|
||||
//Renderer::windowX= 0;
|
||||
//Renderer::windowY= 0;
|
||||
|
||||
string modelPath="";
|
||||
string particlePath="";
|
||||
|
@ -2056,6 +2070,8 @@ bool App::OnInit() {
|
|||
overrideSize.first = strToInt(values[0]);
|
||||
overrideSize.second = strToInt(values[1]);
|
||||
|
||||
Renderer::windowX= 0;
|
||||
Renderer::windowY= 0;
|
||||
Renderer::windowW = overrideSize.first;
|
||||
Renderer::windowH = overrideSize.second + 25;
|
||||
}
|
||||
|
|
|
@ -21,6 +21,8 @@ using namespace Shared::Graphics::Gl;
|
|||
|
||||
namespace Shared{ namespace G3dViewer{
|
||||
|
||||
int Renderer::windowX= 100;
|
||||
int Renderer::windowY= 100;
|
||||
int Renderer::windowW= 640;
|
||||
int Renderer::windowH= 480;
|
||||
|
||||
|
|
|
@ -68,8 +68,8 @@ public:
|
|||
|
||||
class Renderer : public RendererInterface {
|
||||
public:
|
||||
static const int windowX= 100;
|
||||
static const int windowY= 100;
|
||||
static int windowX;
|
||||
static int windowY;
|
||||
static int windowW;
|
||||
static int windowH;
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user