Metamation Developer Notes

  • Developer Notes
  • Resource Map
  • Tools
    • Code Formatting
    • Configuring Git
    • Assignments
    • Testing with Windows Sandbox
    • Single Binary Applications
    • Self-Updating Applications
  • Flux Workflow
    • Flux Workflow
    • Flux Development Style Guide
    • Release notes for Flux
    • SonarCloud analysis for Flux
    • Build a Flux SDK Program
    • Shipping Flux
    • Flux.Test
      • BasicBendAuto Test
      • LaserAuto.cs Detailed Documentation
      • Laserexample:Test1
  • Technical Notes
    • File formats
      • .FX File Format
      • Au(Gold) streams
      • .GEO File Format
      • .LST File Format
      • .LST file - technology
      • .BNC File Format
      • .WAD Files: Flux Resource Packages
      • .Curl Files: ASCII config information
    • Folders App
      • Data\Bendtools
      • Data\Machines
    • FluxCode
      • Welcome & Repo Map
      • Architecture & System Context
      • Subsystem *Bend* (Press Brake)
      • Subsystem *BCell* (Bend Cell Automation)
      • API Maps
      • Data Model Catalog
      • Design Patterns -- A Reader's Guide
      • Tests and Golden Paths
      • Guided Code Tours
      • CAM Glossary with Code Mapping
      • Assignments
      • Flux Onboarding Handbook
    • Data flow
      • Part
        • Part.Dwg
        • Part.Load
        • Part.Load to Part.Dwg
      • BendTech.cs
      • Bend Technology
      • Laser Cutting Technology
    • LTS (Long term support mechanism)
    • Machine ID Scheme
  • FluxTester
    • Commands and Scripts
    • Command Cookbook
    • Script Commands
    • BendTooling.cs Test Inventory
    • LaserTooling.cs Test Steps
    • Fluxtester Recipe Book
    • Nesting.cs Overview
    • Nesting.cs Recipe Book
    • Job.cs Overview
    • Job.cs Recipe Book
  • Software license
  • 3d party software
    • Python
  • Documentation
    • Bento documentation
      • Structure of a Bento page
      • Attributes
    • Software
      • Software Requirement
      • Installation
      • Git workflow for documentation contributors
    • Quick start guide
    • Workflow
      • Roles and responsibilities
      • Analyze
      • Edit
      • Proofread
      • Pre-Publish
      • Publish
      • Release cycle
      • Information required for Documentation Team
      • Checklist for Documenters
    • Styleguide
    • Flavoring
    • Translation
      • Ordering translation for a new document
    • Citations
    • Annotation
Technical Notes
/
Data flow
/
Part

Part

Everything in Flux revolves around a single central concept: the Part. A Part is the digital twin of a physical sheet-metal component — it holds the 3D geometry, the 2D flat drawing, and all the manufacturing instructions needed to produce that component on real machines.

Every other major object either belongs to a Part or organises Parts for production.

Part                       ← one sheet-metal component
 ├── Model3                ← its 3D folded shape
 ├── Drawing2              ← its unfolded flat shape
 ├── BendTech              ← instructions for a press-brake
 ├── FoldTech              ← instructions for a panel-bending machine
 ├── FlatTech (CutTech)   ← instructions for laser / punch cutting
 ├── Layout                ← single-part arrangement on one sheet
 └── TrimJob / TrimTech   ← instructions for 5-axis trimming

At a higher level, many Parts can be grouped together for production:

NestJob                    ← one production batch
 ├── NestPart[]            ← which parts, how many
 ├── NestSheet[]           ← which raw-material sheets are available
 └── NestPattern[]         ← calculated sheet arrangements (results)

The Part

Namespace: Flux.Core — File: Core/Part/Part.cs

Part is the root domain object. It is a container that links together every representation of the same physical component.

Property Type Meaning

Info

PartInfo

Name, material, thickness, and other metadata

Model

Model3

The 3D folded shape of the part

Dwg

Drawing2

The 2D unfolded (flat) drawing

BendTech

BendTech

Press-brake processing data

FoldTech

FoldTech

Panel-bender processing data

CutTech

FlatTech

Laser / punch cutting data

Layout

Layout

Quick single-part sheet arrangement

TrimJob

TrimJob

5-axis trim / pipe-cutting job

TrimTech

TrimTech

5-axis CAM processing data

