[Scummvm-git-logs] scummvm-tools master -> 6d6ed5a71cbfbd17f91259bb60a563c77dc7c2c0

criezy criezy at scummvm.org
Sun Dec 4 20:01:40 CET 2016


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm-tools' repo located at https://github.com/scummvm/scummvm-tools .

Summary:
6d6ed5a71c TOOLS: Fix handling of output path for compress_touche tool


Commit: 6d6ed5a71cbfbd17f91259bb60a563c77dc7c2c0
    https://github.com/scummvm/scummvm-tools/commit/6d6ed5a71cbfbd17f91259bb60a563c77dc7c2c0
Author: Thierry Crozat (criezy at scummvm.org)
Date: 2016-12-04T19:01:19Z

Commit Message:
TOOLS: Fix handling of output path for compress_touche tool

The tool was only accepting output directories but not files, but was
not handling properly setting the output file name when an output
directory was provided. Now we can provide either an output directory
or output file name and both work as expected.

Changed paths:
    NEWS
    engines/touche/compress_touche.cpp


diff --git a/NEWS b/NEWS
index fa56aa6..dee9c2d 100644
--- a/NEWS
+++ b/NEWS
@@ -1,6 +1,9 @@
 For a more comprehensive changelog of the latest experimental code, see:
         https://github.com/scummvm/scummvm-tools/commits/
 
+1.10.0 (YYYY-MM-DD)
+ - Fix handling of output path for the compress_touche tool.
+
 1.9.0 (2016-10-27)
  - Fix random crashes in the tool to convert Broken Sword 1 speech files.
 
diff --git a/engines/touche/compress_touche.cpp b/engines/touche/compress_touche.cpp
index 4cc6803..beb9dee 100644
--- a/engines/touche/compress_touche.cpp
+++ b/engines/touche/compress_touche.cpp
@@ -44,13 +44,14 @@ static uint32 input_Vxx_size[Vxx_HDR_LEN];
 
 CompressTouche::CompressTouche(const std::string &name) : CompressionTool(name, TOOLTYPE_COMPRESSION) {
 	_supportsProgressBar = true;
+	_outputToDirectory = false;
 
 	ToolInput input;
 	input.format = "/";
 	_inputPaths.push_back(input);
 
 	_shorthelp = "Used to compress Touche speech files (Vxxx and OBJ).";
-	_helptext = "\nUsage: " + getName() + " [params] [-o outputfile TOUCHE.*] <inputdir>\n* differs with compression type.\n" + _shorthelp + "\n";
+	_helptext = "\nUsage: " + getName() + " [params] [-o outputfile] <inputdir>\n* differs with compression type.\n" + _shorthelp + "\n";
 }
 
 InspectionMatch CompressTouche::inspectInput(const Common::Filename &filename) {
@@ -184,7 +185,7 @@ void CompressTouche::execute() {
 	Common::Filename inpath(_inputPaths[0].path);
 	Common::Filename &outpath = _outputPath;
 
-	if (outpath.empty()) {
+	if (outpath.getFullName().empty()) {
 		switch(_format) {
 		case AUDIO_MP3:
 			outpath.setFullName(OUTPUT_MP3);





More information about the Scummvm-git-logs mailing list