X
PrevPrev Go to previous topic
NextNext Go to next topic
Last Post 27 Sep 2006 05:54 PM by  anon
Image math
 1 Replies
Sort:
You are not authorized to post a reply.
Author Messages

anon



New Member


Posts:
New Member


--
27 Sep 2006 05:54 PM
    How can I do image math in IDL? I'd like to add, subtract and divide an image with the other image. Thank you in advance.

    Deleted User



    New Member


    Posts:
    New Member


    --
    27 Sep 2006 05:54 PM
    Making image math easy to code and efficient to run is probably the main focus of the IDL language. IDL calls itself an "array-based language" because the kinds of tasks you want to do are as easy as: IDL> help, myimage MYIMAGE BYTE = Array[400, 200] IDL> help, myimage2 MYIMAGE2 BYTE = Array[400, 200] ; Subtract an array IDL> diffImage = myimage - myimage2 IDL> help, diffImage DIFFIMAGE BYTE = Array[400, 200] ; Divide by a scalar IDL> halfMyimage = myimage / 1.5 ; Multiply by an array IDL> help, filterImage FILTERIMAGE BYTE = Array[400, 200] IDL> filteredImage = myImage * filterImage James Jones
    You are not authorized to post a reply.