GIF Raster Image Process Problem {Scanned}

Siki Zoltan siki at AGT.BME.HU
Fri May 6 04:27:05 PDT 2005


Dear Akio,

The formula looks like:
X = Ax + By + C and Y = Dx + Ey + F (Affine transformation)
The order of the parameters in the world file is:
A
D
B
E
C
F

The process to find out the values of the parameters is called
georeferencing. There are a loft of programs what can solve the task
specifying point on the raster and giving the real co-ordinates for them.
Unfortunatelly I use commercial software for this purpose, but I think
GRASS can do it.
Usually more then the minimal 3 points are used with a least squares
estimation.

I hope it helps you

Zoltan

On Fri, 6 May 2005, Akio Neuchi wrote:

> Dear Zoltan、
>
> Sorry for my late reply.
> We were in long holidays here in Japan.
> Thank you for your recommendations.
> In fact, by adjusting World file, the Raster/Vector Images finally so-so well superimposed,
> except the coordinates of these images are a bit dislocated, depend on the 1st and 4th pixel values on the World file.
> Though I am adjusting manually those numbers, what is the right formula to get the X and Y pixel dimensions?
> Thanks again for your help.
>
> Akio
>
> <World file>
> 0.000038
> 0.0000000000
> 0.0000000000
> -0.000038
> 139.738114
> 35.691990000000004
>
> MAP #file
> NAME rastest
> STATUS ON
> SIZE 600 700
> EXTENT 139.5 35.5 140 36
> UNITS dd
> SHAPEPATH "data"
> FONTSET "./fonts/fonts.lst"
> IMAGECOLOR 225 240 200
> IMAGETYPE GIF
>
> # Projection definition, set-upped by PROJ.4 parameters
> PROJECTION
> #     "init=epsg:26915"
>       "proj=latlong"
> END
>
> # Web interface definition (including WMS enabling metadata)
> WEB
>       EMPTY "/gistest/empty.html"
>       HEADER decide_route_header.html
>       TEMPLATE decide_route.html
>       FOOTER decide_route_footer.html
>       MINSCALE 0
>       MAXSCALE 300000000
>       IMAGEPATH /var/opt/SUNWappserver7/domains/domain1/server1/docroot/gistest/tmp
>       IMAGEURL /gistest/tmp
>       LOG /var/opt/SUNWappserver7/domains/domain1/server1/docroot/gistest/rastest.log
> #     TEMPLATE "decide_route.html"
>       METADATA
>               WMS_TITLE "MapDisplay Demo"
>               WMS_ABSTRACT "Created by AN"
>               WMS_ACCESSCONSTRAINTS none
>       END
> END
>
> QUERYMAP
>       SIZE 200 200
>       STATUS ON
>       STYLE HILITE
>       COLOR 255 0 0
> END
>
> OUTPUTFORMAT
>      NAME gif
>      MIMETYPE "image/gif"
>      DRIVER "GD/GIF"
>      EXTENSION "gif"
> #    IMAGEMODE RGB
> IMAGEMODE PC256
>      TRANSPARENT FALSE
> #    TRANSPARENT TRUE
> #    FORMATOPTION "INTERLACE=OFF"
> END
>
> ### RASTER Layer
> LAYER
>       NAME "RAS365313"
>       GROUP "B_RASTER"
>       TYPE RASTER
>       DATA "MS12000DEF365313.gif"
> #     STATUS ON
>       STATUS DEFAULT
>         TRANSPARENCY 100
> #     OFFSITE 125 135 148
>       PROJECTION
>               "proj=latlong"
> #             "init=epsg:26915"
>       END
>       PROCESSING "LOAD_WHOLE_IMAGE=TRUE"
> END
>
> # here starts Vector Layers
> # background - Parks
> LAYER
>       NAME "BARA_PARK_AREA"
>       GROUP "BARA_PARK"
>       TILEINDEX "v_bak_ara_park"
>       STATUS ON
>       MAXSCALE 200000
>       TYPE POLYGON
>       PROJECTION
> #             "init=epsg:26915"
>               "proj=latlong"
>       END
>       CLASS
>               BACKGROUNDCOLOR 0 220 0
>               COLOR 150 200 100
> #             COLOR 154 205 50
>       END
> END
>
> # background - Sea surface
> LAYER
>       NAME "BARA_SEA"
>       TILEINDEX "v_bak_ara_sea"
>       STATUS default
>       TYPE POLYGON
>       PROJECTION
> #             "init=epsg:26915"
>               "proj=latlong"
>       END
>       CLASS
>               BACKGROUNDCOLOR 0 255 255
>               COLOR 100 149 237
>       END
> END
>
> # background - Rivers
> LAYER
>       NAME "BLIN_RIVER"
>       TILEINDEX "v_bak_lin_river"
>       STATUS default
>       MAXSCALE 200000
>       TYPE LINE
>       PROJECTION
> #             "init=epsg:26915"
>               "proj=latlong"
>       END
>       CLASS
>               BACKGROUNDCOLOR 0 255 255
>               COLOR 100 149 237
>       END
> END
> END # Map File
>
> -----Original Message-----
> From: Siki Zoltan [mailto:siki at agt.bme.hu]
> Sent: Friday, April 29, 2005 5:31 PM
> To: Akio Neuchi
> Cc: MAPSERVER-USERS at LISTS.UMN.EDU
> Subject: Re: [UMN_MAPSERVER-USERS] GIF Raster Image Process Problem {Scanned}
>
>
> Dear Akio,
>
> You should define EXTENT, UNITS and SHAPEPATH at separate lines.
> Do you have world file to your image? Check the extents.
> Try STATUS DEFAULT.
>
> Bye Zoltan
>
>
>



More information about the MapServer-users mailing list