Repository navigation
Conversation
07cc379 to
e68b0d6
Compare
📝 WalkthroughWalkthroughA new 3D alpha wrapping feature has been introduced, including its C implementation, SQL interface, documentation, test cases, and sample WKT data. The function Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant SQL
participant PostGIS
participant SFCGAL
User->>SQL: CALL CG_3DAlphaWrapping(geom, alpha, offset)
SQL->>PostGIS: Invoke sfcgal_alphawrapping_3d()
PostGIS->>SFCGAL: Convert geometry, call alpha_wrapping_3d()
SFCGAL-->>PostGIS: Return wrapped geometry
PostGIS-->>SQL: Return result geometry
SQL-->>User: Output wrapped geometry
Poem
📜 Recent review detailsConfiguration used: CodeRabbit UI ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (9)
✅ Files skipped from review due to trivial changes (2)
🚧 Files skipped from review as they are similar to previous changes (6)
⏰ Context from checks skipped due to timeout of 90000ms (12)
🔇 Additional comments (1)
✨ Finishing Touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Caution
Inline review comments failed to post. This is likely due to GitHub's limits when posting large numbers of comments. If you are seeing this consistently it is likely a permissions issue. Please check "Moderation" -> "Code review limits" under your organization settings.
Actionable comments posted: 1
🧹 Nitpick comments (3)
sfcgal/sfcgal.sql.in (1)
599-599: Consider adding parameter validation or documentation commentWhile the function signature itself looks good, it might be helpful to add inline SQL documentation about what the
relative_alphaandrelative_offsetparameters represent, or add parameter validation to ensure they fall within appropriate ranges.doc/reference_sfcgal.xml (2)
3588-3593: Fix duplicated word
The sentence “It can can have values from 0 to infinity.” has a duplicated “can”.Replace with:
<para> The <varname>relative_alpha</varname> parameter controls which features will appear in the output. It can have values from 0 to infinity. Smaller <varname>relative_alpha</varname> values result in simpler outputs, but they are less accurate representations of the original input. </para>
3588-3598: Use<xref>for internal references
Local cross-references should use<xref>instead of<link>withlinkendto be consistent with other entries.Modify:
- <para>Computes the <link xlink:href="https://doc.cgal.org/latest/Alpha_wrap_3/index.html">3D Alpha Wrapping</link> of the points in a geometry. An alpha wrapping is a watertight and orientable surface mesh that strictly encloses the input. It can be seen as an extension or refinement of an <link linkend="CG_AlphaShape">alpha-shape</link>.</para> + <para>Computes the <link xlink:href="https://doc.cgal.org/latest/Alpha_wrap_3/index.html">3D Alpha Wrapping</link> of the points in a geometry. An alpha wrapping is a watertight and orientable surface mesh that strictly encloses the input. It can be seen as an extension or refinement of an <xref linkend="CG_AlphaShape">alpha-shape</xref>.</para>
🛑 Comments failed to post (1)
doc/reference_sfcgal.xml (1)
3579-3583: 🛠️ Refactor suggestion
Use floating-point parameters and mark offset as optional
Therelative_alphaandrelative_offsetparameters should allow fractional values (not just integers), matching other CGAL-based functions (e.g.CG_AlphaShape). Sincerelative_offset = 0triggers auto-computation, mark it as optional with a default.Proposed diff:
- <paramdef><type>integer</type> <parameter>relative_alpha</parameter></paramdef> - <paramdef><type>integer</type> <parameter>relative_offset</parameter></paramdef> + <paramdef><type>float</type> <parameter>relative_alpha</parameter></paramdef> + <paramdef choice="opt"><type>float</type> <parameter>relative_offset = 0</parameter></paramdef>🤖 Prompt for AI Agents (early access)
In doc/reference_sfcgal.xml around lines 3579 to 3583, update the parameter types for relative_alpha and relative_offset from integer to floating-point to allow fractional values. Additionally, mark relative_offset as optional by specifying a default value of 0 to indicate auto-computation, aligning with other CGAL-based functions.
This introduces `CG_3DAlphaWrapping`, a new function for SFCGAL backend based on `sfcgal_geometry_alpha_wrapping_3d`. The documentation and unit tests are updated accordingly. SFCGAL 2.1 or above is needed.
e68b0d6 to
2cd9919
Compare
|
Merged |
This introduces
CG_3DAlphaWrapping, a new function for SFCGALbackend based on
sfcgal_geometry_alpha_wrapping_3d.The documentation and unit tests are updated accordingly.
SFCGAL 2.1 or above is needed.
cc @lbartoletti