Showing the changes to libraries/render-utils/src/DebugDeferredBuffer.cpp (1 of 1 file). Show all
Unified · Split
| @@ -76,12 +76,12 @@ static const std::string DEEFAULT_CUSTOM_SHADER { · 75 unmodified lines | |||
| 76 | }; | 76 | }; |
| 77 | 77 | ||
| 78 | static std::string getFileContent(std::string fileName, std::string defaultContent = std::string()) { | 78 | static std::string getFileContent(std::string fileName, std::string defaultContent = std::string()) { |
| 79 | QFile customFile(QUrl(QString::fromStdString(fileName)).toLocalFile()); | 79 | QFile customFile(QString::fromStdString(fileName)); |
| 80 | if (customFile.open(QIODevice::ReadOnly)) { | 80 | if (customFile.open(QIODevice::ReadOnly)) { |
| 81 | return customFile.readAll().toStdString(); | 81 | return customFile.readAll().toStdString(); |
| 82 | } | 82 | } |
| 83 | qWarning() << "DebugDeferredBuffer::getFileContent(): Could not open" | 83 | qWarning() << "DebugDeferredBuffer::getFileContent(): Could not open" |
| 84 | << QUrl(QString::fromStdString(fileName)).toLocalFile(); | 84 | << QString::fromStdString(fileName); |
| 85 | return defaultContent; | 85 | return defaultContent; |
| 86 | } | 86 | } |
| 87 | 87 | ||
| @@ -89,9 +89,9 @@ static std::string getFileContent(std::string fileName, std::string defaultConte · 1 unmodified line | |||
| 89 | DebugDeferredBuffer::DebugDeferredBuffer() { | 89 | DebugDeferredBuffer::DebugDeferredBuffer() { |
| 90 | // TODO REMOVE: Temporary until UI | 90 | // TODO REMOVE: Temporary until UI |
| 91 | static const auto DESKTOP_PATH = QStandardPaths::writableLocation(QStandardPaths::DesktopLocation); | 91 | static const auto DESKTOP_PATH = QStandardPaths::writableLocation(QStandardPaths::DesktopLocation); |
| 92 | static const auto CUSTOM_FILE = "file://" + DESKTOP_PATH.toStdString() + "/custom.slh"; | 92 | static const auto CUSTOM_FILE = DESKTOP_PATH.toStdString() + "/custom.slh"; |
| 93 | CustomPipeline pipeline; | 93 | CustomPipeline pipeline; |
| 94 | pipeline.info = QFileInfo(DESKTOP_PATH + "/custom.slh"); | 94 | pipeline.info = QFileInfo(QString::fromStdString(CUSTOM_FILE)); |
| 95 | _customPipelines.emplace(CUSTOM_FILE, pipeline); | 95 | _customPipelines.emplace(CUSTOM_FILE, pipeline); |
| 96 | } | 96 | } |
| 97 | 97 | ||