filename problem when resizing (keep format)

Discussions on NConvert - the command line tool for image conversion and manipulation

Moderators: XnTriq, xnview

Post Reply
jj238095
Posts: 4
Joined: Fri Jun 03, 2011 11:49 am

filename problem when resizing (keep format)

Post by jj238095 » Fri Jun 03, 2011 12:15 pm

Hello,

I have a folder with files in different formats. They all should be resized to a new folder, but the filename and the format should be the same:

nconvert -v -truecolors -npcd 2 -size 256x256+0 -ctype grey -corder inter -o X:\resized\%% -ratio -rtype lanczos -rflag decr -resize 200 200 -bgcolor 255 255 255 -canvas 200 200 center -l filelist.txt

My problem: The new files get created without extention. I could not figure out the syntax for -o to just get the same filename in the destination folder.

Any reply is appreciated.

User avatar
xnview
Author of XnView
Posts: 29744
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: filename problem when resizing (keep format)

Post by xnview » Fri Jun 03, 2011 1:04 pm

you have no -out option?
Pierre.

jj238095
Posts: 4
Joined: Fri Jun 03, 2011 11:49 am

Re: filename problem when resizing (keep format)

Post by jj238095 » Fri Jun 03, 2011 9:28 pm

Hello Pierre,

since I want the output format to be the same as the input I just tried without -out. It seems to work: nconvert does the resizing and leaves the format the same. It's just that the filenames get created witout the extension.
cmd output:

Code: Select all

C:\temp>nconvert -v -npcd 2 -size 256x256+0 -ctype grey -corder inter -ratio -rtype lanczos -rflag decr -resize 200 200 -bgcolor 255 255 255 -canvas 200 200 center -o C:\temp\ncneu\% C:\temp\nconverttest\*.*
** NCONVERT v5.90 (c) 1991-2011 Pierre-E Gougelet (May 12 2011/13:59:51) **
        Version for Windows Xp/Vista/7 x64  (All rights reserved)
** This is a freeware software (for non commercial use)

A Adobe Photoshop Document (RGB) - Rle was recognized : C:\temp\nconverttest\here.comes.psd.psd
    Width:1920 Height:1200 with 16777216 colors
    Nplanes : 3      Bitscount : 8
    Bytes Per Plane : 1920
    xdpi : 72         ydpi : 72
Resizing : OK
Resizing canvas : OK
Conversion of C:\temp\nconverttest\here.comes.psd.psd into C:\temp\ncneu\here.comes.psd OK

A Portable Network Graphics (RGB) - ZIP was recognized : C:\temp\nconverttest\oh-look-a-png.png
    Width:1920 Height:1200 with 16777216 colors
    Nplanes : 1      Bitscount : 24
    Bytes Per Plane : 5760
    xdpi : 96         ydpi : 96
Resizing : OK
Resizing canvas : OK
Conversion of C:\temp\nconverttest\oh-look-a-png.png into C:\temp\ncneu\oh-look-a-png OK

A Windows Bitmap (RGB) was recognized : C:\temp\nconverttest\some_bmp_01.bmp
    Width:1920 Height:1200 with 16777216 colors
    Nplanes : 1      Bitscount : 24
    Bytes Per Plane : 5760
    xdpi : 96         ydpi : 96
Resizing : OK
Resizing canvas : OK
Conversion of C:\temp\nconverttest\some_bmp_01.bmp into C:\temp\ncneu\some_bmp_01 OK

A Compuserve GIF (Version 89a) (RGB) - LZW was recognized : C:\temp\nconverttest\this_is_a_gif.gif
    Width:1920 Height:1200 with 256 colors
    Nplanes : 1      Bitscount : 8
    Bytes Per Plane : 1920
    xdpi : 0         ydpi : 0
Resizing : OK
Resizing canvas : OK
  Error: This picture cannot be written using this format (C:\temp\ncneu\this_is_a_gif)

A TIFF (RGB) - LZW was recognized : C:\temp\nconverttest\tif-009.tif
    Width:1920 Height:1200 with 16777216 colors
    Nplanes : 1      Bitscount : 24
    Bytes Per Plane : 5760
    xdpi : 96         ydpi : 96
Resizing : OK
Resizing canvas : OK
Conversion of C:\temp\nconverttest\tif-009.tif into C:\temp\ncneu\tif-009 OK


C:\temp>pause
Have a nice weekend!

User avatar
xnview
Author of XnView
Posts: 29744
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: filename problem when resizing (keep format)

Post by xnview » Mon Jun 06, 2011 7:32 am

Ok, right, i'll fix it
Pierre.

jj238095
Posts: 4
Joined: Fri Jun 03, 2011 11:49 am

Re: filename problem when resizing (keep format)

Post by jj238095 » Mon Jun 06, 2011 12:01 pm

Je vous remercie pour votre réponse rapide et pour ses efforts!

Post Reply