Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Philip Trettner
polymesh
Commits
9cc357e2
Commit
9cc357e2
authored
Jul 23, 2018
by
Philip Trettner
Browse files
access to attributes in attribute collection
parent
43a4968a
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/polymesh/attribute_collection.hh
View file @
9cc357e2
...
...
@@ -32,6 +32,13 @@ struct attribute_collection
accessor
operator
[](
std
::
string
const
&
name
)
{
return
{
name
,
*
this
};
}
const_accessor
operator
[](
std
::
string
const
&
name
)
const
{
return
{
name
,
*
this
};
}
/// access to all attributes
/// (should usually not be used)
std
::
map
<
std
::
string
,
std
::
unique_ptr
<
primitive_attribute_base
<
vertex_tag
>>>
const
&
vertex_attributes
()
const
{
return
mVertexAttrs
;
}
std
::
map
<
std
::
string
,
std
::
unique_ptr
<
primitive_attribute_base
<
face_tag
>>>
const
&
face_attributes
()
const
{
return
mFaceAttrs
;
}
std
::
map
<
std
::
string
,
std
::
unique_ptr
<
primitive_attribute_base
<
edge_tag
>>>
const
&
edge_attributes
()
const
{
return
mEdgeAttrs
;
}
std
::
map
<
std
::
string
,
std
::
unique_ptr
<
primitive_attribute_base
<
halfedge_tag
>>>
const
&
halfedge_attributes
()
const
{
return
mHalfedgeAttrs
;
}
public:
struct
accessor
{
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment