#ifndef b4_xy_INCLUDED #define b4_xy_INCLUDED #include #ifdef WIN32 #ifdef DOEXPORT_SCRIPT #define EXPORT_SCRIPT __declspec(dllexport) #else #define EXPORT_SCRIPT #endif #else #define EXPORT_SCRIPT #endif class b4_xy : public bncs_script_helper { public: b4_xy( bncs_client_callback * parent, const char* path ); virtual ~b4_xy(); void buttonCallback( buttonNotify *b ); int revertiveCallback( revertiveNotify * r ); void databaseCallback( revertiveNotify * r ); bncs_string parentCallback( parentNotify *p ); void timerCallback( int ); private: #define MATRIXSIZE 64 // Size of audio and video routers int video_id; // BNCS driver id of the video matrix int audio_id; // BNCS driver id of the audio matrix int pkg_name_id; // BNCS driver id of the package names int pkg_xpts_id; // BNCS driver id of the package crosspoint comma delimted strings. int srcpkg; // Source package number int destpkg; // Destination package number int videosrc; // Video source id in source package int audiosrc; // Audio source id in source package int newvideosrc; // Video source id in newly selected source package int newaudiosrc; // Audio source id in newly selected source package int videodest; // Video destination id in destination package int audiodest; // Audio destination id in destination package int undo_vid_src; // Holds video source number for undo operations int undo_aud_src; // Holds audio source number for undo operations int undo_vid_dest; // Holds video destination number for undo operations int undo_aud_dest; // Holds audio destination for undo operations. int take_count; // Used by the take timeout system int videoxystate[MATRIXSIZE + 1]; // Holds the current state of the video matrix int audioxystate[MATRIXSIZE + 1]; // Holds the current state of the audio matrix bool src_selected; // When set true, indicates we have a valid source selected bool dest_selected; // When set true, indicates we have a valid destination selected bool vid_enabled; // Holds the state of the video level enable/disable buttons bool aud_enabled; // Holds the state of the audio level enable/disable buttons bool undo_enabled; bool take_enabled; bool take_timer_active; bncs_string take_high, take_low; // Statesheet names for the TAKE button // Local methods void checkTake(void); // Function that checks for valid source and destination packages. Enables TAKE if appropriate. void doTake(void); // Implement the TAKE actions }; #endif // b4_xy_INCLUDED