AGX Dynamics 2.38.0.2
Loading...
Searching...
No Matches
TrimeshReaderWriter.h
Go to the documentation of this file.
1/*
2Copyright 2007-2024. Algoryx Simulation AB.
3
4All AGX source code, intellectual property, documentation, sample code,
5tutorials, scene files and technical white papers, are copyrighted, proprietary
6and confidential material of Algoryx Simulation AB. You may not download, read,
7store, distribute, publish, copy or otherwise disseminate, use or expose this
8material unless having a written signed agreement with Algoryx Simulation AB, or having been
9advised so by Algoryx Simulation AB for a time limited evaluation, or having purchased a
10valid commercial license from Algoryx Simulation AB.
11
12Algoryx Simulation AB disclaims all responsibilities for loss or damage caused
13from using this software, unless otherwise stated in written agreements with
14Algoryx Simulation AB.
15*/
16
17#pragma once
18
19#include <agx/agx.h>
20#include <agxCollide/Trimesh.h>
21
22namespace agxCollide
23{
24 class HeightField;
25}
26
27namespace agxUtil
28{
29
31 namespace TrimeshReaderWriter
32 {
33
43 const agx::String &filename,
44 uint32_t trimeshOptions = agxCollide::Trimesh::REMOVE_DUPLICATE_VERTICES,
45 const agx::Matrix3x3 &vertexRotateAndScale = agx::Matrix3x3(),
46 const agx::Vec3 &vertexTranslate = agx::Vec3());
47
58 const agx::Vec3Vector &vertices,
59 const agx::UInt32Vector &indices,
60 uint32_t trimeshOptions = agxCollide::Trimesh::REMOVE_DUPLICATE_VERTICES,
61 const agx::Matrix3x3 &vertexRotateAndScale = agx::Matrix3x3(),
62 const agx::Vec3 &vertexTranslate = agx::Vec3());
63
76 const agx::String &filename,
77 agx::Real bottomMargin,
78 uint32_t trimeshOptions = agxCollide::Trimesh::REMOVE_DUPLICATE_VERTICES,
79 const agx::Matrix3x3 &vertexRotateAndScale = agx::Matrix3x3(),
80 const agx::Vec3 &vertexTranslate = agx::Vec3());
81
88 const agxCollide::HeightField *heightField);
89
97 AGXPHYSICS_EXPORT bool exportTrimesh(const agxCollide::Trimesh *trimesh, const agx::String &filename);
98
108 const agx::String &filename,
109 const agx::Matrix3x3 &vertexRotateAndScale = agx::Matrix3x3(),
110 const agx::Vec3 &vertexTranslate = agx::Vec3());
111 }
112}
#define AGXPHYSICS_EXPORT
A HeightField is a collision shape that can be created from a grid structure, like an image.
Class for storing rendering information for a Shape.
Definition RenderData.h:39
Triangle mesh for geometric intersection tests.
Definition Trimesh.h:43
@ REMOVE_DUPLICATE_VERTICES
Removes exactly identical duplicates in the vertices, as well as (resulting or previously existing) t...
Definition Trimesh.h:77
This namespace consists of a set of classes for handling geometric intersection tests including boole...
AGXPHYSICS_EXPORT agxCollide::RenderData * createRenderData(const agx::String &filename, const agx::Matrix3x3 &vertexRotateAndScale=agx::Matrix3x3(), const agx::Vec3 &vertexTranslate=agx::Vec3())
Create a RenderData object from a supported mesh file (See agxIO::MeshReader::FileType).
AGXPHYSICS_EXPORT agxCollide::Trimesh * createTrimesh(const agx::String &filename, uint32_t trimeshOptions=agxCollide::Trimesh::REMOVE_DUPLICATE_VERTICES, const agx::Matrix3x3 &vertexRotateAndScale=agx::Matrix3x3(), const agx::Vec3 &vertexTranslate=agx::Vec3())
Create a Trimesh shape from a supported mesh file format (See agxIO::MeshReader::FileType) containing...
AGXPHYSICS_EXPORT agxCollide::Trimesh * createTrimeshTerrain(const agx::String &filename, agx::Real bottomMargin, uint32_t trimeshOptions=agxCollide::Trimesh::REMOVE_DUPLICATE_VERTICES, const agx::Matrix3x3 &vertexRotateAndScale=agx::Matrix3x3(), const agx::Vec3 &vertexTranslate=agx::Vec3())
Create a Terrain shape from a supported mesh model file (See agxIO::MeshReader::FileType).
AGXPHYSICS_EXPORT bool exportTrimesh(const agxCollide::Trimesh *trimesh, const agx::String &filename)
Exports trimesh vertex and index data to a mesh file (currently only supporting wavefront obj).
The agxUtil namespace contain classes and methods for utility functionality.
double Real
Definition Real.h:42