版本/作者/日期 | 修改内容 |
---|---|
1.0/Sandy/2015-09-24 | 初版 |
7.TF卡录像播放
-(int)playRecord:(int)record_id filePath:(NSString*)filePath; //播放tf卡录像文件 参数:(int)record_id:固定为0 (NSString*)filePath:录像文件路径 -(void)stopPlayRecord; //停止播放录像
FOUNDATION_EXPORT NSString* const IPCamera_PlayRecord_Status_Changed_Notification; //录像播放状态改变 FOUNDATION_EXPORT NSString* const IPCamera_PlayRecord_Notify_Notification; //录像播放通知
(void)IPCamera_response_function:(NSNotification*)note;
#define ADD_IPCAMERA_RESPONSE_WITHOUT_ARG(notice_name) \ [[NSNotificationCenter defaultCenter] addObserver: self selector: @selector(IPCamera_response_function:) name: notice_name object: nil] #define ADD_IPCAMERA_RESPONSE_WITH_ARG(notice_name,camera_object) \ [[NSNotificationCenter defaultCenter] addObserver: self selector: @selector(IPCamera_response_function:) name: notice_name object: camera_object]
ADD_IPCAMERA_RESPONSE_WITH_ARG( IPCamera_PlayRecord_Status_Changed_Notification, cam_) ADD_IPCAMERA_RESPONSE_WITH_ARG( IPCamera_PlayRecord_Notify_Notification, cam_)
[cam_ playRecord:0 filePath: recordpath];
[cam_ stopPlayRecord];
-(void)IPCamera_response_function:(NSNotification*)note { if( [note.name isEqualToString:IPCamera_PlayRecord_Status_Changed_Notification ]) { NSLog(@"播放录像状态改变"); } if( [note.name isEqualToString:IPCamera_PlayRecord_Notify_Notification ]) { NSLog(@"开始播放通知"); } }