CMSV6Help Center
/
839 DOCS · 213 VIDEOS中文

Playback software alarm file search docking

Author 谢周轩Updated 2025-10-16 14:55:50Doc ID 2380391 words · 2 min readView original ↗

1. function description

**Select alarm type to search in playback analysis software **

2. call process

The 2.1 playback software will call the AVFILE_SearchFile of the file resolution library plug- in to search for video files.
'AVFILE_API int APICALL AVFILE_SearchFile(const char szFolder, void pUsr, void (CALLBACK FUNSearchCB)(AVFILEGroup_S pGroup, void* pUsr)) ;'

The nFileType field of the AVFILEGroup_S * pGroup file information returned by 2.2 indicates the file type
nFileType bitwise represent different alarms, one file can have multiple alarms at the same time.
See AVFileDef.h header file for specific definition

2.3 playback software bitwise nFileType to match alarm type

3. Precautions

**Note: The following are the definitions of alarm types. For more information, see the AVFileDef.h header file **
// Video file alarm flag bit, which can contain multiple alarms at the same time (AVFILEGroup_S::nFileType)
-- #define AVFILE_ALARM_TYPE_ALL (0xFFFFFFFF)
-- #define AVFILE_ALARM_TYPE_NONE ((1) << 0) // Alarm file, compatible with the old version of the parsing library
-- #define AVFILE_ALARM_TYPE_1 ((1) << 1) // IO alarm
-- #define AVFILE_ALARM_TYPE_2 ((1) << 2) // Acceleration alarm
-- #define AVFILE_ALARM_TYPE_3 ((1) << 3) // Rollover alarm
-- #define AVFILE_ALARM_TYPE_4 ((1) << 4) // Collision warning
-- #define AVFILE_ALARM_TYPE_5 ((1) << 5) // Speed class alarm
-- #define AVFILE_ALARM_TYPE_6 ((1) << 6) // temperature alarm
-- #define AVFILE_ALARM_TYPE_7 ((1) << 7) // Video loss alarm
-- #define AVFILE_ALARM_TYPE_8 ((1) << 8) // disk alarm
-- #define AVFILE_ALARM_TYPE_9 ((1) << 9) // GPS abnormal alarm
-- #define AVFILE_ALARM_TYPE_10 ((1) << 10) // motion detection alarm
-- #define AVFILE_ALARM_TYPE_11 ((1) << 11) // Occlusion alarm

typedef struct _tagAVFILEGroup_S
{
char szMulFile[AVFILE_CHANNEL_COUNT][MAX_PATH]; //Number of files, tentative maximum 16 channels
int arrChannel[AVFILE_CHANNEL_COUNT]; // channel information
int nFileNum; // Number of files
SYSTEMTIME tmBegin; // start time
long nTotalMinSecond; // Total file duration // Howard 2012- 09- 20 The unit here is milliseconds!
int nFileType; // file type, regular, alarm, all
AVFILEIOName_S ioName; // IO name information

// AVFILEInfo_S file[AVFILE_CHANNEL_COUNT]; // Number of files, tentatively up to 16 channels
// AVFILEIOName_S ioName[]; // IO name information
// int nFileNum; // Number of files
// SYSTEMTIME begTime; // File start time
// int nTotalSecond; // Total file duration
// int nFileType; // file type, regular, alarm, all
} AVFILEGroup_S, * LPAVFILEGroup_S;

// Search for files
'AVFILE_API int APICALL AVFILE_SearchFile(const char szFolder, void pUsr, void (CALLBACK FUNSearchCB)(AVFILEGroup_S pGroup, void* pUsr)) ;'

Source help.cmsv7.com
839 documents · 213 videos · docs.alwaycare.com