f8c6b2acc39f39ad6a0be0685f4b36852bcdde5a
[ardour.git] / libs / ardour / ardour / lua_script_params.h
1 /*
2  * Copyright (C) 2016 Robin Gareus <robin@gareus.org>
3  *
4  * This program is free software; you can redistribute it and/or
5  * modify it under the terms of the GNU General Public License
6  * as published by the Free Software Foundation; either version 2
7  * of the License, or (at your option) any later version.
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with this program; if not, write to the Free Software
16  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
17  *
18  */
19 #ifndef _ardour_lua_script_params_h_
20 #define _ardour_lua_script_params_h_
21
22 #include "ardour/libardour_visibility.h"
23 #include "ardour/luascripting.h"
24 #include "LuaBridge/LuaBridge.h"
25
26 /* Semantically these are static functions of the LuaScripting class
27  * but are kept separately to minimize header includes.
28  *
29  * LuaScripting itself is a standalone abstraction (not depending on luabridge)
30  * luascripting.h is included by session.h (this file is not).
31  *
32  * The implementation of these functions is in libs/ardour/luascripting.cc
33  */
34 namespace ARDOUR { namespace LuaScriptParams {
35
36         LIBARDOUR_API LuaScriptParamList script_params (LuaScriptInfoPtr, const std::string &);
37         LIBARDOUR_API LuaScriptParamList script_params (const std::string &, const std::string &, bool file=true);
38         LIBARDOUR_API void params_to_ref (luabridge::LuaRef *tbl_args, const LuaScriptParamList&);
39         LIBARDOUR_API void ref_to_params (LuaScriptParamList&, luabridge::LuaRef *tbl_args);
40
41 } } // namespace
42
43 #endif // _ardour_lua_script_params_h_