[postgis-users] Basic postgis raster questions

2011-06-02 Thread Bryce L Nordgren
I started drooling over ST_Histogram() in postgis trunk. Thus far, I think 
my use case prevents me from using it, but I'd like to confirm with the 
list.

I have a raster (derived image from a Landsat scene) which is coarsely 
tiled: 833x833. This gives me 110 tiles for the scene. Separately, I have 
a polygon coverage of a fire perimeter.

Basically, what I want to do is this: 

1] Globally (i.e., not for an individual tile, but for the entire scene) I 
want one histogram of raster values for pixels which are inside the fire 
perimeter, and one histogram of raster values for pixels which are 
outside.
2] For each individual tile, I want separately computed histograms for 
pixels inside and outside the fire perimeter.

My understanding is that I cannot do #2 because ST_Intersection() always 
returns a setof geomval, and never returns a "subset raster". I believe I 
cannot do #1 because in addition to this ST_Intersection behavior, there 
is no way to re-assemble the tiles into one giant raster prior to feeding 
it to ST_Histogram. It appears I can run ST_Histogram only on individual, 
whole tiles.

I am currently pursuing a vector solution using ST_DumpAsPolygons() but 
this is very slow. Hence I have time to send questions to the list. :) 

I have outlined my vector plan of attack here: 
https://collab.firelab.org/software/projects/modisfire/wiki/Calculating_histograms_with_PostGIS_Raster
 
 If you believe this to be a worthy tutorial-in-progress, you may copy or 
link to it as you see fit. I expect it will change as I pursue this 
activity further.

Bryce___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


[postgis-users] Gdal translate Error checking geometry type existence problem

2011-06-02 Thread Virginia Maffei
Hi, i loaded a tif with raster2pgsql into the database and now i'm trying to
get from that table a tif with gdal_translate.
But this error appears:

C:\Archivos de programa\GDAL>gdal_translate PG:"dbname=template_postgis20
user=postgres table=HumedadDeExtincion mode=2" your_file.tif
ERROR 1: Error checking geometry type existence. Is PostGIS correctly
  installed?: no connection to the server

GDALOpen failed - 1
Error checking geometry type existence. Is PostGIS correctly installed?: no
connection to the server

I installed in windows the postgis raster with gdal, python, etc.

Could you please help me with this problem?

Thanks!

Virginia
___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


Re: [postgis-users] Mapserver connection to Postgis Raster

2011-06-02 Thread Virginia Maffei
Hola! estoy intentando cargar manualmente el raster support y estoy
ejecutando el rtpostgissql que trae el postgis2.0
Pero al ejecutarlo me tira que no existe la funcion box2d(raster)
Alguna idea de que puede estar pasando?
Gracias!

PD: Escribí en español porque me pareció ver que son de españa y yo en
realidad hablo en español.

saludos!

Virginia



On Thu, Jun 2, 2011 at 11:16 AM, Virginia Maffei  wrote:

> Thank you!! I will try that installation
>
> Virginia
>
>
>
> 2011/6/2 Jorge Arévalo 
>
>> On Thu, Jun 2, 2011 at 3:25 PM, Virginia Maffei 
>> wrote:
>> > Thank you for your quick response!
>> > I have another question: can i install postgis 2.0 in windows? where can
>> I
>> > download it?
>> >
>> >
>> > Virginia
>> >
>>
>> Yes, you can. Follow this post's instructions:
>>
>> http://gis4free.wordpress.com/2011/03/10/how-to-install-and-configure-postgis-raster-on-windows/
>>
>> Best regards,
>> Jorge
>>
>>
>> >
>> > 2011/6/2 Jorge Arévalo 
>> >>
>> >> Hi,
>> >>
>> >> The mode=2 parameter is only valid with the last version of GDAL
>> >> (1.8.0). So, as Regina said, you need that version to make it work
>> >> properly. More accurately:
>> >>
>> >> - With a GDAL version down to 1.7.1, you can't make it work in any
>> >> way. No driver.
>> >>
>> >> - With a GDAL version between 1.7.1 and 1.7.3, both included, you can
>> >> use the old version of the driver, thought to work with the old
>> >> wktraster extension, now abandoned. And it was buggy. Not recommended.
>> >>  Neither GDAL 1.7.x nor wktraster.
>> >>
>> >> - With GDAL version up to 1.8.0, you can use the last version of GDAL
>> >> PostGIS Raster driver, and you'll need PostGIS 2.0, that includes
>> >> PostGIS Raster extension. Additionally, as Regina said, those days
>> >> we're working on the driver, and all the improvements will be included
>> >> in GDAL 1.8.x
>> >>
>> >> So, summarizing: You need PostGIS 2.0 plus GDAL 1.8.0 to make it work.
>> >>
>> >> Further information on the driver:
>> >> http://trac.osgeo.org/gdal/wiki/frmts_wtkraster.html
>> >>
>> >> Best regards,
>> >> Jorge
>> >>
>> >> On Thu, Jun 2, 2011 at 6:53 AM, Paragon Corporation 
>> wrote:
>> >> > Virginia,
>> >> >
>> >> > I think you are missing a mode='2'  in your connection.  That was a
>> new
>> >> > requirement that was added for GDAL 1.8+
>> >> >
>> >> > Try putting that in.  I think the speed on the loading still needs
>> quite
>> >> > a
>> >> > bit of work though last I tried.  The speed issues will hopefully be
>> >> > resolved before 2.0 release.
>> >> >
>> >> > Thanks,
>> >> > Regina
>> >> > http://www.postgis.us
>> >> >
>> >> >
>> >> > 
>> >> > From: postgis-users-boun...@postgis.refractions.net
>> >> > [mailto:postgis-users-boun...@postgis.refractions.net] On Behalf Of
>> >> > Virginia
>> >> > Maffei
>> >> > Sent: Wednesday, June 01, 2011 8:00 PM
>> >> > To: postgis-users@postgis.refractions.net
>> >> > Subject: [postgis-users] Mapserver connection to Postgis Raster
>> >> >
>> >> > Hi, i'm new at this and i'm trying to connect to postgis raster in
>> the
>> >> > mapfile.
>> >> > I loaded a tif file into postgis raster database with the
>> >> > raster2pgsql.py
>> >> > script. It created a table with 2 fields: rid and rast.
>> >> > In the mapfile i added the connection like it specifies in the
>> postgis
>> >> > raster FAQ but it doesn't displays anything.
>> >> > This is my mapfile:
>> >> > MAP
>> >> >   IMAGETYPE  PNG24
>> >> >   EXTENT 366582.2901411663 6127927.100382689
>> 857582.2901411663
>> >> > 6670927.100382689
>> >> >   SIZE   491 543
>> >> >   SHAPEPATH  "../data"
>> >> >   LAYER # MODIS raster layer begins here
>> >> > NAME modis
>> >> > TYPE RASTER
>> >> > STATUS   ON
>> >> > DATA "PG:host=localhost port=5432 dbname='postgis' user='postgres'
>> >> > password='postgres' schema='public' table='HumedadDeExtincion'"
>> >> > PROCESSING "NODATA=0"
>> >> > PROCESSING "SCALE=AUTO"
>> >> > PROCESSING "SCALE_BUCKETS=201"
>> >> > PROCESSING   "BANDS=1"
>> >> > OFFSITE  71 74 65
>> >> > CLASS
>> >> > NAME "red"
>> >> > EXPRESSION ([pixel] < 10)
>> >> > COLOR 255 0 0
>> >> > END
>> >> > CLASS
>> >> > NAME "green"
>> >> > EXPRESSION ([pixel] >= 10 AND [pixel] < 15000 )
>> >> > COLOR 0 255 0
>> >> > END
>> >> > CLASS
>> >> > NAME "blue"
>> >> > EXPRESSION ([pixel] >= 15000 )
>> >> > COLOR 0 255 0
>> >> > END
>> >> >   END # MODIS raster layer ends here
>> >> >
>> >> >   # End of LAYER DEFINITIONS ---
>> >> > END # All map files must come to an end just as all other things must
>> >> > come
>> >> > to...
>> >> >
>> >> > I have gdal 1.6 , postgis 1.5 and ms4w with mapserver 5.6.6
>> >> > We cant see the tiff file on the browser, it only appears a white
>> image.
>> >> > We did try with the tif without the database connection an it works.
>> >> > Could you help us?
>> >> > Thank you
>> >> >
>> >> > ___
>> >

[postgis-users] Volker Emmel ist außer Haus.

2011-06-02 Thread volker . emmel

Ich werde ab  02.06.2011 nicht im Büro sein. Ich kehre zurück am
13.06.2011.

Ich werde mich nach Rückkehr um die Nachrichten kümmern.

___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


[postgis-users] #PgWest call for papers

2011-06-02 Thread Joshua D. Drake

Hey folks,

Just FYI the call for papers for #PgWest @ San Jose from 09/27-09/30 is 
now open. https://www.postgresqlconference.org/


JD
--
Command Prompt, Inc. - http://www.commandprompt.com/
PostgreSQL Support, Training, Professional Services and Development
The PostgreSQL Conference - http://www.postgresqlconference.org/
@cmdpromptinc - @postgresconf - 509-416-6579
___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


Re: [postgis-users] Create circles using a formula

2011-06-02 Thread vikashvikky

Hi Brent,

   I am really thankful for your reply. The equation I am to use for
calculating radius is 
   radius=(lambda/4*pi)*sqrt((Pt*Gt*Gr)/Pr)

My towers table contains the following columns
tid,lat,lon,lambda,Pt,Gt,Gr,Pr

so as you said the query should be

CREATE VIEW circles AS SELECT tower_id, ST_BUFFER( ST_Transform( ST_SetSRID(
ST_MakePoint(lon,lat), 4326), 900913, (lambda/4*pi)*sqrt((Pt*Gt*Gr)/Pr) ) AS
tower_circle FROM towers

Now for geoserver to generate the circles , creating the postgis store with
table data as layer is enough I guess. Am I going in a right way?


pcreso wrote:
> 
> I'm not conversant with geoserver but have used mapserver to do this sort
> of thing often enough.
> 
> I assume your data is in PostGIS, which means your mapserver DATA
> statement can be an embedded SQL query or a PostGIS view.
> 
> You can create a view on your table, along the lines of:
> 
> create view v_table 
> as select *, buffer(setsrid(makepoint(lon, lat),4326), calculate radius>) as geom
> from table;
> 
> (assuming you want the output data in EPSG:4326)
> 
> or you can set up your process to build the geometry in a physical table
> doing much the same thing, perhaps as an update or insert trigger?
> 
> Use this view, or table as the "table" you provide the WFS service from, &
> the geometries you are providing will be suitably sized circles.
> 
> Note this assumes a constant signal strength unchanged by topography,
> which is very simplistic.
> 
> Tools like GRASS allow you to apply a terrain model to the sites & carry
> out a line-of-sight analysis to generate more accurate polygons descibing
> the expected coverage from a tower.
> 
> If you are displaying thousands of features, you might find WMS with
> srever side rendering gives a better response time than WFS. Geoserver can
> provide both WMS & WFS services, but I think mapserver has some advantages
> in the WMS arena.
> 
> HTH,
> 
>   Brent Wood
>  
>  
> On 02/06/2011, at 3:55 AM, vikashvikky wrote:
> 
>> 
>> Hi,
>> 
>> I am doing a project for a telecom company. I have to render circles on
>> the
>> map(assuming the center of the circle as tower and circle as the area
>> covered by that signal), I am using base layers as Google Maps,Yahoo
>> maps(Spherical Mercator) So I have used CreateGeodesicPolygon()
>> successfully
>> to create circles by reading the values from DB.
>> 
>> Now Since I have to render lot of circles, it made me switch to
>> geoserver.
>> Since the data is being provided by telecom company , they provide
>> Lat,Lon,Gt,Gr,Pt,Pr,lambda(I think their meaning is irrelevant here)
>> values.
>> These values are stored in the database as they are. Now should use a
>> equation(FRIIS transmission equation) and substitute each row(of a tower)
>> values to find the distance covered by the tower.Then I have to create
>> circles with that distance(considered as radius) and lon/lat and render
>> them
>> on map using geoserver.
>> 
>> Please suggest me any ideas of how to carry on this task I wud be
>> thankful to your guidance
>> -- 
>> View this message in context:
>> http://old.nabble.com/Create-circles-using-a-formula-tp31752667p31752667.html
>> Sent from the PostGIS - User mailing list archive at Nabble.com.
>> 
>> ___
>> postgis-users mailing list
>> postgis-users@postgis.refractions.net
>> http://postgis.refractions.net/mailman/listinfo/postgis-users
> 
> ___
> postgis-users mailing list
> postgis-users@postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
> 
> ___
> postgis-users mailing list
> postgis-users@postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
> 
> 

-- 
View this message in context: 
http://old.nabble.com/Create-circles-using-a-formula-tp31752667p31758593.html
Sent from the PostGIS - User mailing list archive at Nabble.com.

___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


Re: [postgis-users] Mapserver connection to Postgis Raster

2011-06-02 Thread Virginia Maffei
Thank you!! I will try that installation

Virginia


2011/6/2 Jorge Arévalo 

> On Thu, Jun 2, 2011 at 3:25 PM, Virginia Maffei  wrote:
> > Thank you for your quick response!
> > I have another question: can i install postgis 2.0 in windows? where can
> I
> > download it?
> >
> >
> > Virginia
> >
>
> Yes, you can. Follow this post's instructions:
>
> http://gis4free.wordpress.com/2011/03/10/how-to-install-and-configure-postgis-raster-on-windows/
>
> Best regards,
> Jorge
>
>
> >
> > 2011/6/2 Jorge Arévalo 
> >>
> >> Hi,
> >>
> >> The mode=2 parameter is only valid with the last version of GDAL
> >> (1.8.0). So, as Regina said, you need that version to make it work
> >> properly. More accurately:
> >>
> >> - With a GDAL version down to 1.7.1, you can't make it work in any
> >> way. No driver.
> >>
> >> - With a GDAL version between 1.7.1 and 1.7.3, both included, you can
> >> use the old version of the driver, thought to work with the old
> >> wktraster extension, now abandoned. And it was buggy. Not recommended.
> >>  Neither GDAL 1.7.x nor wktraster.
> >>
> >> - With GDAL version up to 1.8.0, you can use the last version of GDAL
> >> PostGIS Raster driver, and you'll need PostGIS 2.0, that includes
> >> PostGIS Raster extension. Additionally, as Regina said, those days
> >> we're working on the driver, and all the improvements will be included
> >> in GDAL 1.8.x
> >>
> >> So, summarizing: You need PostGIS 2.0 plus GDAL 1.8.0 to make it work.
> >>
> >> Further information on the driver:
> >> http://trac.osgeo.org/gdal/wiki/frmts_wtkraster.html
> >>
> >> Best regards,
> >> Jorge
> >>
> >> On Thu, Jun 2, 2011 at 6:53 AM, Paragon Corporation 
> wrote:
> >> > Virginia,
> >> >
> >> > I think you are missing a mode='2'  in your connection.  That was a
> new
> >> > requirement that was added for GDAL 1.8+
> >> >
> >> > Try putting that in.  I think the speed on the loading still needs
> quite
> >> > a
> >> > bit of work though last I tried.  The speed issues will hopefully be
> >> > resolved before 2.0 release.
> >> >
> >> > Thanks,
> >> > Regina
> >> > http://www.postgis.us
> >> >
> >> >
> >> > 
> >> > From: postgis-users-boun...@postgis.refractions.net
> >> > [mailto:postgis-users-boun...@postgis.refractions.net] On Behalf Of
> >> > Virginia
> >> > Maffei
> >> > Sent: Wednesday, June 01, 2011 8:00 PM
> >> > To: postgis-users@postgis.refractions.net
> >> > Subject: [postgis-users] Mapserver connection to Postgis Raster
> >> >
> >> > Hi, i'm new at this and i'm trying to connect to postgis raster in the
> >> > mapfile.
> >> > I loaded a tif file into postgis raster database with the
> >> > raster2pgsql.py
> >> > script. It created a table with 2 fields: rid and rast.
> >> > In the mapfile i added the connection like it specifies in the postgis
> >> > raster FAQ but it doesn't displays anything.
> >> > This is my mapfile:
> >> > MAP
> >> >   IMAGETYPE  PNG24
> >> >   EXTENT 366582.2901411663 6127927.100382689 857582.2901411663
> >> > 6670927.100382689
> >> >   SIZE   491 543
> >> >   SHAPEPATH  "../data"
> >> >   LAYER # MODIS raster layer begins here
> >> > NAME modis
> >> > TYPE RASTER
> >> > STATUS   ON
> >> > DATA "PG:host=localhost port=5432 dbname='postgis' user='postgres'
> >> > password='postgres' schema='public' table='HumedadDeExtincion'"
> >> > PROCESSING "NODATA=0"
> >> > PROCESSING "SCALE=AUTO"
> >> > PROCESSING "SCALE_BUCKETS=201"
> >> > PROCESSING   "BANDS=1"
> >> > OFFSITE  71 74 65
> >> > CLASS
> >> > NAME "red"
> >> > EXPRESSION ([pixel] < 10)
> >> > COLOR 255 0 0
> >> > END
> >> > CLASS
> >> > NAME "green"
> >> > EXPRESSION ([pixel] >= 10 AND [pixel] < 15000 )
> >> > COLOR 0 255 0
> >> > END
> >> > CLASS
> >> > NAME "blue"
> >> > EXPRESSION ([pixel] >= 15000 )
> >> > COLOR 0 255 0
> >> > END
> >> >   END # MODIS raster layer ends here
> >> >
> >> >   # End of LAYER DEFINITIONS ---
> >> > END # All map files must come to an end just as all other things must
> >> > come
> >> > to...
> >> >
> >> > I have gdal 1.6 , postgis 1.5 and ms4w with mapserver 5.6.6
> >> > We cant see the tiff file on the browser, it only appears a white
> image.
> >> > We did try with the tif without the database connection an it works.
> >> > Could you help us?
> >> > Thank you
> >> >
> >> > ___
> >> > postgis-users mailing list
> >> > postgis-users@postgis.refractions.net
> >> > http://postgis.refractions.net/mailman/listinfo/postgis-users
> >> >
> >> >
> >>
> >>
> >>
> >> --
> >> Jorge Arévalo
> >> Internet & Mobilty Division, DEIMOS
> >> jorge.arev...@deimos-space.com
> >> http://es.linkedin.com/in/jorgearevalo80
> >> http://mobility.grupodeimos.com/
> >> http://gis4free.wordpress.com
> >> http://geohash.org/ezjqgrgzz0g
> >> ___
> >> postgis-users mailing list
> >> postgis-users@postgis.refractions.net
> >> http

Re: [postgis-users] OLYHEDRALSURFACE WKT format and related tools?

2011-06-02 Thread Paragon Corporation
Stefan,


Hi,

> We're experimenting with terrestrial surveying data about buildings in
> 3D whereas there are mainly facades and the roof (but mostly no
> floor).
> Now I'm looking for a format to store the output which consist of 3D
> planes, possibly interrelated.
> So far we are visualizing the work using VRML (.wrl) format and viewers.

>  Knowing PostGIS 2D quite well I thought that the WKT format of
> POLYHEDRALSURFACE could be a better solution.
> I somewhere found that there is a ST_AsX3D(geom. precision) which
> could output a VRML-like visualization format.
Yap that is the reason we created an ST_As3D function.  We are working on a
project
That utilizes X3D rendering.  To be honest though the PostGIS geometry stuff
is more on our second phase and the 
ST_As3D functions are there to make our second phase a smooth ride.  That
said most of our
X3D is really 3D points, rotation angles,



> What do you think about chosing the POLYHEDRALSURFACE WKT format?
You mean storing as Geometry write but passing in POLYHEDRALSURFACE wkt?

Depending on what you are doing POLYHEDRALSURFACE or TIN would probably be
your best bet.
Sounds like POLYHEDRAL would be better if you don't really care about
landscape.



> Are thee tools/fragments to insert and visualize POLYHEDRALSURFACE
> data out of PostGIS?
You can insert WKT POLYHEDRALSURFACE in PostGIS 2.0.

Thanks,
Regina
http://www.postgis.us


___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


[postgis-users] I could not find this function like

2011-06-02 Thread Nuri BURHAN
Hello.

I like postgis and spent lots time with postgis.

I haven't find a solition for my problem which is ;*how long does it take
 the busstop to the bus' GPS point?*

*result_linesting_geom=function (linestring_geom,point1_geom,point2_geom)*
*
*
***linestring_geom => bus path*
*point 1 => bus stop coordinat*
*point 2 => bus's GPS point coordinat*
*result_linesting_geom = > it is on **linestring_geom but between shortest
ponint 1 on **linestring_geom  and shortest point2  on **linestring_geom  *
*
*
*Any way thank you for your help.*
*
*
*
*--
M. Nuri BURHAN
0364-2250810-1330
Çorum Municipality GIS department /TURKEY
<>___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


Re: [postgis-users] Mapserver connection to Postgis Raster

2011-06-02 Thread Jorge Arévalo
On Thu, Jun 2, 2011 at 3:25 PM, Virginia Maffei  wrote:
> Thank you for your quick response!
> I have another question: can i install postgis 2.0 in windows? where can I
> download it?
>
>
> Virginia
>

Yes, you can. Follow this post's instructions:
http://gis4free.wordpress.com/2011/03/10/how-to-install-and-configure-postgis-raster-on-windows/

Best regards,
Jorge


>
> 2011/6/2 Jorge Arévalo 
>>
>> Hi,
>>
>> The mode=2 parameter is only valid with the last version of GDAL
>> (1.8.0). So, as Regina said, you need that version to make it work
>> properly. More accurately:
>>
>> - With a GDAL version down to 1.7.1, you can't make it work in any
>> way. No driver.
>>
>> - With a GDAL version between 1.7.1 and 1.7.3, both included, you can
>> use the old version of the driver, thought to work with the old
>> wktraster extension, now abandoned. And it was buggy. Not recommended.
>>  Neither GDAL 1.7.x nor wktraster.
>>
>> - With GDAL version up to 1.8.0, you can use the last version of GDAL
>> PostGIS Raster driver, and you'll need PostGIS 2.0, that includes
>> PostGIS Raster extension. Additionally, as Regina said, those days
>> we're working on the driver, and all the improvements will be included
>> in GDAL 1.8.x
>>
>> So, summarizing: You need PostGIS 2.0 plus GDAL 1.8.0 to make it work.
>>
>> Further information on the driver:
>> http://trac.osgeo.org/gdal/wiki/frmts_wtkraster.html
>>
>> Best regards,
>> Jorge
>>
>> On Thu, Jun 2, 2011 at 6:53 AM, Paragon Corporation  wrote:
>> > Virginia,
>> >
>> > I think you are missing a mode='2'  in your connection.  That was a new
>> > requirement that was added for GDAL 1.8+
>> >
>> > Try putting that in.  I think the speed on the loading still needs quite
>> > a
>> > bit of work though last I tried.  The speed issues will hopefully be
>> > resolved before 2.0 release.
>> >
>> > Thanks,
>> > Regina
>> > http://www.postgis.us
>> >
>> >
>> > 
>> > From: postgis-users-boun...@postgis.refractions.net
>> > [mailto:postgis-users-boun...@postgis.refractions.net] On Behalf Of
>> > Virginia
>> > Maffei
>> > Sent: Wednesday, June 01, 2011 8:00 PM
>> > To: postgis-users@postgis.refractions.net
>> > Subject: [postgis-users] Mapserver connection to Postgis Raster
>> >
>> > Hi, i'm new at this and i'm trying to connect to postgis raster in the
>> > mapfile.
>> > I loaded a tif file into postgis raster database with the
>> > raster2pgsql.py
>> > script. It created a table with 2 fields: rid and rast.
>> > In the mapfile i added the connection like it specifies in the postgis
>> > raster FAQ but it doesn't displays anything.
>> > This is my mapfile:
>> > MAP
>> >   IMAGETYPE      PNG24
>> >   EXTENT         366582.2901411663 6127927.100382689 857582.2901411663
>> > 6670927.100382689
>> >   SIZE           491 543
>> >   SHAPEPATH      "../data"
>> >   LAYER # MODIS raster layer begins here
>> >     NAME         modis
>> > TYPE         RASTER
>> > STATUS       ON
>> > DATA "PG:host=localhost port=5432 dbname='postgis' user='postgres'
>> > password='postgres' schema='public' table='HumedadDeExtincion'"
>> >     PROCESSING "NODATA=0"
>> > PROCESSING "SCALE=AUTO"
>> > PROCESSING "SCALE_BUCKETS=201"
>> >     PROCESSING   "BANDS=1"
>> >     OFFSITE      71 74 65
>> > CLASS
>> > NAME "red"
>> > EXPRESSION ([pixel] < 10)
>> > COLOR 255 0 0
>> > END
>> > CLASS
>> > NAME "green"
>> > EXPRESSION ([pixel] >= 10 AND [pixel] < 15000 )
>> > COLOR 0 255 0
>> > END
>> > CLASS
>> > NAME "blue"
>> > EXPRESSION ([pixel] >= 15000 )
>> > COLOR 0 255 0
>> > END
>> >   END # MODIS raster layer ends here
>> >
>> >   # End of LAYER DEFINITIONS ---
>> > END # All map files must come to an end just as all other things must
>> > come
>> > to...
>> >
>> > I have gdal 1.6 , postgis 1.5 and ms4w with mapserver 5.6.6
>> > We cant see the tiff file on the browser, it only appears a white image.
>> > We did try with the tif without the database connection an it works.
>> > Could you help us?
>> > Thank you
>> >
>> > ___
>> > postgis-users mailing list
>> > postgis-users@postgis.refractions.net
>> > http://postgis.refractions.net/mailman/listinfo/postgis-users
>> >
>> >
>>
>>
>>
>> --
>> Jorge Arévalo
>> Internet & Mobilty Division, DEIMOS
>> jorge.arev...@deimos-space.com
>> http://es.linkedin.com/in/jorgearevalo80
>> http://mobility.grupodeimos.com/
>> http://gis4free.wordpress.com
>> http://geohash.org/ezjqgrgzz0g
>> ___
>> postgis-users mailing list
>> postgis-users@postgis.refractions.net
>> http://postgis.refractions.net/mailman/listinfo/postgis-users
>
>
> ___
> postgis-users mailing list
> postgis-users@postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
>
>



-- 
Jorge Arévalo
Internet & Mobilty Division, DEIMOS
jorge.arev...@deimos-space.com
http://es.linkedin.com/in/jorgearevalo80

Re: [postgis-users] Mapserver connection to Postgis Raster

2011-06-02 Thread Virginia Maffei
Thank you for your quick response!

I have another question: can i install postgis 2.0 in windows? where can I
download it?



Virginia


2011/6/2 Jorge Arévalo 

> Hi,
>
> The mode=2 parameter is only valid with the last version of GDAL
> (1.8.0). So, as Regina said, you need that version to make it work
> properly. More accurately:
>
> - With a GDAL version down to 1.7.1, you can't make it work in any
> way. No driver.
>
> - With a GDAL version between 1.7.1 and 1.7.3, both included, you can
> use the old version of the driver, thought to work with the old
> wktraster extension, now abandoned. And it was buggy. Not recommended.
>  Neither GDAL 1.7.x nor wktraster.
>
> - With GDAL version up to 1.8.0, you can use the last version of GDAL
> PostGIS Raster driver, and you'll need PostGIS 2.0, that includes
> PostGIS Raster extension. Additionally, as Regina said, those days
> we're working on the driver, and all the improvements will be included
> in GDAL 1.8.x
>
> So, summarizing: You need PostGIS 2.0 plus GDAL 1.8.0 to make it work.
>
> Further information on the driver:
> http://trac.osgeo.org/gdal/wiki/frmts_wtkraster.html
>
> Best regards,
> Jorge
>
> On Thu, Jun 2, 2011 at 6:53 AM, Paragon Corporation  wrote:
> > Virginia,
> >
> > I think you are missing a mode='2'  in your connection.  That was a new
> > requirement that was added for GDAL 1.8+
> >
> > Try putting that in.  I think the speed on the loading still needs quite
> a
> > bit of work though last I tried.  The speed issues will hopefully be
> > resolved before 2.0 release.
> >
> > Thanks,
> > Regina
> > http://www.postgis.us
> >
> >
> > 
> > From: postgis-users-boun...@postgis.refractions.net
> > [mailto:postgis-users-boun...@postgis.refractions.net] On Behalf Of
> Virginia
> > Maffei
> > Sent: Wednesday, June 01, 2011 8:00 PM
> > To: postgis-users@postgis.refractions.net
> > Subject: [postgis-users] Mapserver connection to Postgis Raster
> >
> > Hi, i'm new at this and i'm trying to connect to postgis raster in the
> > mapfile.
> > I loaded a tif file into postgis raster database with the raster2pgsql.py
> > script. It created a table with 2 fields: rid and rast.
> > In the mapfile i added the connection like it specifies in the postgis
> > raster FAQ but it doesn't displays anything.
> > This is my mapfile:
> > MAP
> >   IMAGETYPE  PNG24
> >   EXTENT 366582.2901411663 6127927.100382689 857582.2901411663
> > 6670927.100382689
> >   SIZE   491 543
> >   SHAPEPATH  "../data"
> >   LAYER # MODIS raster layer begins here
> > NAME modis
> > TYPE RASTER
> > STATUS   ON
> > DATA "PG:host=localhost port=5432 dbname='postgis' user='postgres'
> > password='postgres' schema='public' table='HumedadDeExtincion'"
> > PROCESSING "NODATA=0"
> > PROCESSING "SCALE=AUTO"
> > PROCESSING "SCALE_BUCKETS=201"
> > PROCESSING   "BANDS=1"
> > OFFSITE  71 74 65
> > CLASS
> > NAME "red"
> > EXPRESSION ([pixel] < 10)
> > COLOR 255 0 0
> > END
> > CLASS
> > NAME "green"
> > EXPRESSION ([pixel] >= 10 AND [pixel] < 15000 )
> > COLOR 0 255 0
> > END
> > CLASS
> > NAME "blue"
> > EXPRESSION ([pixel] >= 15000 )
> > COLOR 0 255 0
> > END
> >   END # MODIS raster layer ends here
> >
> >   # End of LAYER DEFINITIONS ---
> > END # All map files must come to an end just as all other things must
> come
> > to...
> >
> > I have gdal 1.6 , postgis 1.5 and ms4w with mapserver 5.6.6
> > We cant see the tiff file on the browser, it only appears a white image.
> > We did try with the tif without the database connection an it works.
> > Could you help us?
> > Thank you
> >
> > ___
> > postgis-users mailing list
> > postgis-users@postgis.refractions.net
> > http://postgis.refractions.net/mailman/listinfo/postgis-users
> >
> >
>
>
>
> --
> Jorge Arévalo
> Internet & Mobilty Division, DEIMOS
> jorge.arev...@deimos-space.com
> http://es.linkedin.com/in/jorgearevalo80
> http://mobility.grupodeimos.com/
> http://gis4free.wordpress.com
> http://geohash.org/ezjqgrgzz0g
> ___
> postgis-users mailing list
> postgis-users@postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
>
___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


[postgis-users] POLYHEDRALSURFACE WKT format and related tools?

2011-06-02 Thread Stefan Keller
Hi,

We're experimenting with terrestrial surveying data about buildings in
3D whereas there are mainly facades and the roof (but mostly no
floor).
Now I'm looking for a format to store the output which consist of 3D
planes, possibly interrelated.
So far we are visualizing the work using VRML (.wrl) format and viewers.

Knowing PostGIS 2D quite well I thought that the WKT format of
POLYHEDRALSURFACE could be a better solution.
I somewhere found that there is a ST_AsX3D(geom. precision) which
could output a VRML-like visualization format.

What do you think about chosing the POLYHEDRALSURFACE WKT format?
Are thee tools/fragments to insert and visualize POLYHEDRALSURFACE
data out of PostGIS?

Yours, Stefan
___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


Re: [postgis-users] Mapserver connection to Postgis Raster

2011-06-02 Thread Jorge Arévalo
Hi,

The mode=2 parameter is only valid with the last version of GDAL
(1.8.0). So, as Regina said, you need that version to make it work
properly. More accurately:

- With a GDAL version down to 1.7.1, you can't make it work in any
way. No driver.

- With a GDAL version between 1.7.1 and 1.7.3, both included, you can
use the old version of the driver, thought to work with the old
wktraster extension, now abandoned. And it was buggy. Not recommended.
 Neither GDAL 1.7.x nor wktraster.

- With GDAL version up to 1.8.0, you can use the last version of GDAL
PostGIS Raster driver, and you'll need PostGIS 2.0, that includes
PostGIS Raster extension. Additionally, as Regina said, those days
we're working on the driver, and all the improvements will be included
in GDAL 1.8.x

So, summarizing: You need PostGIS 2.0 plus GDAL 1.8.0 to make it work.

Further information on the driver:
http://trac.osgeo.org/gdal/wiki/frmts_wtkraster.html

Best regards,
Jorge

On Thu, Jun 2, 2011 at 6:53 AM, Paragon Corporation  wrote:
> Virginia,
>
> I think you are missing a mode='2'  in your connection.  That was a new
> requirement that was added for GDAL 1.8+
>
> Try putting that in.  I think the speed on the loading still needs quite a
> bit of work though last I tried.  The speed issues will hopefully be
> resolved before 2.0 release.
>
> Thanks,
> Regina
> http://www.postgis.us
>
>
> 
> From: postgis-users-boun...@postgis.refractions.net
> [mailto:postgis-users-boun...@postgis.refractions.net] On Behalf Of Virginia
> Maffei
> Sent: Wednesday, June 01, 2011 8:00 PM
> To: postgis-users@postgis.refractions.net
> Subject: [postgis-users] Mapserver connection to Postgis Raster
>
> Hi, i'm new at this and i'm trying to connect to postgis raster in the
> mapfile.
> I loaded a tif file into postgis raster database with the raster2pgsql.py
> script. It created a table with 2 fields: rid and rast.
> In the mapfile i added the connection like it specifies in the postgis
> raster FAQ but it doesn't displays anything.
> This is my mapfile:
> MAP
>   IMAGETYPE      PNG24
>   EXTENT         366582.2901411663 6127927.100382689 857582.2901411663
> 6670927.100382689
>   SIZE           491 543
>   SHAPEPATH      "../data"
>   LAYER # MODIS raster layer begins here
>     NAME         modis
> TYPE         RASTER
> STATUS       ON
> DATA "PG:host=localhost port=5432 dbname='postgis' user='postgres'
> password='postgres' schema='public' table='HumedadDeExtincion'"
>     PROCESSING "NODATA=0"
> PROCESSING "SCALE=AUTO"
> PROCESSING "SCALE_BUCKETS=201"
>     PROCESSING   "BANDS=1"
>     OFFSITE      71 74 65
> CLASS
> NAME "red"
> EXPRESSION ([pixel] < 10)
> COLOR 255 0 0
> END
> CLASS
> NAME "green"
> EXPRESSION ([pixel] >= 10 AND [pixel] < 15000 )
> COLOR 0 255 0
> END
> CLASS
> NAME "blue"
> EXPRESSION ([pixel] >= 15000 )
> COLOR 0 255 0
> END
>   END # MODIS raster layer ends here
>
>   # End of LAYER DEFINITIONS ---
> END # All map files must come to an end just as all other things must come
> to...
>
> I have gdal 1.6 , postgis 1.5 and ms4w with mapserver 5.6.6
> We cant see the tiff file on the browser, it only appears a white image.
> We did try with the tif without the database connection an it works.
> Could you help us?
> Thank you
>
> ___
> postgis-users mailing list
> postgis-users@postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
>
>



-- 
Jorge Arévalo
Internet & Mobilty Division, DEIMOS
jorge.arev...@deimos-space.com
http://es.linkedin.com/in/jorgearevalo80
http://mobility.grupodeimos.com/
http://gis4free.wordpress.com
http://geohash.org/ezjqgrgzz0g
___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users