Ticket #1113: DontUseCPPGraphics.diff

File DontUseCPPGraphics.diff, 1.0 KB (added by MattArsenault, 13 years ago)

Use extern C for graphics API

  • api/graphics2.h

    diff --git a/api/graphics2.h b/api/graphics2.h
    index 1dc5504..71f944b 100644
    a b  
    1818#ifndef _GRAPHICS2_H_
    1919#define _GRAPHICS2_H_
    2020
     21#ifdef __cplusplus
     22extern "C" {
     23#endif
     24
    2125// Functions that must be supplied by the app
    2226//
    2327extern void app_graphics_render(int xs, int ys, double time_of_day);
    extern void boinc_app_key_release(int, int); 
    3034
    3135// Functions that the app can call
    3236//
    33 extern void boinc_graphics_loop(int argc, char** argv, const char* title=0);
     37extern void boinc_graphics_loop(int argc, char** argv, const char* title);
    3438extern void* boinc_graphics_make_shmem(const char*, int);
    3539extern void* boinc_graphics_get_shmem(const char*);
    3640extern void boinc_set_windows_icon(const char* icon16,const char* icon48);
    extern double boinc_max_gfx_cpu_frac; 
    4347extern void get_window_title(char* buf, int len);
    4448extern bool throttled_app_render(int, int, double);
    4549
     50#ifdef __cplusplus
     51}
    4652#endif
     53
     54#endif /* _GRAPHICS2_H_ */
     55
     56