comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: Process series of image files?
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Process series of image files? [message #53212 is a reply to message #53211] Thu, 29 March 2007 09:46 Go to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
go cats writes:

> I have another question. I learned that dialog_pickfile() is useful to
> pick an input file, instead of modifying and save code. Is there a way
> to define output file name in thay way? I mean specifying user defined
> output file name, instead of modifying write_tiff every time.

This is, generally, what is meant by the term "programming". :-)

; Get all the input TIFF files in directory.
files = File_Search('*.tif', Count=count)

; Process each file somehow...
FOR j=0,count-1 DO BEGIN
something, something, something

; Write the file out with a changed name.
dir = File_DirName(file, /Mark_Directory)
basename = File_BaseName(file, '.tif')
outfile = dir + basename +'.processed.tif'
Write_Tiff, outfile, processedImage
ENDFOR

Cheers,

David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
[Message index]
 
Read Message
Read Message
Read Message
Previous Topic: Re: 14 bit image in false color
Next Topic: Re: We have file_lines for lines in IDL. What about file_rows?

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Sun Oct 12 04:46:56 PDT 2025

Total time taken to generate the page: 1.44338 seconds