Skip to content

raisim::Mesh::FileCache ​

class · #include <raisim/object/singleBodies/Mesh.hpp>

Mesh files read by World::addMesh(), so a mesh placed many times (a .rasset collider, say) is read from disk once per world. An entry is reused while its file keeps its size and modification time, so an edited file is read again. Vertices are scaled after reading exactly as loadMesh() scales them. USD files, whose units and transforms are applied while reading, are always read directly.

Nested classes ​

  • struct Contents — Unscaled contents of one mesh file.

Public member functions ​

find ​

cpp
std::shared_ptr<const Contents> find(const std::string &filename)

Parameters

ParameterDescription
filename (in)mesh file

Returns its contents, read on first use; nullptr if the file is not cached (USD, or its size or time cannot be read)

RaiSim — physics for robotics and AI.