Select to view content in your preferred language

triangulate | quadrangulate

277
2
05-21-2025 09:54 AM
romainjanil
Regular Contributor

It would be nice to have some smart geometric operations (obviously working on faces/meshes), offering different triangulation algos (anyone noticed that the triangulation of initial shapes is different than triangulation of generated shapes...?). And even why not a quadrangulate operation. It would help a lot to work with ngons or ribbon like features....

cheers

2 Comments
ThomasFuchs
Status changed to: Needs Clarification

Thank you @romainjanil for bringing up this topic. 

You want to have more control over the triangulation algorithm that is used for generating models. So far there are no plans to offer this. But, the upcoming release of CityEngine 2025.0 comes with many improvements for the boolean 3D operations, including better cleanup of the resulting shapes. This also affects the triangulation.

The triangulation of Initial Shapes for rendering in the CE viewport is not the same as the triangulation used for creating models. If there are differences, it's recommended to hide the Initial Shapes.

Can you please give more insights, why you need to apply a specific triangulation algorithm for generating Models?

romainjanil

Hi Thomas,

most obvious use case for a quadrangulate operation would be a to get a simple way to subdivide in cga concave ribbon like area features, generally output from any gis software buffer function or results of setbacks too. Most of the time the convexify operation gives irrelevant results unfortunately.
It's possible somehow to approximate a "quadify" function with iterative setbacks or splitAndSetbackPerimeter modulo edge indices etc but it's cumbersome and most of the time introduce new vertices which are not necessarily wanted...

Control of triangulation was initially a request to handle concave free form initial shapes with Z, mostly representing organic parts of terrain or artificial ground features: triangulation of initial shapes always looked better and more natural than the result after cga generation . Now starting with 2024.1 and 2025.0 and the inline function it's possible to subdivide  those shapes inline on multiple axis, and cleanup, merge vertices, smooth normals afterwards the subdivided grid, so this seems not so important now.
I'll post an example image of what I have in mind regarding this quadify feature.