# HG changeset patch # User John Tsiombikas # Date 1346206246 -10800 # Node ID 23d4c50616fff59051952d1c4a4aa5607103ebd9 # Parent 0f83e882fd048568310f50b295db08d865309b67 C++ header file compatibility diff -r 0f83e882fd04 -r 23d4c50616ff src/pattr.h --- a/src/pattr.h Wed Aug 29 03:16:58 2012 +0300 +++ b/src/pattr.h Wed Aug 29 05:10:46 2012 +0300 @@ -30,6 +30,10 @@ int max_particles; }; +#ifdef __cplusplus +extern "C" { +#endif + void psys_texture_loader(unsigned int (*load)(const char*, void*), void (*unload)(unsigned int, void*), void *cls); int psys_init_attr(struct psys_attributes *attr); @@ -43,4 +47,8 @@ int psys_save_attr(struct psys_attributes *attr, const char *fname); int psys_save_attr_stream(struct psys_attributes *attr, FILE *fp); +#ifdef __cplusplus +} #endif + +#endif /* PATTR_H_ */ diff -r 0f83e882fd04 -r 23d4c50616ff src/psys.h --- a/src/psys.h Wed Aug 29 03:16:58 2012 +0300 +++ b/src/psys.h Wed Aug 29 05:10:46 2012 +0300 @@ -70,7 +70,9 @@ struct psys_particle *next; }; - +#ifdef __cplusplus +extern "C" { +#endif struct psys_emitter *psys_create(void); void psys_free(struct psys_emitter *em); @@ -98,4 +100,8 @@ void psys_update(struct psys_emitter *em, float tm); void psys_draw(struct psys_emitter *em); +#ifdef __cplusplus +} +#endif + #endif /* LIBPSYS_H_ */