gmio/src/gmio_stl/stl_mesh.h

45 lines
1.4 KiB
C
Raw Normal View History

2015-03-03 00:38:33 +08:00
/****************************************************************************
2015-05-28 15:40:24 +08:00
** gmio
2015-05-01 00:19:45 +08:00
** Copyright Fougue (2 Mar. 2015)
2015-03-03 00:38:33 +08:00
** contact@fougsys.fr
**
** This software is a reusable library whose purpose is to provide complete
** I/O support for various CAD file formats (eg. STL)
**
** This software is governed by the CeCILL-B license under French law and
** abiding by the rules of distribution of free software. You can use,
** modify and/ or redistribute the software under the terms of the CeCILL-B
** license as circulated by CEA, CNRS and INRIA at the following URL
2015-03-30 15:05:25 +08:00
** "http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html".
2015-03-03 00:38:33 +08:00
****************************************************************************/
2015-03-05 01:25:51 +08:00
/*! \file stl_mesh.h
* Declaration of gmio_stl_mesh
*/
#ifndef GMIO_STL_MESH_H
#define GMIO_STL_MESH_H
2014-01-29 23:59:19 +08:00
#include "stl_global.h"
#include "stl_triangle.h"
2014-03-13 21:37:55 +08:00
/*! Provides an interface for accessing the underlying(hidden) user mesh */
struct gmio_stl_mesh
2014-01-29 23:59:19 +08:00
{
/*! Opaque pointer on the user mesh, passed as first argument to hook
* functions */
2015-03-03 17:35:36 +08:00
const void* cookie;
2014-03-13 21:37:55 +08:00
2015-03-03 17:35:36 +08:00
/*! Number of triangles in the mesh */
2015-03-20 00:31:08 +08:00
uint32_t triangle_count;
2014-03-13 21:37:55 +08:00
/*! Pointer on a function that stores the mesh triangle of index \p tri_id
* into \p triangle */
2015-03-20 00:31:08 +08:00
void (*get_triangle_func)(
const void* cookie, uint32_t tri_id, gmio_stl_triangle_t* triangle);
};
typedef struct gmio_stl_mesh gmio_stl_mesh_t;
2014-01-29 23:59:19 +08:00
#endif /* GMIO_STL_MESH_H */