GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - LIHPC-Computational-Geometry/hexex2geogram: .hexex to .geogram mesh file conversion

BranchesTags
Open more actions menu

Latest commit

 

History

11 Commits
11 Commits

Folders and files

NameName
Last commit message
Last commit date
data
data
 
 
ultimaille @ 5fba21e
ultimaille @ 5fba21e
 
 
.gitignore
.gitignore
 
 
.gitmodules
.gitmodules
 
 
CITATION.cff
CITATION.cff
 
 
CMakeLists.txt
CMakeLists.txt
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
main.cpp
main.cpp
 
 

Repository files navigation

hexex2geogram : .hexex to .geogram mesh file conversion

Maintenance Level: Abandoned

A .hexex file stores a tetrahedral mesh with an $u,v,w$ parametrization. The syntax is explained in the additional material of HexEx1 and also below.

.geogram is a file format used by the Geogram library, which supports embedded attributes.

This simple program converts a .hexex file to a .geogram one, using per-cell-corner attributes to store the parametrization.

Requirements

  • a C++ 17 compiler
  • CMake
  • UltiMaille (included as submodule)
  • Graphite or Vorpaview, to visualize the output .geogram file
  • OpenMP (optionnal)

Build

mkdir build
cd build
cmake ..
make

Tutorial

The sphere.hexex file comes from the additional material of HexEx1.

./hexex2geogram ../data/sphere.hexex ../data/sphere.geogram

Then:

  • open sphere.geogram with Graphite
  • in the Properties panel, choose "ATTRIBUTE" for "painting"
  • choose "cell_corners.u", "cell_corners.v" or "cell_corners.w" for "attribute"
  • click on "autorange"
  • use a perceptually correct colormap

The output files of MC3D2 also use the .hexex format, with additional information at the end (the walls of the block decomposition). These walls could be saved in the output .geogram file with cell facets attributes, but as of today (October 2023), Graphite/Vorpaview cannot display them. Instead, tetrahedra are grouped by block, and a cell attribute "cells.block_id" is exported. The computation is quite slow.

.hexex format

It is an ASCII-based format.

The fist line is $n$, the number of vertices. It is followed by $n$ lines defining the $n$ vertices. A vertex definition has 3 floating-point numbers for the $x$, $y$ and $z$ coordinates, separated by spaces.

Then there is $m$, the number of cells, followed by $m$ lines for the tetrahedra definitions. A tetrahedron defintion has 4 integers $i0,i1,i2,i3$ (vertex index for each corner) then $4 \times 3$ floating-point numbers ( $u,v,w$ for corner 0, then for corner 1, corner 2 and corner 3), separated by spaces.

The vertices indices $i0,i1,i2,i3$ must be ordered such that $$\det(i1-i0,i2-i0,i3-i0)>0$$ This condition is not checked in hexex2geogram.

In case of an output of MC3D2, the file ends with the number of wall triangles $w$, followed by $w$ lines for wall triangle definitions. A wall triangle definition has 3 integers and a floating-point number (separated by spaces): the 3 vertex indices and the distance from the brush fire's origin.

License

AGPL-3.0

Cite this repository

See CITATION.cff or the dedicated button on GitHub

Footnotes

  1. Max Lyon, David Bommes, Leif Kobbelt, HexEx: Robust Hexahedral Mesh Extraction, SIGGRAPH 2016, url ↩ ↩2

  2. Hendrik Brückler, Ojaswi Gupta, Manish Mandad, Marcel Campen, The 3D Motorcycle Complex for Structured Volume Decomposition, Eurographics 2022, url ↩ ↩2

About

.hexex to .geogram mesh file conversion

Topics

file-conversionfile-convertergeometry-processingmeshmesh-processing

Resources

Readme
AGPL-3.0 license
Activity
Custom properties

Stars

2 stars

Watchers

1 watching

Forks

0 forks
Report repository

Contributors

Languages

You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.