SGflip

by Tim C. Lueth, SG-Lib Toolbox: SolidGeometry 5.6 - Surfaces
Introduced first in SolidGeometry 5.0, Creation date: 2020-09-05, Last change: 2025-09-14

returns a SG with inverted facets - same fnct as 2014-11-30

Description

similar to FLswap, but for solids

See Also: , TflipR

Example Illustration

 missing image of SGflip(SG)

Syntax

SG=SGflip(SG)

Input Parameter

SG: Solid geometry

Output Parameter

SG: Solid geometry with inverted facets

Examples


SGmeshlab(SGtransT(SGflip(SGbox),TflipR(eye(4))))




Copyright 2020-2025 Tim C. Lueth. All rights reserved. The code is the property of Tim C. Lueth and may not be redistributed or modified without explicit written permission. This software may be used free of charge for academic research and teaching purposes only. Commercial use, redistribution, modification, or reverse engineering is strictly prohibited. Access to source code is restricted and granted only under specific agreements. For licensing inquiries or commercial use, please contact: Tim C. Lueth

Algorithm (Workflow)

This function, SGflip, is designed to invert the facets of a solid geometry object. It is part of the SolidGeometry library and is similar to the FLswap function but specifically for solids.

Input Parameters

Output Results

Algorithm Steps

  1. The function begins by calling SGofSG(SG). This step ensures that the input is a valid solid geometry object. It likely performs checks or conversions to standardize the input.
  2. Next, the function inverts the facets of the solid geometry by calling FLswap(SG.FL). This operation swaps the order of vertices in each facet, effectively flipping the facet's orientation.
  3. The modified solid geometry object, with inverted facets, is then returned as the output.

Example Usage

An example of how this function might be used is given by the line:

SGmeshlab(SGtransT(SGflip(SGbox),TflipR(eye(4))))

In this example, a box geometry is flipped, transformed, and then visualized using a function like SGmeshlab.

Algorithm explaination created using ChatGPT on 2025-08-18 22:08. (Please note: No guarantee for the correctness of this explanation)

Last html export of this page out of FM database by TL: 2025-09-21