MCPcopy Create free account
hub / github.com/Nadrin/Quartz / requestSaveImage

Method requestSaveImage

apps/quartz/renderwindow.cpp:100–112  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

98}
99
100bool RenderWindow::requestSaveImage()
101{
102 QFileDialog dialog(nullptr, tr("Save Image"));
103 dialog.setNameFilter(tr("Image files (*.jpg *.png *.bmp *.tga *.hdr)"));
104 dialog.setFileMode(QFileDialog::AnyFile);
105 dialog.setAcceptMode(QFileDialog::AcceptSave);
106 dialog.setDirectory(QDir::currentPath());
107 if(dialog.exec()) {
108 const QString path = dialog.selectedFiles().at(0);
109 return saveImage(path);
110 }
111 return false;
112}
113
114bool RenderWindow::saveImage(const QString &path)
115{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected