Unexpected output from ST_AsX3D with PolyhedralSurfaceZ

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Unexpected output from ST_AsX3D with PolyhedralSurfaceZ

TomvanTilburg
Im trying to display some extruded buildings as X3D but noticed that the output with concave buildings (U shaped) creates a convex faceset on the top and bottom of the building. This doesn't seem right.

When I tesselate first, and therefore go fom polyhedralsurfacez to TIN the output is allright.
You can try with and without tesselate yourself:

SELECT ST_AsX3D(ST_Tesselate(ST_Extrude(ST_GeometryFromText('Polygon((0 0, 0 10, 30 10, 30 0, 20 0, 20 5, 10 5, 10 0, 0 0))'),0,0,10)))

For completeness:
<X3D>
<Scene>
        <Viewpoint orientation='0.2 0 0 0.8' position='-10 -10 100'/> 
        <Background skyColor='1 1 1'/> 
        <Shape>
<!--PUT YOUR OUTPUT HERE, TESSELATED VERSION ALREADY INCLUDES SHAPE -->
</Shape>
    </Scene>
</X3D>

Best, Tom

_______________________________________________
postgis-devel mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/postgis-devel
Reply | Threaded
Open this post in threaded view
|

conversion to the ST_ColorMap format

J.J. Green
Hi all,

I've added the PostGIS ST_ColorMap format to the list of
output formats supported by the cptutils package

   http://soliton.vm.bytemark.co.uk/pub/jjg/en/code/cptutils/
   http://soliton.vm.bytemark.co.uk/pub/jjg/en/code/cptutils/cptpg-1.html

so allowing conversion from GMT cpt, GIMP ggr, Photoshop grd
etc to the PostGIS format.  An online converter can be found at

   http://soliton.vm.bytemark.co.uk/pub/cptutils-online/select.html

please let me know of bugs, feature requests etc

Cheers

Jim
--
J.J. Green
http://soliton.vm.bytemark.co.uk/pub/jjg/en/
_______________________________________________
postgis-devel mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/postgis-devel
Reply | Threaded
Open this post in threaded view
|

Re: conversion to the ST_ColorMap format

Bborie Park-2
Nice!

On Mon, Jan 18, 2016 at 1:28 PM, J.J. Green <[hidden email]> wrote:
Hi all,

I've added the PostGIS ST_ColorMap format to the list of
output formats supported by the cptutils package

  http://soliton.vm.bytemark.co.uk/pub/jjg/en/code/cptutils/
  http://soliton.vm.bytemark.co.uk/pub/jjg/en/code/cptutils/cptpg-1.html

so allowing conversion from GMT cpt, GIMP ggr, Photoshop grd
etc to the PostGIS format.  An online converter can be found at

  http://soliton.vm.bytemark.co.uk/pub/cptutils-online/select.html

please let me know of bugs, feature requests etc

Cheers

Jim
--
J.J. Green
http://soliton.vm.bytemark.co.uk/pub/jjg/en/
_______________________________________________
postgis-devel mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/postgis-devel


_______________________________________________
postgis-devel mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/postgis-devel
Reply | Threaded
Open this post in threaded view
|

Re: Unexpected output from ST_AsX3D with PolyhedralSurfaceZ

Regina Obe
In reply to this post by TomvanTilburg

Tom,

 

Yah that looks wrong and I get the same bad rendering too and right rendering with the Tesellate.  Can you ticket this one and I'll take a look next chance I get.

 

http://postgis.net/support/

 

Thanks,

Regina

 

 

 

From: postgis-devel [mailto:[hidden email]] On Behalf Of Tom van Tilburg
Sent: Monday, January 18, 2016 11:25 AM
To: PostGIS Development Discussion <[hidden email]>
Subject: [postgis-devel] Unexpected output from ST_AsX3D with PolyhedralSurfaceZ

 

Im trying to display some extruded buildings as X3D but noticed that the output with concave buildings (U shaped) creates a convex faceset on the top and bottom of the building. This doesn't seem right.

 

When I tesselate first, and therefore go fom polyhedralsurfacez to TIN the output is allright.

You can try with and without tesselate yourself:

 

SELECT ST_AsX3D(ST_Tesselate(ST_Extrude(ST_GeometryFromText('Polygon((0 0, 0 10, 30 10, 30 0, 20 0, 20 5, 10 5, 10 0, 0 0))'),0,0,10)))

 

For completeness:

<X3D>

<Scene>

        <Viewpoint orientation='0.2 0 0 0.8' position='-10 -10 100'/> 

        <Background skyColor='1 1 1'/> 

        <Shape>

<!--PUT YOUR OUTPUT HERE, TESSELATED VERSION ALREADY INCLUDES SHAPE -->

</Shape>

    </Scene>

</X3D>

 

Best, Tom


_______________________________________________
postgis-devel mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/postgis-devel