VersionManagerDialog::VersionManagerDialog(QString ver, Profile pro, QWidget *parent) : QDialog(parent), ui(new Ui::VersionManagerDialog) { ui->setupUi(this); this->pro = Profile(pro); this->setWindowTitle("Minecraft Version: " + ver); ui->chkGameDir->setChecked(pro.hasGameDir); if(pro.hasGameDir) ui->txtGameDir->setText(pro.gameDir); ui->chkJavaDir->setChecked(pro.hasJavaDir); if(pro.hasJavaDir) ui->txtJavaDir->setText(pro.javaDir); ui->chkJavaArgs->setChecked(pro.hasJavaArgs); if(pro.hasJavaArgs) ui->txtJavaArgs->setText(pro.javaArgs); ui->chkResolution->setChecked(pro.hasResolution); if(pro.hasResolution) { ui->txtHeight->setText(QString::number(pro.r.height)); ui->txtWidth->setText(QString::number(pro.r.width)); } ui->chkFullscreen->setChecked(pro.hasFullScreen); gameDirChanged(); javaArgsChanged(); javaDirChanged(); resolutionChanged(); fullscreenChanged(); }
void ImageView::setResolution(double value) { if (value != m_resolution) { m_resolution = value; resolutionChanged(m_resolution); update(); } }
void QDeclarativeCameraViewfinder::setResolution(const QSize &resolution) { if (m_control) { m_control->setViewfinderParameter( QCameraViewfinderSettingsControl::Resolution, resolution); emit resolutionChanged(); } }
void QG_ImageOptionsDialog::setGraphicSize(const RS_Vector& s) { graphicSize = s; if(!useResolution){ sizeChanged(); } else { resolutionChanged(); } }
void ImageView::reset() { m_zoom = 1.0; m_resolution = 1.0; m_origin = QPoint(0, 0); zoomChanged(1); resolutionChanged(1); originXChanged(0); originYChanged(0); update(); }
void QQuickGridMesh::setResolution(const QSize &res) { if (res == m_resolution) return; if (res.width() < 1 || res.height() < 1) { return; } m_resolution = res; emit resolutionChanged(); }
void ImageExporterResolutionWidget::updateResolutionSummary() { // TODO: detect unsigned long long overflow int height{ static_cast<int>(std::round(toPixels(m_heightState->value, m_heightState->type))) }; int width{ static_cast<int>(std::round(toPixels(m_widthState->value, m_widthState->type))) }; emit resolutionChanged(QSize(width, height)); unsigned long long pixelNumber{ static_cast<unsigned long long>(width) * static_cast<unsigned long long>(height) }; QString unit; double byte; if (pixelNumber * 4 < 1024) { unit = "Byte"; byte = static_cast<double>(pixelNumber) * 4; } else if (pixelNumber * 4 < static_cast<unsigned long long>(std::pow<int, int>(1024, 2))) { unit = "KiB"; byte = static_cast<double>(pixelNumber) * 4 / 1024; } else if (pixelNumber * 4 < static_cast<unsigned long long>(std::pow<int, int>(1024, 3))) { unit = "MiB"; byte = static_cast<double>(pixelNumber) * 4 / std::pow<int, int>(1024, 2); } else if (pixelNumber * 4 < static_cast<unsigned long long>(std::pow<int, int>(1024, 4))) { unit = "GiB"; byte = static_cast<double>(pixelNumber) * 4 / std::pow<int, int>(1024, 3); } else //if (pixelNumber * 4 < static_cast<unsigned long long>(std::pow<int, int>(1024, 5))) { unit = "TiB"; byte = static_cast<double>(pixelNumber) * 4 / std::pow<int, int>(1024, 4); } QString summary{ QString::number(pixelNumber) + " pixels (" + QString::number(std::round(byte * 100) / 100) + " " + unit + " uncompressed)" }; //m_ui->resolutionSummaryLabel->setText(summary); emit resolutionSummaryChanged(summary); }
/** * @brief cwCaptureViewport::setResolution * @param resolution */ void cwCaptureViewport::setResolution(int resolution) { if(Resolution != resolution) { Resolution = resolution; emit resolutionChanged(); } }
void QOpticalDevice::setResolution(int u, int v) { resolution = cv::Size(u,v); emit resolutionChanged(u,v); }
QQuickGridMesh::QQuickGridMesh(QObject *parent) : QQuickShaderEffectMesh(parent) , m_resolution(1, 1) { connect(this, SIGNAL(resolutionChanged()), this, SIGNAL(geometryChanged())); }
cv::Mat clsTracking2D::getProcessedImage() { if(isVideo) usleep(VIDEOFRAME_SLEEP); if(!initializedProcess){ initializeProcessing(); } if(resolutionChanged()){ WARNMSG(("Lost camera frame... wrong resolution.")); usleep(500); return rawImage; // returns the previous frame... very dangerous in real-time systems.! } cv::Rect roi( cameraResolutions["roiX"], cameraResolutions["roiY"], cameraResolutions["roiW"], cameraResolutions["roiH"]); rawMatROI = rawImage(roi); rawImageROIval = rawMatROI; rawImageROI = &rawImageROIval; rawImageIval = rawImage; rawImageI = &rawImageIval; // cvRectangle(rawImageI, cvPoint( paramsInt["roiX"], paramsInt["roiY"]),cvPoint( paramsInt["roiX"]+ paramsInt["roiW"], paramsInt["roiY"]+ paramsInt["roiH"]), CV_RGB(0,0,255), 1, 40, 0); frameCount++; //process background subtraction: switch(paramsInt["bg"] ) { case BG_BGCodeBookModel: INFOMSG(("calcCodeBook")); calcCodeBook(rawImageROI,foregroundImage,debugFrame); break; case BG_COLORSUBTRACTION: INFOMSG(("calcBGsubtraction")); calcBGsubtraction(rawImageROI,foregroundImage); break; case BG_SEG: INFOMSG(("calcBgSegmentation")); calcBgSegmentation(rawImageROI,foregroundImage); break; default: DEBUGMSG(("no bg model found")); } cvCopy(rawImageI,paintedFrame); paintROI(paintedFrame); if(readyForParticles && startTracking) { pParticles.processManyParticles(foregroundImage); if(paramsInt["showTraces"] == 1) pParticles.drawManyParticles(paintedFrame); } if(paramsInt["showProcessed"] == 1) rawImage = foregroundImage; else rawImage = paintedFrame; if(paramsInt["frameRate"] > 0 ) { double timeElapsed = fpsTimer.getElapsedTime(); double timeToSleep = ((1000.0/(double)paramsInt["frameRate"])-timeElapsed)*1000; if(timeToSleep > 0) { usleep(timeToSleep); } fpsTimer.reset(); fpsTimer.start(); } while(paramsInt["frameRate"] == 0) { usleep(3000); } return rawImage; }
void QOpticalDevice::setResolution(cv::Size s) { this->resolution = s; emit resolutionChanged(s.width, s.height); }
void VersionManagerDialog::on_chkResolution_clicked() { resolutionChanged(); }
void IniReader::setResolution(const QString &s){settings.insert("resolution",s);emit resolutionChanged();}
void IniReader::finished() { settings=watcher->result(); emit readConfigChanged(); emit writeConfigChanged(); emit romPathChanged(); emit hashPathChanged(); emit samplePathChanged(); emit artPathChanged(); emit ctrlrPathChanged(); emit iniPathChanged(); emit fontPathChanged(); emit cheatPathChanged(); emit crosshairPathChanged(); emit cfgDirChanged(); emit nvramDirChanged(); emit inputDirChanged(); emit stateDirChanged(); emit snapshotDirChanged(); emit diffDirChanged(); emit commentDirChanged(); emit stateChanged(); emit autoSaveChanged(); emit playbackChanged(); emit recordChanged(); emit mngWriteChanged(); emit aviWriteChanged(); emit wavWriteChanged(); emit snapNameChanged(); emit snapSizeChanged(); emit snapViewChanged(); emit snapBilinearChanged(); emit stateNameChanged(); emit burninChanged(); emit autoFrameSkipChanged(); emit frameSkipChanged(); emit secondsToRunChanged(); emit throttleChanged(); emit sleepChanged(); emit speedChanged(); emit refreshSpeedChanged(); emit rotateChanged(); emit rorChanged(); emit rolChanged(); emit autoRorChanged(); emit autoRolChanged(); emit flipXChanged(); emit flipYChanged(); emit artworkCropChanged(); emit useBackdropsChanged(); emit useOverlaysChanged(); emit useBezelsChanged(); emit useCPanelsChanged(); emit useMarqueesChanged(); emit brightnessChanged(); emit contrastChanged(); emit gammaChanged(); emit effectChanged(); emit beamChanged(); emit flickerChanged(); emit sampleRateChanged(); emit samplesChanged(); emit volumeChanged(); emit coinLockoutChanged(); emit ctrlrChanged(); emit mouseChanged(); emit joystickChanged(); emit lightgunChanged(); emit multiKeyboardChanged(); emit multiMouseChanged(); emit steadyKeyChanged(); emit uiActiveChanged(); emit offScreenReloadChanged(); emit joystickMapChanged(); emit joystickDeadzoneChanged(); emit joystickSaturationChanged(); emit naturalChanged(); emit joystickContradictoryChanged(); emit coinImpulseChanged(); emit paddleDeviceChanged(); emit adstickDeviceChanged(); emit pedalDeviceChanged(); emit dialDeviceChanged(); emit trackballDeviceChanged(); emit lightgunDeviceChanged(); emit positionalDeviceChanged(); emit mouseDeviceChanged(); emit verboseChanged(); emit logChanged(); emit osLogChanged(); emit debugChanged(); emit updateInPauseChanged(); emit debugScriptChanged(); emit sdlVideoFPSChanged(); emit commLocalHostChanged(); emit commLocalPortChanged(); emit commRemoteHostChanged(); emit commRemotePortChanged(); emit antiAliasChanged(); emit drcChanged(); emit drcUseCChanged(); emit drcLogUMLChanged(); emit drcLogNativeChanged(); emit biosChanged(); emit cheatChanged(); emit skipGameInfoChanged(); emit uiFontChanged(); emit ramSizeChanged(); emit confirmQuitChanged(); emit uiMouseChanged(); emit autoBootCommandChanged(); emit autoBootDelayChanged(); emit autoBootScriptChanged(); emit httpChanged(); emit httpPortChanged(); emit httpPathChanged(); emit consoleChanged(); emit multiThreadingChanged(); emit numProcessorsChanged(); emit videoChanged(); emit numScreensChanged(); emit windowChanged(); emit maximizeChanged(); emit keepAspectChanged(); emit unevenStretchChanged(); emit waitVSyncChanged(); emit syncRefreshChanged(); emit screenChanged(); emit aspectChanged(); emit resolutionChanged(); emit viewChanged(); emit switchResChanged(); emit filterChanged(); emit prescaleChanged(); emit glForcePow2TextureChanged(); emit glNoTextureRectChanged(); emit glVboChanged(); emit glPboChanged(); emit glGlslChanged(); emit glGlslFilterChanged(); emit soundChanged(); emit audioLatencyChanged(); emit centerHChanged(); emit centerVChanged(); emit scaleModeChanged(); emit useAllHeadsChanged(); emit keymapChanged(); emit keymapFileChanged(); emit sixAxisChanged(); emit videoDriverChanged(); emit renderDriverChanged(); emit audioDriverChanged(); emit glLibChanged(); }
//Rendering void Core::setResolution(int x,int y) { m_resX=x; m_resY=y; emit resolutionChanged(m_resX,m_resY); }
void ChangeResolutionDialog::accept() { camera->setResolution(ui->resU->value(),ui->resV->value()); emit resolutionChanged(camera->getResolutionU(),camera->getResolutionV()); QDialog::accept(); }