Flags

EFlags

Bitfield of part-state switches

Active Part

Part.Current is the static property that holds whichever Part the user is currently working on. This is the application’s global selection state — think of it as "the open document".

Part active = Part.Current;   // the part currently open in the editor

3D Geometry — Model3

File: Core/Model/Model3.cs

Model3 represents the part in its folded, three-dimensional state — what you would hold in your hands.

It stores a tree of connected planar faces and bends:

Property Type Meaning

Entities

AList<Entity3>

All geometric elements (faces, bends, meshes)

Baseplane

E3Plane

The reference face — root of the geometry tree

Flexes

IEnumerable<E3Flex>

All bend lines in the model

FlatMesh

CMesh

Triangle mesh in the fully flat state

FoldedMesh

CMesh

Triangle mesh in the folded state

Category

ECategory

Classification (sheet metal, laser, assembly …)

MassProps

MassProps

Centre of gravity, volume, weight

Entity Hierarchy

Entity3 is the base class for all geometric elements inside a model:

Entity3                 ← abstract base (has a name, transform)
 ├── E3Thick            ← has a material thickness
 │    ├── E3Plane       ← a flat face (most common element)
 │    └── E3Flex        ← a bend connecting two faces
 ├── E3Surface          ← imported freeform surface
 ├── E3Insert           ← assembly sub-component
 └── E3Mesh             ← arbitrary triangle mesh

E3Plane objects are the faces of the part. E3Flex objects are the bends that connect those faces. Together they form a directed acyclic graph (DAG) rooted at Baseplane:

Baseplane (E3Plane)
 └── [via E3Flex "bend A"]
      └── Side face (E3Plane)
           └── [via E3Flex "bend B"]
                └── Flange (E3Plane)

Every E3Thick has Windward (parent) and Leeward (child) pointers to navigate this tree.

2D Flat Drawing — Drawing2

File: Core/Model/Drawing2.cs

Drawing2 is the unfolded, two-dimensional representation — the flat blank that will be cut from a sheet.

Property Type Meaning

Entities

Entity2[]

All 2D elements

Plines

E2Pline[]

Contours (outer edge, holes, internal features)

Bendlines

E2Bendline[]

Lines where the part will be bent

The most important element is E2Pline — a 2D polyline that describes a contour. The outer boundary of the flat part is one E2Pline; every hole or cutout is another.

Geometry Primitives

These types live in Flux.Base and are used throughout the entire codebase.

Points and Vectors

Type Description

Point2

2D position (x, y) as double

Point3

3D position (x, y, z) as double

Point2f

2D position as float (used in rendering)

Point3f

3D position as float (used in rendering)

Vector2

2D direction with length

Vector3

3D direction; supports dot product, cross product, normalisation

Transforms

Type Description

Matrix2

2D affine transform — rotation, translation, scaling

Matrix3

3D affine transform

CoordSystem

An oriented coordinate frame: one origin point and three perpendicular axes

Polylines — Pline

File: Base/Pline/Pline.cs

Pline is one of the most frequently used types in the codebase. It represents a 2D contour made of straight lines and arcs.

Property Type Meaning

Segs

Segment[]

The individual line or arc segments

IsClosed

bool

Whether the contour is closed (a loop)

IsOuter

bool

Whether this is an outer boundary (vs. a hole)

Bound

Bound2

Axis-aligned bounding box

Area

double

Enclosed area

Think of Pline as the 2D equivalent of a shape — it can be the outline of the whole part, a rectangular hole, or an arc slot.

Press-Brake Data — BendTech

File: Core/Bend/BendTech.cs

BendTech stores everything needed to produce the part’s bends on a press-brake machine.

Property Type Meaning

BMachine

BendMachine

The target machine

Ops

AList<BendOp>

Ordered list of bend operations

Cell

BCellTech

Robotic cell configuration (optional)

Robotic

bool

Whether a robot handles the part

Bend Operations — BendOp

Each BendOp is one individual bend, in sequence:

Property Type Meaning

Flex

E3Flex

The model element being bent

Kind

EBendKind

What kind of bend (air bend, hem, coin …)

Angle

double

Target bend angle in degrees

Handling

EHandlingFlip

How the operator re-orients the part after this step

Tools

BendToolSet

Punch and die selected for this step

EBendKind — Bend Types

