Changeset 1890
- Timestamp:
- 06/02/12 02:37:43 (12 months ago)
- Location:
- trunk/core
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/core/gui.c
r1874 r1890 1983 1983 { 1984 1984 --show_md_grid; 1985 if (module_mdetect_load()) 1985 // If motion detect library loaded then display the MD grid 1986 // Don't call 'module_mdetect_load' here as we don't want to load 1987 // the module, just see if it was already loaded. 1988 if (libmotiondetect) 1986 1989 libmotiondetect->md_draw_grid(); 1987 1990 } -
trunk/core/modules.c
r1810 r1890 164 164 } 165 165 166 void module_mdetect_unload() 167 { 168 if (libmotiondetect) 169 { 170 module_unload(MODULE_NAME_MDETECT); 171 libmotiondetect = 0; 172 } 173 } 174 166 175 167 176 /************* DYNAMIC LIBRARY ZEBRA ******/ -
trunk/core/motion_detector.h
r1693 r1890 119 119 extern struct libmotiondetect_sym* libmotiondetect; 120 120 extern struct libmotiondetect_sym* module_mdetect_load(); // 0fail, addr-ok 121 extern void module_mdetect_unload(); 121 122 #else 122 123 // This section is for module -
trunk/core/script.c
r1722 r1890 612 612 break; 613 613 case AS_MOTION_DETECTOR: 614 if (module_mdetect_load()) 614 // If motion detect module loaded then run the MD code 615 // Don't call module_mdetect_load here as it may cause the 616 // module to be re-loaded after the script is interrupted 617 if (libmotiondetect) 615 618 { 616 619 if (libmotiondetect->md_detect_motion()==0) … … 717 720 } 718 721 // If motion detect library loaded then shut down motion detector 719 // Don't call 'module_mdetect_load' here as we don't want to load 720 // the module, just see if it was already loaded. 721 if (libmotiondetect) 722 libmotiondetect->md_close_motion_detector(); 722 module_mdetect_unload(); 723 723 724 shot_histogram_set(0); 724 725 kbd_key_release_all();
Note: See TracChangeset
for help on using the changeset viewer.