ImagePanelDyn::ImagePanelDyn(wxWindow* parent, wxImage &imageScaled, wxImage &imageNoScaled, wxPoint point, wxSize size, int style) : wxPanel(parent, wxID_ANY, point, size, style) { image0 = imageScaled.Copy(); image1 = imageNoScaled.Copy(); w = point.x; h = point.y; win = parent; }
ImageFrameDyn::ImageFrameDyn(wxWindow* parent, wxImage &imageScaled, wxImage &imageNoScaled, wxPoint point, wxSize size, int style) : wxFrame(parent, wxID_ANY, "", point, size, style) { cout << "ImageFrameDyn::ImageFrameDyn[0]" << endl; Model *model = new Model(); image0 = imageScaled.Copy(); imageZ = imageNoScaled.Copy(); model->isImageOK("ImageFrameDyn:image0", image0, true); model->isImageOK("ImageFrameDyn:imageZ", imageZ, true); // w = point.x; // h = point.y; win = parent; this->Show(); }
ImagePanelDyn::ImagePanelDyn(wxPanel* parent, int idImage, string nomImage, wxImage &image, wxPoint point, wxSize size, int style) : wxPanel(parent, wxID_ANY, point, size, style) { image0 = image.Copy(); idImage0 = idImage; panel = parent; nomImage0 = string(nomImage); this->Show(); }
bool CFrameWnd::StretchDraw(wxDC &x_dc, wxImage &x_img, wxRect &x_rect) {_STT(); if ( !x_img.Ok() ) return FALSE; // The slow but portable way... wxImage cWxImage = x_img.Copy(); cWxImage.Rescale( x_rect.GetWidth(), x_rect.GetHeight() ); x_dc.DrawBitmap( cWxImage, x_rect.x, x_rect.y ); return TRUE; }