Skip to content

Commit

Permalink
Bindings: Add template specializations
Browse files Browse the repository at this point in the history
  • Loading branch information
ferdnyc committed Dec 4, 2020
1 parent d0a625c commit b280fbd
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
2 changes: 2 additions & 0 deletions bindings/python/openshot.i
Expand Up @@ -129,6 +129,8 @@
%template() std::map<std::string, int>;
%template() std::pair<int, int>;
%template() std::vector<int>;
%template() std::pair<double, double>;
%template() std::pair<float, float>;

/* Make openshot.Fraction more Pythonic */
%extend openshot::Fraction {
Expand Down
7 changes: 7 additions & 0 deletions bindings/ruby/openshot.i
Expand Up @@ -57,6 +57,13 @@
%shared_ptr(juce::AudioSampleBuffer)
%shared_ptr(openshot::Frame)

/* Template specializations */
%template() std::map<std::string, int>;
%template() std::pair<int, int>;
%template() std::vector<int>;
%template() std::pair<double, double>;
%template() std::pair<float, float>;

%{
/* Ruby and FFmpeg define competing RSHIFT macros,
* so we move Ruby's out of the way for now. We'll
Expand Down

0 comments on commit b280fbd

Please sign in to comment.