# mr0wang10/occ-welding-robot-system architecture

> Architecture diagram of the GitHub repository mr0wang10/occ-welding-robot-system, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-03). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/mr0wang10/occ-welding-robot-system
- Repository: https://github.com/mr0wang10/occ-welding-robot-system

## Overview

This is an MFC SDI desktop application for viewing robot models and controlling robot poses in an OpenCascade 3D view. The documented user workflow is to use the robot control panel to select or control a model, enter inverse-kinematics inputs, and inspect joint/TCP pose information in the view. The main frame hosts the docked controls and view; the document is the SDI document stage. Welding-related UI and seam display are also represented, but their full runtime wiring was not sampled. Dashed edges mark relationships not verified in excerpts.

Main entry points: [`OCC_MFC/MainFrm.cpp`](https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/MainFrm.cpp) (Main frame), [`OCC_MFC/OCC_MFCView.cpp`](https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/OCC_MFCView.cpp) (OpenCascade view), [`OCC_MFC/CRobotControlDlg.cpp`](https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/CRobotControlDlg.cpp) (Robot controls), [`OCC_MFC/OCC_MFC.cpp`](https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/OCC_MFC.cpp) (MFC application)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_shell["Application shell"]
  node_app["MFC application<br/>[OCC_MFC.cpp]"]
  node_frame["Main frame<br/>[MainFrm.cpp]"]
  node_document["SDI document<br/>[OCC_MFCDoc.cpp]"]
  node_view["OpenCascade view<br/>[OCC_MFCView.cpp]"]
  node_fileview["File view<br/>[FileView.cpp]"]
  node_classview["Class view<br/>[ClassView.cpp]"]
  node_properties["Properties pane<br/>[PropertiesWnd.cpp]"]
  node_output["Output pane<br/>[OutputWnd.cpp]"]
end

subgraph group_robot["Robot interaction"]
  node_robotpane["Control pane<br/>[CControlPane.cpp]"]
  node_robotcontrols["Robot controls"]
  node_robotpage["Robot page<br/>[CPageRobot.cpp]"]
  node_kinematics["6-DOF kinematics<br/>[Kine6Dof.h]"]
  node_kinelib["Kine6Dof library"]
  node_model[("Robot model library")]
end

subgraph group_welding["Weld visualization"]
  node_weldpage["Weld page<br/>[CPageWeld.cpp]"]
  node_weldview["Weld seam display<br/>[OCC_MFCView.cpp]"]
  node_weldidentify["Wire identification"]
end

node_user(("Operator"))

node_user -->|"starts"| node_app
node_app -->|"creates"| node_frame
node_app -->|"opens"| node_document
node_app -->|"creates"| node_view
node_frame -->|"creates"| node_robotpane
node_frame -->|"resizes"| node_view
node_frame -->|"hosts"| node_fileview
node_frame -->|"hosts"| node_classview
node_frame -->|"hosts"| node_properties
node_frame -->|"hosts"| node_output
node_user -->|"enters poses"| node_robotcontrols
node_robotpane -.->|"hosts"| node_robotcontrols
node_robotcontrols -.->|"uses"| node_robotpage
node_robotcontrols -.->|"requests inverse solve"| node_kinematics
node_kinematics -.->|"uses"| node_kinelib
node_robotcontrols -.->|"controls pose"| node_view
node_view -->|"displays"| node_model
node_view -->|"uses"| node_document
node_user -.->|"uses"| node_weldpage
node_weldpage -.->|"processes wire"| node_weldidentify
node_weldpage -.->|"requests display"| node_weldview
node_weldview -.->|"renders seams"| node_view