enum EBendKind {
    AirBend,        // most common: punch doesn't reach die bottom
    Coining,        // high-pressure: punch presses all the way
    ClosedHem,      // folds flat onto itself
    OpenHem,        // folds back but leaves a gap
    BumpBend,       // multiple small hits to form a curve
    FormBend,       // uses a special forming tool
    // … and several pre-bend variants
}

EHandlingFlip — Part Re-orientation

After each bend the operator (or robot) may need to turn the part:

enum EHandlingFlip {
    None,       // keep orientation
    Bump,       // push forward along the machine
    RotateL,    // rotate left 90°
    RotateR,    // rotate right 90°
    Rotate180,  // rotate 180°
    Flip,       // flip over (turn upside down)
}

Panel-Bender Data — FoldTech

File: Core/Fold/FoldTech.cs

FoldTech covers panel-bending and bump-bending machines — different from press-brakes in that the sheet stays mostly still and the machine’s bending beam moves.

Property Type Meaning

FMachine

FoldMachine

Target machine

Sections

IList<FoldSection>

Segments of the part processed together

Material

Material

Resolved material (may differ from the request)

CanOptimizeSequence

bool

Whether bend order can be reordered freely

FoldSection → FoldStep

FoldTech
 └── FoldSection[]     ← one group of bends processed without re-gripping
      └── FoldStep[]   ← each individual machine movement

Cutting Data — FlatTech (CutTech)

File: Core/Cut/FlatTech.cs

FlatTech holds everything for cutting the flat blank from a raw sheet, either by laser or by punch.

Property Type Meaning

Dwg

Drawing2

The flat drawing being cut

Config

CutConfig

Machine, material, thickness, film/treatment settings

AllSteps

List<CutStep>

Ordered cutting operations

Entities

AList<CutEntity>

Contours being processed

HasUncutSegs

bool

Warning: some contours have no tooling yet

CutStep subtypes include LaserCut, PunchStep, CommonLineCut, and ScrapCut.

Sheet Layout — Layout

File: Core/Layout/Layout.cs

A Layout arranges one or more part instances on a single physical sheet, ready for cutting.

Property Type Meaning

SheetSize

Size2

Physical sheet dimensions (width × height)

SheetMargin

Margin2

Unusable margins at the sheet edges

SheetGrain

EGrain

Rolling direction of the material

Children

AList<Placement>

Each positioned part instance

Config

CutConfig

Machine and material settings

Estimate

Estimates

Calculated machining time

Placement

Each Placement is one instance of a part on the sheet:

Property Type Meaning

Tech

FlatTech

Cutting data for this part

Pt

Point2

Position of the part on the sheet

Angle

double

Rotation in radians

Mirrored

bool

Whether the part is flipped on the X axis

IsColliding

bool

Validation: overlaps with another placement

GrainMismatch

bool

Validation: rolling direction is wrong

A single Part can appear as many Placement objects on the same sheet.

Nesting — NestJob

File: Core/Nest/NestJob.cs

When multiple different part types must be cut from a batch of sheets, a NestJob manages the optimisation.

NestJob
 ├── NestPart[]       ← which parts are required and how many
 ├── NestSheet[]      ← raw sheets available (size, grain, quantity)
 └── NestPattern[]    ← one result sheet per used sheet
      └── NestElement[] ← each part instance with its position

NestPart

Property Type Meaning

Part

Part

The part to nest

Min

int

Minimum quantity required

Max

int

Maximum allowed

Complete

int

How many have been placed so far

NestSheet

Property Type Meaning

Size

Size2

Sheet dimensions

Margin

Margin2

Unusable edge margins

Qty

int

Number of sheets available

Grain

EGrain

Rolling direction

NestPattern

A NestPattern is one filled sheet — the output for a single raw sheet after nesting:

Property Type Meaning

Job

NestJob

Parent job

Sheet

NestSheet

Which sheet type was used

Elements

List<NestElement>

All placed part instances

Robotic Bend Cell — BCellTech

File: Core/BCell/

When a press-brake is combined with a robot for automated material handling, the robotic cell configuration is stored in BCellTech.

The cell is composed of typed equipment items:

BCellItem               ← abstract: has a name, size, and position
 ├── BStorage           ← pallet, basket, conveyor (where parts wait)
 ├── BGripper           ← end-of-arm tool (vacuum cups or jaw gripper)
 ├── BLightBox          ← vision reference target
 ├── BFurniture         ← passive collision geometry (tables, fences)
 └── BEquipment         ← active conveyors

