libweed 0.0.3

weed-host.h

Go to the documentation of this file.
00001 /* WEED is free software; you can redistribute it and/or
00002    modify it under the terms of the GNU Lesser General Public
00003    License as published by the Free Software Foundation; either
00004    version 3 of the License, or (at your option) any later version.
00005 
00006    Weed is distributed in the hope that it will be useful,
00007    but WITHOUT ANY WARRANTY; without even the implied warranty of
00008    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00009    Lesser General Public License for more details.
00010 
00011    You should have received a copy of the GNU Lesser General Public
00012    License along with this source code; if not, write to the Free Software
00013    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
00014 
00015 
00016    Weed is developed by:
00017 
00018    Gabriel "Salsaman" Finch - http://lives.sourceforge.net
00019 
00020    mainly based on LiViDO, which is developed by:
00021 
00022 
00023    Niels Elburg - http://veejay.sf.net
00024 
00025    Gabriel "Salsaman" Finch - http://lives.sourceforge.net
00026 
00027    Denis "Jaromil" Rojo - http://freej.dyne.org
00028 
00029    Tom Schouten - http://zwizwa.fartit.com
00030 
00031    Andraz Tori - http://cvs.cinelerra.org
00032 
00033    reviewed with suggestions and contributions from:
00034 
00035    Silvano "Kysucix" Galliani - http://freej.dyne.org
00036 
00037    Kentaro Fukuchi - http://megaui.net/fukuchi
00038 
00039    Jun Iio - http://www.malib.net
00040 
00041    Carlo Prelz - http://www2.fluido.as:8080/
00042 
00043 */
00044 
00045 /* (C) Gabriel "Salsaman" Finch, 2005 - 2007 */
00046 
00047 #ifndef __WEED_HOST_H__
00048 #define __WEED_HOST_H__
00049 
00050 #ifndef __WEED_H__
00051 #include <weed/weed.h>
00052 #endif
00053 
00054 #ifdef __cplusplus
00055 extern "C"
00056 {
00057 #endif /* __cplusplus */
00058 
00059 /* Plant types */
00060 #define WEED_PLANT_UNKNOWN 0 ///< used for host deserialisation only
00061 
00062 /* Caller Types */
00063 #define WEED_CALLER_HOST 0
00064 #define WEED_CALLER_PLUGIN 1
00065 
00066   /* host only functions */
00067 typedef void (*weed_plant_free_f)(weed_plant_t *plant);
00068 typedef int (*weed_leaf_delete_f)(weed_plant_t *plant, const char *key);
00069 typedef int (*weed_leaf_set_flags_f)(weed_plant_t *plant, const char *key, int flags);
00070 typedef int (weed_leaf_set_caller_f)(weed_plant_t *plant, const char *key, int seed_type, int num_elems, void *value, int caller);
00071 
00072 #ifndef _SKIP_WEED_API_
00073 weed_default_getter_f weed_default_get;
00074 weed_leaf_get_f weed_leaf_get;
00075 weed_leaf_set_f weed_leaf_set;
00076 weed_leaf_set_f weed_leaf_set_plugin;
00077 weed_plant_new_f weed_plant_new;
00078 weed_plant_free_f weed_plant_free;
00079 weed_leaf_delete_f weed_leaf_delete;
00080 weed_plant_list_leaves_f weed_plant_list_leaves;
00081 weed_leaf_num_elements_f weed_leaf_num_elements;
00082 weed_leaf_element_size_f weed_leaf_element_size;
00083 weed_leaf_seed_type_f weed_leaf_seed_type;
00084 weed_leaf_get_flags_f weed_leaf_get_flags;
00085 weed_leaf_set_flags_f weed_leaf_set_flags;
00086 
00087 weed_malloc_f weed_malloc;
00088 weed_free_f weed_free;
00089 weed_memcpy_f weed_memcpy;
00090 weed_memset_f weed_memset;
00091 
00092 #endif
00093 
00094 void weed_init(int api_v, weed_malloc_f, weed_free_f, weed_memcpy_f, weed_memset_f);
00095 
00096 #ifdef __cplusplus
00097 }
00098 #endif /* __cplusplus */
00099 
00100 #endif // #ifndef __WEED_HOST_H__
00101 
00102 
 All Data Structures Files Functions Variables Typedefs Defines