click node_app "https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/OCC_MFC.cpp"
click node_frame "https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/MainFrm.cpp"
click node_document "https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/OCC_MFCDoc.cpp"
click node_robotpane "https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/CControlPane.cpp"
click node_robotcontrols "https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/CRobotControlDlg.cpp"
click node_robotpage "https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/CPageRobot.cpp"
click node_kinematics "https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/Kine6Dof.h"
click node_model "https://github.com/mr0wang10/occ-welding-robot-system/tree/master/OCC_MFC/Rbt3DModelLib"
click node_view "https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/OCC_MFCView.cpp"
click node_weldpage "https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/CPageWeld.cpp"
click node_weldview "https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/OCC_MFCView.cpp"
click node_weldidentify "https://github.com/mr0wang10/occ-welding-robot-system/blob/master/weldwire_identfy.cpp"
click node_fileview "https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/FileView.cpp"
click node_classview "https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/ClassView.cpp"
click node_properties "https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/PropertiesWnd.cpp"
click node_output "https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/OutputWnd.cpp"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_app,node_frame,node_document,node_view,node_fileview,node_classview,node_properties,node_output toneBlue
class node_robotpane,node_robotcontrols,node_robotpage,node_kinematics,node_kinelib,node_model toneAmber
class node_weldpage,node_weldview,node_weldidentify toneMint
class node_user toneIndigo
```

## Components

### Application shell

- [MFC application](https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/OCC_MFC.cpp): `OCC_MFC/OCC_MFC.cpp`
- [Main frame](https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/MainFrm.cpp): `OCC_MFC/MainFrm.cpp`
- [SDI document](https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/OCC_MFCDoc.cpp): `OCC_MFC/OCC_MFCDoc.cpp`
- [OpenCascade view](https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/OCC_MFCView.cpp): `OCC_MFC/OCC_MFCView.cpp`
- [File view](https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/FileView.cpp): `OCC_MFC/FileView.cpp`
- [Class view](https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/ClassView.cpp): `OCC_MFC/ClassView.cpp`
- [Properties pane](https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/PropertiesWnd.cpp): `OCC_MFC/PropertiesWnd.cpp`
- [Output pane](https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/OutputWnd.cpp): `OCC_MFC/OutputWnd.cpp`

### Robot interaction

- [Control pane](https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/CControlPane.cpp): `OCC_MFC/CControlPane.cpp`
- [Robot controls](https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/CRobotControlDlg.cpp): `OCC_MFC/CRobotControlDlg.cpp`
- [Robot page](https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/CPageRobot.cpp): `OCC_MFC/CPageRobot.cpp`
- [6-DOF kinematics](https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/Kine6Dof.h): `OCC_MFC/Kine6Dof.h`
- **Kine6Dof library**
- [Robot model library](https://github.com/mr0wang10/occ-welding-robot-system/tree/master/OCC_MFC/Rbt3DModelLib): `OCC_MFC/Rbt3DModelLib`

### Weld visualization

- [Weld page](https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/CPageWeld.cpp): `OCC_MFC/CPageWeld.cpp`
- [Weld seam display](https://github.com/mr0wang10/occ-welding-robot-system/blob/master/OCC_MFC/OCC_MFCView.cpp): `OCC_MFC/OCC_MFCView.cpp`
- [Wire identification](https://github.com/mr0wang10/occ-welding-robot-system/blob/master/weldwire_identfy.cpp): `weldwire_identfy.cpp`

### Other components

- **Operator**

## Connections

- Operator → MFC application: starts
- MFC application → Main frame: creates
- MFC application → SDI document: opens
- MFC application → OpenCascade view: creates
- Main frame → Control pane: creates (evidence: `OCC_MFC/MainFrm.cpp`)
- Main frame → OpenCascade view: resizes (evidence: `OCC_MFC/MainFrm.cpp`)
- Main frame → File view: hosts (evidence: `OCC_MFC/MainFrm.cpp`)
- Main frame → Class view: hosts (evidence: `OCC_MFC/MainFrm.cpp`)
- Main frame → Properties pane: hosts (evidence: `OCC_MFC/MainFrm.cpp`)
- Main frame → Output pane: hosts (evidence: `OCC_MFC/MainFrm.cpp`)
- Operator → Robot controls: enters poses
- Control pane → Robot controls: hosts
- Robot controls → Robot page: uses
- Robot controls → 6-DOF kinematics: requests inverse solve
- 6-DOF kinematics → Kine6Dof library: uses
- Robot controls → OpenCascade view: controls pose
- OpenCascade view → Robot model library: displays
- OpenCascade view → SDI document: uses
- Operator → Weld page: uses
- Weld page → Wire identification: processes wire
- Weld page → Weld seam display: requests display
- Weld seam display → OpenCascade view: renders seams
