Go to the documentation of this file.
28 IffId map_type = lwo_vmap->_map_type;
29 const std::string &name = lwo_vmap->_name;
32 if (map_type ==
IffId(
"TXUV")) {
34 _txuv.insert(VMap::value_type(name, lwo_vmap)).second;
36 }
else if (map_type ==
IffId(
"PICK")) {
38 _pick.insert(VMap::value_type(name, lwo_vmap)).second;
45 nout <<
"Multiple vertex maps on the same points of type "
46 << map_type <<
" named " << name <<
"\n";
55 get_uv(
const std::string &uv_name,
int n, LPoint2 &uv)
const {
56 VMap::const_iterator ni = _txuv.find(uv_name);
57 if (ni == _txuv.end()) {
62 if (vmap->_dimension != 2) {
63 nout <<
"Unexpected dimension of " << vmap->_dimension
64 <<
" for UV map " << uv_name <<
"\n";
74 uv.set(value[0], value[1]);
85 std::string vpool_name =
"layer" + format_string(_layer->
get_number());
94 if (!_egg_vpool->empty()) {
95 _layer->_egg_group->add_child(_egg_vpool.p());
A mapping of floating-point values per integer index.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
void connect_egg()
Connects all the egg structures together.
bool get_uv(const std::string &uv_name, int n, LPoint2 &uv) const
Returns true if there is a UV of the indicated name associated with the given vertex,...
A four-byte chunk ID appearing in an "IFF" file.
bool has_value(int index) const
Returns true if the map has a value associated with the given index, false otherwise.
void make_egg()
Creates the egg structures associated with this Lightwave object.
PTA_stdfloat get_value(int index) const
Returns the mapping value associated with the given index, or an empty PTA_stdfloat if there is no ma...
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
int get_number() const
Returns the index number associated with this particular layer.
void add_vmap(const LwoVertexMap *lwo_vmap)
Associates the indicated VertexMap with the points set.
A collection of vertices.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.