Added a makefile
This commit is contained in:
@@ -119,33 +119,14 @@ public:
|
||||
void update_from(const AnimQueue &queue);
|
||||
};
|
||||
|
||||
// AnimViewMap: basically just a map from tangible ID to AnimView.
|
||||
// AnimViewMap: a unordered_map from tangible ID to AnimView. Adds a few
|
||||
// methods for garbage collection and updating.
|
||||
//
|
||||
// Also provides a simple garbage collector to get rid of AnimViews
|
||||
// that haven't been updated recently.
|
||||
//
|
||||
class AnimViewMap {
|
||||
class AnimViewMap : public std::unordered_map<int64_t, AnimView> {
|
||||
public:
|
||||
using ViewMap = std::unordered_map<int64_t, AnimView>;
|
||||
private:
|
||||
ViewMap view_map_;
|
||||
public:
|
||||
AnimViewMap() {}
|
||||
~AnimViewMap() {}
|
||||
|
||||
// Get the entire view map for iterating over.
|
||||
ViewMap &get_map() { return view_map_; }
|
||||
|
||||
// Get one entry from the view map, if it exists.
|
||||
AnimView *get_one(int64_t id);
|
||||
|
||||
// Clear the updated bits on all the AnimViews.
|
||||
void clear_updated_bits();
|
||||
|
||||
// Delete any AnimViews whose updated bits are not set.
|
||||
void delete_non_updated();
|
||||
|
||||
// Update one AnimView, and set its updated bit.
|
||||
void update_one(const AnimQueue &queue);
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user