Skip to content

Commit 9b25785

Browse files
committed
Added -onlyHighestMip parameter
1 parent d44de34 commit 9b25785

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

MipMapTool.cpp

+6
Original file line numberDiff line numberDiff line change
@@ -159,6 +159,11 @@ int main(int argc, char* argv[]) {
159159
allArguments.erase(namestyleArg);
160160
}
161161

162+
auto highestMIPArg = std::find_if(allArguments.begin(), allArguments.end(), [](const std::string& arg) {
163+
return arg.starts_with("-onlyHighestMip");
164+
});
165+
166+
162167
if (firstArg == "unpack") {
163168
std::cout << "Unpacking files:\n";
164169
allArguments.erase(allArguments.begin());
@@ -175,6 +180,7 @@ int main(int argc, char* argv[]) {
175180
std::filesystem::path outputPath = makeOutputPath(inputFile, mipmap, namestyle);
176181

177182
newFile->writeToFile(outputPath);
183+
if (highestMIPArg != allArguments.end()) return 0;
178184
}
179185
}
180186
return 0;

0 commit comments

Comments
 (0)