Merge pull request #1119 from stweil/ssize_t
[openjpeg.git] / src / bin / jp2 / opj_decompress.c
index a963b86a57724e33e84567c38687dbe3b18e2ded..a28a194bb7c738d23bc121d2d4c79d33fe021d91 100644 (file)
@@ -134,7 +134,7 @@ typedef struct opj_decompress_params {
     /** Verbose mode */
     OPJ_BOOL m_verbose;
 
-    /** tile number ot the decoded tile*/
+    /** tile number of the decoded tile */
     OPJ_UINT32 tile_index;
     /** Nb of tile to decode */
     OPJ_UINT32 nb_tile_to_decode;
@@ -242,8 +242,8 @@ static void decode_help_display(void)
             "  -split-pnm\n"
             "    Split output components to different files when writing to PNM\n");
     if (opj_has_thread_support()) {
-        fprintf(stdout, "  -threads <num_threads>\n"
-                "    Number of threads to use for decoding.\n");
+        fprintf(stdout, "  -threads <num_threads|ALL_CPUS>\n"
+                "    Number of threads to use for decoding or ALL_CPUS for all available cores.\n");
     }
     fprintf(stdout, "  -quiet\n"
             "    Disable output from the library and other output.\n");
@@ -1548,6 +1548,14 @@ int main(int argc, char **argv)
                 goto fin;
             }
         } else {
+            if (!(parameters.DA_x0 == 0 &&
+                    parameters.DA_y0 == 0 &&
+                    parameters.DA_x1 == 0 &&
+                    parameters.DA_y1 == 0)) {
+                if (!(parameters.quiet)) {
+                    fprintf(stderr, "WARNING: -d option ignored when used together with -t\n");
+                }
+            }
 
             if (!opj_get_decoded_tile(l_codec, l_stream, image, parameters.tile_index)) {
                 fprintf(stderr, "ERROR -> opj_decompress: failed to decode tile!\n");