Key planning objects:

Type Meaning

BRobotPose

A robot TCP (tool-centre-point) position and orientation

BPickupPlan

How and from where the robot picks up a part

BDepositPlan

Where and how the robot places a finished part

BRegrip

A robot manoeuvre to re-orient the part mid-sequence

5-Axis Trimming — TrimJob / TrimTech

Files: Core/Trim/

For parts that need 5-axis cutting (e.g. pipes or complex 3D profiles), TrimJob and TrimTech fill the same role as NestJob and FlatTech do for flat cutting.

Type Meaning

TrimJob

The production job: which machine, which parts, quantities

TrimTech

CAM data for a single part: tool paths, lead-ins, sequences

Global State — FX

File: Core/FX.cs

FX is a large static class that acts as the application’s global state and service locator. A few key properties beginners will encounter frequently:

Property Meaning

FX.Part.Current

The Part currently open in the editor

FX.Settings

Application-wide user settings

FX.DefaultUnit

Whether the app uses millimetres or inches

FX.DataDir

Path to the installation data directory

FX.AdminMode

Whether admin-only features are enabled

Note
FX extends BA (the Base utility module), which means all low-level helpers (logging, geometry, colours) are also accessible through FX.

Change Notifications

The data model uses a lightweight property-watching system instead of (or alongside) standard .NET INotifyPropertyChanged.

Classes that participate implement ISheafSite and expose PWatch / PUnwatch methods. Change events are identified by the EProp enum:

// Subscribe to changes on a part:
part.PWatch(EProp.DwgChanged, OnDwgChanged);

// Unsubscribe:
part.PUnwatch(EProp.DwgChanged, OnDwgChanged);

Common EProp values: DwgChanged, Bendlines, Visual, SheetSize, SheetGrain.

Complete Relationship Diagram

                     NestJob
                    /   |    \
          NestPart[]  NestSheet[]  NestPattern[]
              |                        |
            Part*              NestElement[]
            /|\\ \\                   /  \
           / | \\ \\          NestPart   Point2
          /  |  \\  \\
    Model3 Dwg  BendTech  FoldTech  FlatTech(CutTech)  TrimJob
      |    |       |          |          |
  E3Plane  E2Pline  BendOp[]  FoldSection[]  CutStep[]
  E3Flex   E2Bendline            FoldStep[]
  E3Mesh

Layout
  └── Placement[]
        ├── FlatTech (ref to Part's CutTech)
        ├── Point2  (position on sheet)
        └── double  (rotation angle)

* A Layout also belongs to a Part (Part.Layout = quick single-part layout)

Key Enumerations Summary

Enum Values (selection)

EBendKind

AirBend, Coining, ClosedHem, OpenHem, BumpBend, FormBend

EHandlingFlip

None, Bump, RotateL, RotateR, Rotate180, Flip

ECategory

SheetMetal, Laser, Assembly, Surface, Tube, MultiBody

EGrain

Describes the rolling direction of sheet material

ECutStatus

PartOverlap, UntooledPlines, GrainMismatch, OutOfMachineStroke …

EProp

DwgChanged, Bendlines, Visual, SheetSize, SheetGrain …

Contents

  • The Part
  • Active Part
  • 3D Geometry — Model3
  • Entity Hierarchy
  • 2D Flat Drawing — Drawing2
  • Geometry Primitives
  • Points and Vectors
  • Transforms
  • Polylines — Pline
  • Press-Brake Data — BendTech
  • Bend Operations — BendOp
  • EBendKind — Bend Types
  • EHandlingFlip — Part Re-orientation
  • Panel-Bender Data — FoldTech
  • FoldSection → FoldStep
  • Cutting Data — FlatTech (CutTech)
  • Sheet Layout — Layout
  • Placement
  • Nesting — NestJob
  • NestPart
  • NestSheet
  • NestPattern
  • Robotic Bend Cell — BCellTech
  • 5-Axis Trimming — TrimJob / TrimTech
  • Global State — FX
  • Change Notifications
  • Complete Relationship Diagram
  • Key Enumerations Summary
Data flow Part.Dwg

      Copyright © 2025 TRUMPF Metamation. All rights reserved.

    Compiled by Bento