forked from soblin/matplotlibcpp17
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathanimation.h
More file actions
40 lines (33 loc) · 1.13 KB
/
Copy pathanimation.h
File metadata and controls
40 lines (33 loc) · 1.13 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
/**
* @file animation.h
* @brief corresponding header for matplotlib.animation
**/
#pragma once
#include <pybind11/pybind11.h>
#include <matplotlibcpp17/common.h>
namespace matplotlibcpp17::animation {
/**
* @brief A wrapper class for matplotlib.animation.ArtistAnimation
**/
struct DECL_STRUCT_ATTR ArtistAnimation : public BaseWrapper {
public:
ArtistAnimation(const pybind11::tuple &args, const pybind11::dict &kwargs) {
pybind11::object attr = pybind11::module::import("matplotlib.animation")
.attr("ArtistAnimation");
self = attr(*args, **kwargs);
load_attrs();
}
// save
ObjectWrapper save(const pybind11::tuple &args = pybind11::tuple(),
const pybind11::dict &kwargs = pybind11::dict());
private:
void load_attrs() { LOAD_FUNC_ATTR(save, self); }
pybind11::object save_attr;
};
// save
ObjectWrapper ArtistAnimation::save(const pybind11::tuple &args,
const pybind11::dict &kwargs) {
pybind11::object ret = save_attr(*args, **kwargs);
return ObjectWrapper(std::move(ret));
}
} // namespace matplotlibcpp17::animation