From: Efren S. <efr...@me...> - 2007-11-27 18:35:47
|
Arlindo, With the perl interface, can you encode colors in a shapefile? We shouldn't encode colors in the shapefiles; I was hoping to use these shapefiles in conjunction with Mapserver and let the coloring to = mapserver .map configuration file. However, we should encode some values about = the shape in the .dbx file so that we can use mapserver's .map file CLASS = value, which defines thematic classes for a given layer. A CLASS has an = EXPRESSION value that we can use to select coloring, etc., based on a value encoded in = the .dbx file. For instance, here is simple sample for coloring Tropical Cyclone Warnings Wind Radiis/Track: LAYER NAME "al062007_019_34ktWndRadii" GROUP "tcw" METADATA "wms_title" "al062007_019_34ktWndRadii" ##required END TYPE POLYGON STATUS OFF DATA /otsr/shapefiles/2007091100/al062007_019_34ktWndRadii LABELITEM "RADIUS_NM" CLASS NAME "al062007_019_34ktWndRadii" OUTLINECOLOR 255 0 0 LABEL MINFEATURESIZE 50 MINDISTANCE 150 POSITION CC SIZE TINY COLOR 0 0 0 END DEBUG ON END DUMP TRUE PROJECTION "init=3Depsg:4326" ##recommended END END # Layer al062007_019_34ktWndRadii LAYER NAME "ep102007_017_track" GROUP "tcw" METADATA "wms_title" "ep102007_017_track" ##required END TYPE LINE STATUS OFF DATA /otsr/shapefiles/2007091100/ep102007_017_track LABELITEM "STM_NAME" CLASS NAME "ep102007_017_track" COLOR 0 0 0 LABEL MINFEATURESIZE 50 MINDISTANCE 150 POSITION CC SIZE TINY COLOR 0 0 0 END DEBUG ON END DUMP TRUE PROJECTION "init=3Depsg:4326" ##recommended END END # Layer ep102007_017_track - how to draw a line in black, and another in green Mapserver takes care of the drawing for us via the .map file by using OUTLINECOLOR - how to have a rectangle filled "blue" Mapserver takes care of the drawing for us via the .map file by using = COLOR - how to define new colors from (red,green,blue) values COLOR and OUTLINECOLOR take RGB values as shown above. Do you have access to any GIS software? Is there a free alternative to ARC/View? Which one do you recommend? I just want a way to see if the = file we eventually produce with GrADS can be visualized by standard GIS = software. Lets use Mapserver from UMN: http://mapserver.gis.umn.edu. Thanks. Efren |