Hi Tom,
You can copy the triangulated from my message Box and ST_Translate /
ST_Scale it using ST_{X,Y,Z}{Min,Max} of your box. Of course, more
preferable way would be to use SFCGAL extension, as it's part of PostGIS :)
вт, 24 июл. 2018 г. в 16:09, Tom Kazimiers <[email protected]>:
> That's nice indeed, thanks for the update!
>
> I suppose there is no way to convert a Box3D to a TIN geometry without
> SFCGAL in a similar fashion? Specifiying vertices and triangles using
> ST_{X,Y,Z}{Min,Max} is no problem, it only gets pretty verbose and we can't
> add SFCGAL to our dependencies at the moment.
>
> Cheers,
> Tom
>
> On July 24, 2018 10:20:09 AM UTC, Felix Kunde <[email protected]> wrote:
>
>> I was hoping for a news like this. Great. Thanks!
>>
>>
>> Gesendet: Montag, 23. Juli 2018 um 20:17 Uhr
>> Von: "Darafei \"Komяpa\" Praliaskouski" <[email protected]>
>> An: "PostGIS Users Discussion" <[email protected]>
>> Betreff: Re: [postgis-users] Convert Box3D to TIN geometries
>>
>> Hi Felix,
>>
>> This was fixed in PostGIS 2.5.
>>
>> There your query ends up with geometry like this:
>>
>> GEOMETRYCOLLECTION Z (TIN Z (((0 0 0,0 1 0,1 1 0,0 0 0)),((1 0 0,0 0 0,1 1
>> 0,1 0 0)),((0 1 1,1 0 1,1 1 1,0 1 1)),((0 1 1,0 0 1,1 0 1,0 1 1)),((0 0 0,0
>> 0 1,0 1 1,0 0 0)),((0 1 0,0 0 0,0 1 1,0 1 0)),((1 0 1,1 1 0,1 1 1,1 0
>> 1)),((1 0 1,1 0 0,1 1 0,1 0 1)),((0 0 1,1 0 0,1 0 1,0 0 1)),(
>> (0 0 1,0 0 0,1 0 0,0 0 1)),((0 1 0,0 1 1,1 1 1,0 1 0)),((1 1 0,0 1 0,1 1 1,1
>> 1 0))))
>>
>> ср, 18 июл. 2018 г. в 11:21, Felix Kunde
>> <[email protected][mailto:[email protected]]>:Hi,
>> thought that's easy to do with the postgis_sfcgal extension, but no:
>> SELECT ST_Tesselate('BOX3D(0 0 0,1 1 1)'::box3d::geometry));
>>
>> ERROR: Solid is invalid : PolyhedralSurface (shell) 0 is invalid: not
>> connected : SOLID((((0/1 0/1 0/1,0/1 1/1 0/1,1/1 1/1 0/1,1/1 0/1 0/1,0/1 0/1
>> 0/1)),((0/1 0/1 1/1,0/1 1/1 1/1,1/1 1/1 1/1,1/1 0/1 1/1,0/1 0/1 1/1)),((0/1
>> 0/1 0/1,0/1 1/1 0/1,0/1 1/1 1/1,0/1 0/1
>> SQL Status:XX000
>>
>> The polygons are not in the right order :-/
>> Also tried dumping and delaunay triangulation but yet not solution. Anyone
>> else?
>>
>> Cheers,
>> Felix
>>
>>
>>
>> Gesendet: Dienstag, 17. Juli 2018 um 20:04 Uhr
>> Von: "Tom Kazimiers" <[email protected][mailto:[email protected]]>
>> An: [email protected][mailto:[email protected]]
>> Betreff: [postgis-users] Convert Box3D to TIN geometries
>> Hi all,
>>
>> I need to convert a lot of Box3D geometries to TIN geometries. Is there a
>> way in PostGIS to do this without specifiying each triangle and vertex for
>> the new TINs explicitly? Idealy, I would just be able to issue a simple
>> update statement without needing to think about vertex order and triangle
>> order.
>>
>> Thanks,
>> Tom
>> ------------------------------
>>
>> postgis-users mailing list
>> [email protected][mailto:[email protected]]
>> https://lists.osgeo.org/mailman/listinfo/postgis-users
>> ------------------------------
>>
>> postgis-users mailing list
>> [email protected][mailto:[email protected]]
>> https://lists.osgeo.org/mailman/listinfo/postgis-users--
>>
>> Darafei Praliaskouski
>> Support me: http://patreon.com/komzpa[http://patreon.com/komzpa]
>> ------------------------------
>> postgis-users mailing list [email protected]
>> https://lists.osgeo.org/mailman/listinfo/postgis-users[https://lists.osgeo.org/mailman/listinfo/postgis-users]
>> ------------------------------
>>
>> postgis-users mailing list
>> [email protected]
>> https://lists.osgeo.org/mailman/listinfo/postgis-users
>>
>> _______________________________________________
> postgis-users mailing list
> [email protected]
> https://lists.osgeo.org/mailman/listinfo/postgis-users
--
Darafei Praliaskouski
Support me: http://patreon.com/komzpa
_______________________________________________
postgis-users mailing list
[email protected]
https://lists.osgeo.org/mailman/listinfo/postgis-users