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 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180
|
/**
* @file
* @brief SWIG configuration for libopenshot (to generate Java SWIG bindings)
* @author Jonathan Thomas <jonathan@openshot.org>
*
* @section LICENSE
*/
// Copyright (c) 2008-2024 OpenShot Studios, LLC
//
// SPDX-License-Identifier: LGPL-3.0-or-later
%module("threads"=1) openshot
/* Suppress warnings about ignored operator= */
%warnfilter(362);
/* Don't generate multiple wrappers for functions with default args */
%feature("compactdefaultargs", "1");
/* Enable inline documentation */
%feature("autodoc", "1");
/* Include various SWIG helpers */
%include "typemaps.i"
%include "std_string.i"
#%include "std_list.i"
%include "std_vector.i"
%include "std_map.i"
%include <stdint.i>
/* Unhandled STL Exception Handling */
%include <std_except.i>
/* Include shared pointer code */
#%include <std_shared_ptr.i>
/* Mark these classes as shared_ptr classes */
#ifdef USE_IMAGEMAGICK
#%shared_ptr(Magick::Image)
#endif
#%shared_ptr(juce::AudioBuffer<float>)
#%shared_ptr(openshot::Frame)
/* Instantiate the required template specializations */
%template() std::map<std::string, int>;
#%template() std::pair<int, int>;
%template() std::vector<int>;
%template() std::vector<float>;
#%template() std::pair<double, double>;
#%template() std::pair<float, float>;
#%template() std::pair<std::string, std::string>;
#%template() std::vector<std::pair<std::string, std::string>>;
%template() std::vector<std::vector<float>>;
%{
#include "OpenShotVersion.h"
#include "ReaderBase.h"
#include "WriterBase.h"
#include "AudioDevices.h"
#include "AudioWaveformer.h"
#include "CacheBase.h"
#include "CacheDisk.h"
#include "CacheMemory.h"
#include "ChannelLayouts.h"
#include "ChunkReader.h"
#include "ChunkWriter.h"
#include "ClipBase.h"
#include "Clip.h"
#include "Coordinate.h"
#include "Color.h"
#include "DummyReader.h"
#include "EffectBase.h"
#include "Effects.h"
#include "EffectInfo.h"
#include "Enums.h"
#include "Exceptions.h"
#include "FFmpegReader.h"
#include "FFmpegWriter.h"
#include "Fraction.h"
#include "Frame.h"
#include "FrameMapper.h"
#include "PlayerBase.h"
#include "Point.h"
#include "Profiles.h"
#include "QtHtmlReader.h"
#include "QtImageReader.h"
#include "QtPlayer.h"
#include "QtTextReader.h"
#include "KeyFrame.h"
#include "RendererBase.h"
#include "Settings.h"
#include "TimelineBase.h"
#include "Timeline.h"
#include "ZmqLogger.h"
%}
#ifdef USE_IMAGEMAGICK
%{
#include "ImageReader.h"
#include "ImageWriter.h"
#include "TextReader.h"
%}
#endif
/* Wrap std templates (list, vector, etc...) */
#%template(ClipList) std::list<openshot::Clip *>;
#%template(EffectBaseList) std::list<openshot::EffectBase *>;
%template(CoordinateVector) std::vector<openshot::Coordinate>;
%template(PointsVector) std::vector<openshot::Point>;
%template(FieldVector) std::vector<openshot::Field>;
%template(MappedFrameVector) std::vector<openshot::MappedFrame>;
%template(MetadataMap) std::map<std::string, std::string>;
/* Deprecated */
%template(AudioDeviceInfoVector) std::vector<openshot::AudioDeviceInfo>;
%include "OpenShotVersion.h"
%include "ReaderBase.h"
%include "WriterBase.h"
%include "AudioDevices.h"
%include "AudioWaveformer.h"
%include "CacheBase.h"
%include "CacheDisk.h"
%include "CacheMemory.h"
%include "ChannelLayouts.h"
%include "ChunkReader.h"
%include "ChunkWriter.h"
%include "ClipBase.h"
%include "Clip.h"
%include "Coordinate.h"
%include "Color.h"
%include "DummyReader.h"
%include "EffectBase.h"
%include "Effects.h"
%include "EffectInfo.h"
%include "Enums.h"
%include "Exceptions.h"
%include "FFmpegReader.h"
%include "FFmpegWriter.h"
%include "Fraction.h"
%include "Frame.h"
%include "FrameMapper.h"
%include "PlayerBase.h"
%include "Point.h"
%include "Profiles.h"
%include "QtHtmlReader.h"
%include "QtImageReader.h"
%include "QtPlayer.h"
%include "QtTextReader.h"
%include "KeyFrame.h"
%include "RendererBase.h"
%include "Settings.h"
%include "TimelineBase.h"
%include "Timeline.h"
%include "ZmqLogger.h"
#ifdef USE_IMAGEMAGICK
%include "ImageReader.h"
%include "ImageWriter.h"
%include "TextReader.h"
#endif
/* Effects */
%include "effects/Bars.h"
%include "effects/Blur.h"
%include "effects/Brightness.h"
%include "effects/Caption.h"
%include "effects/ChromaKey.h"
%include "effects/ColorShift.h"
%include "effects/Crop.h"
%include "effects/Deinterlace.h"
%include "effects/Hue.h"
%include "effects/Mask.h"
%include "effects/Negate.h"
%include "effects/Pixelate.h"
%include "effects/Saturation.h"
%include "effects/Shift.h"
%include "effects/Wave.h"
|