00001 /* 00002 Data types, function prototypes, etc. used within liveViz. 00003 */ 00004 #ifndef __UIUC_CHARM_LIVEVIZ_IMPL_H 00005 #define __UIUC_CHARM_LIVEVIZ_IMPL_H 00006 #include "liveViz.h" 00007 00008 //Silly globals declared in liveViz.C 00009 extern liveVizConfig lv_config; 00010 extern CProxy_liveVizGroup lvG; 00011 00012 00013 // Moved here from liveViz.C so that liveVizPoll.C can see it too. 00014 class imageHeader { 00015 public: 00016 liveVizRequest req; 00017 CkRect r; 00018 imageHeader(const liveVizRequest &req_,const CkRect &r_) 00019 :req(req_), r(r_) {} 00020 }; 00021 00022 extern void vizReductionHandler(void *r_msg); 00023 void liveVizInitComplete(void *rednMessage); 00024 extern CkCallback clientGetImageCallback; 00025 00026 //The liveVizGroup is only used to set lv_config on every processor. 00027 class liveVizGroup : public CBase_liveVizGroup { 00028 public: 00029 liveVizGroup(const liveVizConfig &cfg) { 00030 lv_config=cfg; 00031 contribute(0,0,CkReduction::sum_int,CkCallback(liveVizInitComplete)); 00032 } 00033 liveVizGroup(CkMigrateMessage *m): CBase_liveVizGroup(m) {} 00034 void pup(PUP::er &p) { 00035 lv_config.pupNetwork(p); 00036 } 00037 }; 00038 00039 #endif