[GRASS-dev] r.in.pdf
Jarek Jasiewicz
jarekj at amu.edu.pl
Mon Jun 7 13:15:55 EDT 2010
Mohammed Rashad pisze:
> what about making a script or program in addon for doing these
> operation in single click or command
>
> --
> Rashad
>
>
> ------------------------------------------------------------------------
> *From:* Roger Miller <roger at spinn.net>
> *To:* Mohammed Rashad <rashadkm at yahoo.com>
> *Cc:* grass-dev at lists.osgeo.org
> *Sent:* Mon, June 7, 2010 6:51:08 PM
> *Subject:* Re: [GRASS-dev] r.in.pdf
>
> I don't know enough about the pdf format to give you a comprehensive
> answer, but I can tell you what I've done in the past. You will need
> more information than is inherent in the pdf; you need to know the
> projection of the map and you need the information to fit the map to its
> location.
>
> 1) use the utility pdftoppm to convert the pdf to a ppm file. pdftoppm
> is not a GRASS utility, but is commonly included in linux distributions
> and is probably available for other systems as well.
>
> 2) convert the ppm file to a jpeg or tiff file. This can be done with
> the common utilities ppmtojpeg or cjpeg, neither of which is part of
> grass.
>
> 3) construct a world file for the jpeg or tiff file. You can find
> format information for the world file in Wikipedia.
>
> 4) use r.in <http://r.in.gd>.gdal to import the file to a location
> that is correct for
> the map's projection.
>
> Usually the difficult part in the process is getting the geographic
> information necessary to fill out the world file. The process can be
> easily scripted, but it uses filters (pdftoppm and e.g. ppmtojpeg) that
> don't come with GRASS.
>
>
> Roger
>
> On Mon, 2010-06-07 at 02:21 -0700, Mohammed Rashad wrote:
> > I have a map in pdf format. i want to import the map in grass.
> > reading pdf map is available in ArcGIS. so I thought of developing and
> > contributing a module to GRASS GIS (r.in <http://r.in>.pdf) to read
> maps in pdf
> > formats directly.I dont know where to start. will anyone please
> > provide me any information or links related to importing raster maps
> > into grass gis.how a map is processed when we perform r.in.* module on
> > the map?. How files are like cellhd,fcell etc are created in GRASS?
> >
> > any help, suggestion or comments are really welcome
> >
> > --
> > Rashad
> >
> >
> >
> > _______________________________________________
> > grass-dev mailing list
> > grass-dev at lists.osgeo.org <mailto:grass-dev at lists.osgeo.org>
> > http://lists.osgeo.org/mailman/listinfo/grass-dev
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> grass-dev mailing list
> grass-dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/grass-dev
I do not see much sense of create such script. It would be rather source
of frustration, none can predict what can be in pdf so how to divide
geographical information from others like legends, symbols etc during
rasterisation or which vector is geographical data and which is not?
Esri solution concerns GeoPDF, created with ESRI and imported back as
set of data and ESRI layers so I is not a good example. I think that
problem of importing GeoPDF is rather a problem for GDAL/OGR dev team.
And AFAIK they do not work on it due to it is porperatly format. Maybe
ask GDAL devs about details.
Jarek
More information about the grass-dev
mailing list