background image

- 63 - 

2.5.17 AdvDVP_SetVideoInput 
 

Syntax 

int AdvDVP_SetVideoInput(int nDevNum, int nInput) 
 

Parameters 

nDevNum: 

Specifies the device number(0~3). 

nInput:   

A value to set video input 
mux(0~3). 

 
Return Value 

SUCCEEDED:     Function 

succeeded. 

FAILED:  

 

 

Function failed. 

SDKINITFAILED:  

SDK not initialized. 

DEVICENUMERROR: Invalid device number. 
PARAMERROR:  

 

Invalid parameter.  

 

Description 

This function sets video input mux of a specified 
capture port. 
It returns “FAILED” when argument “SwitchingChans” 
of AdvDVP_Start was set nonzero. And, the video 
input mux will be set 0 automatically when argument 
“SwitchingChans” of AdvDVP_Start was set nonzero.

 

 

 

See Also 

AdvDVP_Start

 

AdvDVP_GetVideoInput

 

Summary of Contents for DVP-7010BE

Page 1: ...DVP 7010BE 4 Channel PCI bus Surveillance Capture card ...

Page 2: ...ties which may result from its use Acknowledgments IBM and PC are trademarks of International Business Machines Corporation MS DOS Windows Microsoft Visual C and Visual BASIC are trade marks of Microsoft Corporation Intel and Pentium are trademarks of Intel Corporation Delphi and C Builder are trademarks of Inprise Corporation CE notification The DVP 7010BE developed by ADVANTECH CO LTD has passed...

Page 3: ...3 CHAPTER 1 General Information ...

Page 4: ...nput through BNC connectors and digitizes the data to PC through PCI bus The DVP 7010BE is a digital video surveillance card with SDK software develop kit It provides 4 pairs GPIO for user any kind application needs 1 1 Hardware Requirement Intel Pentium III 1GHz or above CPU speed depends on video frame rate channels and resolution 256 MB RAM or above Free PCI slot s CD ROM Hard disk with 1G free...

Page 5: ...5 1 3 Block Diagram Figure 1 1 System diagram 1 4 Packing List DVP 7010BE PCI capture card X 1 Utility CD Driver Manual SDK Sample Sample source code X 1 Connection cable for WDT X 1 ...

Page 6: ...DVP 7010BE User s Manual 6 1 5 Dimensions Figure 1 2 Dimensions ...

Page 7: ...7 1 6 Connector location Figure 1 3 connector location GPIO J1 Video input for ODM customer only ...

Page 8: ...1 GPIO J1 8 bit TTL CMOS level Digital I O GPIO J1 Pin define Pin no Description Pin 1 OUT0 Pin 2 OUT1 Pin 3 OUT2 Pin 4 OUT3 Pin 5 IN0 Pin 6 IN1 Pin 7 IN2 Pin 8 IN3 Pin 9 VCC Pin 10 GND Table 1 1 GPIO J1 pin definition Figure 1 4 GPIO J1 pin definition ...

Page 9: ...facilitate the installation of the enhanced display device drivers and utility software you should read the instructions in this chapter carefully before you attempt installation The device drivers for the DVP 7010BE board are located on the software installation CD The auto run function of the driver CD will guide and link you to the utilities and device drivers under Windows system Before you be...

Page 10: ...DVP 7010BE User s Manual 10 Installation Step 1 Pop up the System Properties window choose the Hardware page and press the Device Manager bottom ...

Page 11: ...11 Step 2 Click the PC icon and press the left bottom of the mouse Press the Scan for hardware changes ...

Page 12: ...DVP 7010BE User s Manual 12 Step 3 The system will show the un known devices like below window ...

Page 13: ...13 Step 4 Click the below icon to specify the driver location ...

Page 14: ...DVP 7010BE User s Manual 14 Step 5 Specify the driver under the CD_ROM driver ...

Page 15: ...15 Step 6 Push the Next bottom to process the installation Step 7 Continuing the installation ...

Page 16: ...DVP 7010BE User s Manual 16 Step 8 Press the Finish bottom to finish the first circle installation Then repeat the installation step 1 8 until all the un known devices are all installed ...

Page 17: ...17 Step 9 From below window we know there are 8 new items are installed ...

Page 18: ... 7010BE User s Manual 18 Installation of DVP 7010BE Demo Program Step 1 Install the DVP 7010BE demo program The executive file is in the path CD_ROM DVP 7010B 7020B SDK DVP 7010B 7020B Sample Installation ...

Page 19: ...19 Step 2 Press the Next bottom to begin the installation ...

Page 20: ...DVP 7010BE User s Manual 20 Step 3 Accept the license agreement and continue the installation ...

Page 21: ...21 Step 4 Key in your name and company name Then press the Next bottom to continue Step 5 Choose the setup type you want and next ...

Page 22: ...DVP 7010BE User s Manual 22 Step 6 Beginning the installation Step 7 Finished the installation of DVP 7010BE demo program ...

Page 23: ...4DEV exe icon on the desktop Execute the demo program 1 10 Demo Program Functionality Below is the demo program window The left side panels are the preview windows of video inputs The right side panels are the function parameter settings ...

Page 24: ...DVP 7010BE User s Manual 24 1 10 1 Device Each device is representative of one Conexant Fusion 878A video capture chip User can set different parameters to different 878A chip ...

Page 25: ...et the Switch Channels to decide how many input for each 878A video chip Each 878A chip can switch to 4 channel video inputs to share 30 25 frame per second For more information please refer to Chapter 2 5 17 AdvDVP_SetVideoInput ...

Page 26: ... the interlace effect on the video image In other words there will be lines in the capture image especially when the targeted image is moving To eliminate this effect user might need to set the resolution down to 640x240 and use specific algorisms to compensate the image interlace between the scanning even field image and odd field image For CIF 320x240 resolution there will be no interlace effect...

Page 27: ...27 ...

Page 28: ...DVP 7010BE User s Manual 28 1 10 4 Frame Rate Set the frame rate for video capturing for specific channel Please refer to Chapter 2 5 13 AdvDVP_SetFrameRate ...

Page 29: ...29 1 10 5 Video Mux Set the Video Mux to specify the video input channel for setting parameter Please refer to Chapter 2 5 16 AdvDVP_GetVideoInput ...

Page 30: ...DVP 7010BE User s Manual 30 1 10 6 Video Standard Set the video standard of your cameras Please refer to Chapter 2 5 10 AdvDVP_GetVideoFormat ...

Page 31: ...31 1 10 7 Snap Buffer Press the Snap Buffer to get the image data of specific channel video input The snap image will be show on the up panel ...

Page 32: ... of specific channel Please refer to chapter 2 5 18 AdvDVP_SetBrightness 2 5 18 AdvDVP_GetContrast 2 5 18 AdvDVP_SetContrast 2 5 18 AdvDVP_GetHue 2 5 18 AdvDVP_SetHue 2 5 18 AdvDVP_GetSaturation 2 5 18 AdvDVP_SetSaturation 1 10 9 GPIO control To get a specified DI value or to set a specified DO value ...

Page 33: ...CHAPTER 2 Software Function Library CHAPTER ...

Page 34: ... and close AdvDVP_CreateSDKInstence Creates SDK instance AdvDVP_InitSDK Initializes the SDK AdvDVP_CloseSDK Closes up the SDK Capture control AdvDVP_GetNoOfDevices Gets number of video capture devices AdvDVP_Start Starts video capturing AdvDVP_Stop Stops video capturing AdvDVP_GetCapState Gets capture state AdvDVP_SetNewFrameCallback Sets a callback function to SDK AdvDVP_GetCurFrameBuffer Gets cu...

Page 35: ...oInput Gets video input mux AdvDVP_SetVideoInput Sets video input mux Sensor Control AdvDVP_GetBrightness Gets brightness value AdvDVP_SetBrightness Sets brightness value AdvDVP_GetContrast Gets contrast value AdvDVP_SetContrast Sets contrast value AdvDVP_GetHue Gets hue value AdvDVP_SetHue Sets hue value AdvDVP_GetSaturation Gets saturation value AdvDVP_SetSaturation Sets saturation value GPIO Ad...

Page 36: ...DVP 7010BE User s Manual 36 GPIO pin ...

Page 37: ...m Read End function pointer STREAMREAD_STRUCT The structure stores the Stream Read callback function pointers 2 2 2 Method Summary SDK Initialize and close AdvDVP_CreateEncSDKInstence Creates encoding SDK instance AdvDVP_InitSDK Initializes the SDK AdvDVP_CloseSDK Closes up the SDK AdvDVP_InitEncoder Opens and initializes video encoder AdvDVP_CloseEncoder Closes and release video encoder Encode co...

Page 38: ...DVP_GetVideoFrameRate Gets video encoding frame rate AdvDVP_SetVideoFrameRate Sets video encoding frame rate AdvDVP_GetVideoResolution Gets video encoding resolution AdvDVP_SetVideoResolution Sets video encoding resolution AdvDVP_GetVideoKeyInterval Gets video encoding key interval AdvDVP_SetVideoKeyInterval Sets video encoding key interval ...

Page 39: ...lly You can install the codec manually by using the rmp4 inf file Right click on the file and then click Install 2 3 1 Data Type Summary PlayerRes The method returned code 2 3 2 Method Summary Playback SDK initialize AdvDVP_CreatePlayerSDKInstence Creates Player SDK instance Playback control AdvDVP_OpenFile Opens file and initialize player AdvDVP_CloseFile Closes file that has been opened AdvDVP_P...

Page 40: ...that is rendered AdvDVP_RegNotifyMsg Registers message sent to player when event occurs AdvDVP_CheckFileEnd Checks if file is finished playing Playback setting AdvDVP_GetVideoResolution Gets video resolution of file AdvDVP_GetFileTime Gets total file time AdvDVP_GetPlayedTime Gets current file time AdvDVP_SetPlayPosition Locates position of file AdvDVP_GetFileTotalFrames Gets total frame number of...

Page 41: ... 41 number of file AdvDVP_GetPlayRate Gets current played rate ...

Page 42: ...2 4 DVP7010B 7020B Functions Reference Data Type 2 4 1 Res Syntax typedef enum tagRes SUCCEEDED 1 FAILED 0 SDKINITFAILED 1 PARAMERROR 2 NODEVICES 3 NOSAMPLE 4 DEVICENUMERROR 5 INPUTERROR 6 Res Description The method returned code ...

Page 43: ...DKInstence Syntax int AdvDVP_CreateSDKInstence void pp Parameters pp A pointer to the SDK instance Return Value SUCCEEDED Function succeeded FAILED Function failed PARAMERROR Parameter error Description This function creates SDK instance ...

Page 44: ...alue SUCCEEDED Function succeeded FAILED Function failed NODEVICES No devices found Description This function initializes all video capture devices in the system After initializing each device the capture status would be set as STOPPED See Also AdvDVP_GetNoOfDevices AdvDVP_GetCapState AdvDVP_CloseSDK ...

Page 45: ...ax int AdvDVP_CloseSDK void Parameters None Return Value SUCCEEDED Function succeeded SDKINITFAILED SDK not initialized Description This function cleans all instances of capture devices and closes up the SDK See Also AdvDVP_InitSDK ...

Page 46: ...VP_GetNoOfDevices int pNoOfDevs Parameters pNoOfDevs A pointer to get number of video capture devices Return Value SUCCEEDED Function succeeded FAILED Function failed SDKINITFAILED SDK not initialized Description This function gets number of video capture devices in the system ...

Page 47: ...mux2 mux3 Main A main window handle hwndPreview A windows handle for display area This parameter is only valid when the SwitchChans is zero When the value of this parameter is NULL the video will not be rendered Return Value SUCCEEDED Function succeeded FAILED Function failed SDKINITFAILED SDK not initialized DEVICENUMERROR Invalid device number Description This function starts video capturing on ...

Page 48: ...DVP 7010BE User s Manual 48 SwitchingChans 0 the video input mux will be set 0 See Also AdvDVP_Stop AdvDVP_GetCapState ...

Page 49: ...rn Value SUCCEEDED Function succeeded FAILED Function failed SDKINITFAILED SDK not initialized DEVICENUMERROR Invalid device number Description This function stops video capturing on a specified capture port The capture state would be set as STOPPED after a successful stop See Also AdvDVP_Start AdvDVP_GetCapState ...

Page 50: ...um Specifies the device number 0 3 Return Value DEVICENUMERROR Invalid device number SDKINITFAILED SDK not initialized Description This function gets capture state of a specified capture port typedef enum STOPPED 1 RUNNING 2 UNINITIALIZED 1 UNKNOWNSTATE 2 CapState See Also AdvDVP_InitSDK AdvDVP_Start AdvDVP_Stop ...

Page 51: ...uffer size buf Frame buffer VMux Video mux Return Value SUCCEEDED Function succeeded FAILED Function failed SDKINITFAILED SDK not initialized DEVICENUMERROR Invalid device number PARAMERROR Invalid parameter NOSAMPLE No buffer sample Description This function gets current frame buffer of a specified capture port Start capturing before the function is called See Also AdvDVP_Start ...

Page 52: ...nt nDevNum int VMux int bufsize BYTE buf nID Single video input ID or the video mux ID The value of IDs is showed as following define ID_NEW_FRAME 37810 define ID_MUX0_NEW_FRAME 37800 define ID_MUX1_NEW_FRAME 37801 define ID_MUX2_NEW_FRAME 37802 define ID_MUX3_NEW_FRAME 37803 nDevNum Specifies the device number 0 3 VMux Specifies the video mux number 0 3 bufsize An integer pointer of the frame buf...

Page 53: ...eded SDKINITFAILED SDK not initialized DEVICENUMERROR Invalid device number Description This function sets a callback function to SDK When new frame arrived messages and frame information will be sent to callback function See Also ...

Page 54: ...deo_None 0x00000000 Video_NTSC_M 0x00000001 Video_NTSC_M_J 0x00000002 Video_PAL_B 0x00000010 Video_PAL_M 0x00000200 Video_PAL_N 0x00000400 Video_SECAM_B 0x00001000 AnalogVideoFormat Return Value SUCCEEDED Function succeeded FAILED Function failed SDKINITFAILED SDK not initialized DEVICENUMERROR Invalid device number PARAMERROR Invalid parameter Description This function gets video input format of ...

Page 55: ...00 Video_NTSC_M 0x00000001 Video_NTSC_M_J 0x00000002 Video_PAL_B 0x00000010 Video_PAL_M 0x00000200 Video_PAL_N 0x00000400 Video_SECAM_B 0x00001000 AnalogVideoFormat Return Value SUCCEEDED Function succeeded FAILED Function failed SDKINITFAILED SDK not initialized DEVICENUMERROR Invalid device number Description This function sets video input format a specified capture port This function should be ...

Page 56: ...DVP 7010BE User s Manual 56 AdvDVP_GetVideoFormat ...

Page 57: ...evice number 0 3 FrameRate A pointer to get video frame rate Return Value SUCCEEDED Function succeeded FAILED Function failed SDKINITFAILED SDK not initialized DEVICENUMERROR Invalid device number PARAMERROR Invalid parameter Description This function gets frame rate of a specified capture port See Also AdvDVP_SetFrameRate ...

Page 58: ... channels mux0 mux1 2 three channels mux0 mux1 mux2 3 four channels mux0 mux1 mux2 mux3 FrameRate A value to set frame rate 0 FrameRate 30 Default value is 30 Return Value SUCCEEDED Function succeeded FAILED Function failed SDKINITFAILED SDK not initialized DEVICENUMERROR Invalid device number PARAMERROR Invalid parameter Description This function sets frame rate of a specified capture port This f...

Page 59: ... 59 SwitchingChans 0 the frame rate must be set 30 Otherwise the function will return PARAMERROR See Also AdvDVP_GetFrameRate ...

Page 60: ...on typedef enum FULLPAL 0 PAL 768x576 SIZED1 NTSC 720x480 PAL 720x576 SIZEVGA 640x480 SIZEQVGA 320x240 SIZESUBQVGA 160x120 VideoSize Return Value SUCCEEDED Function succeeded FAILED Function failed SDKINITFAILED SDK not initialized DEVICENUMERROR Invalid device number PARAMERROR Invalid parameter Description This function gets video resolution of a specified capture port See Also AdvDVP_SetResolut...

Page 61: ...0 PAL 768x576 SIZED1 NTSC 720x480 PAL 720x576 SIZEVGA 640x480 SIZEQVGA 320x240 SIZESUBQVGA 160x120 VideoSize Return Value SUCCEEDED Function succeeded FAILED Function failed SDKINITFAILED SDK not initialized DEVICENUMERROR Invalid device number Description This function sets video resolution of a specified capture port This function should be called before AdvDVP_Start See Also AdvDVP_GetResolutio...

Page 62: ...ceeded FAILED Function failed SDKINITFAILED SDK not initialized DEVICENUMERROR Invalid device number PARAMERROR Invalid parameter Description This function gets video input mux of a specified capture port It returns FAILED when argument SwitchingChans of AdvDVP_Start was set nonzero And the video input mux will be set 0 automatically when argument SwitchingChans of AdvDVP_Start was set nonzero See...

Page 63: ...ED Function failed SDKINITFAILED SDK not initialized DEVICENUMERROR Invalid device number PARAMERROR Invalid parameter Description This function sets video input mux of a specified capture port It returns FAILED when argument SwitchingChans of AdvDVP_Start was set nonzero And the video input mux will be set 0 automatically when argument SwitchingChans of AdvDVP_Start was set nonzero See Also AdvDV...

Page 64: ... 1 3 This value must be set 1 when no switching channels lpValue A long pointer to get brightness value Return Value SUCCEEDED Function succeeded FAILED Function failed SDKINITFAILED SDK not initialized DEVICENUMERROR Invalid device number PARAMERROR Invalid parameter INPUTERROR Invalid video input mux Description This function gets brightness value of a specified capture port See Also AdvDVP_SetB...

Page 65: ...is value must be set 1 when no switching channels lValue A value to set brightness 0 100 Return Value SUCCEEDED Function succeeded FAILED Function failed SDKINITFAILED SDK not initialized DEVICENUMERROR Invalid device number PARAMERROR Invalid parameter INPUTERROR Invalid video input mux Description This function sets brightness value of a specified capture port See Also AdvDVP_GetBrightness ...

Page 66: ...mux 1 3 This value must be set 1 when no switching channels lpValue A long pointer to get contrast value Return Value SUCCEEDED Function succeeded FAILED Function failed SDKINITFAILED SDK not initialized DEVICENUMERROR Invalid device number PARAMERROR Invalid parameter INPUTERROR Invalid video input mux Description This function gets contrast value of a specified capture port See Also AdvDVP_SetCo...

Page 67: ... 3 This value must be set 1 when no switching channels lValue A value to set contrast 0 100 Return Value SUCCEEDED Function succeeded FAILED Function failed SDKINITFAILED SDK not initialized DEVICENUMERROR Invalid device PARAMERROR Invalid parameter INPUTERROR Invalid video input mux Description This function sets contrast value of a specified capture port See Also AdvDVP_GetContrast ...

Page 68: ...t mux 1 3 This value must be set 1 when no switching channels lpValue A long pointer to get hue value Return Value SUCCEEDED Function succeeded FAILED Function failed SDKINITFAILED SDK not initialized DEVICENUMERROR Invalid device number PARAMERROR Invalid parameter INPUTERROR Invalid video input mux Description This function gets hue value of a specified capture port See Also AdvDVP_SetHue ...

Page 69: ...3 This value must be set 1 when no switching channels lValue A value to set hue 0 100 Return Value SUCCEEDED Function succeeded FAILED Function failed SDKINITFAILED SDK not initialized DEVICENUMERROR Invalid device number PARAMERROR Invalid parameter INPUTERROR Invalid video input mux Description This function sets hue value of a specified capture port See Also AdvDVP_GetHue ...

Page 70: ...ux 1 3 This value must be set 1 when no switching channels lpValue A long pointer to get saturation value Return Value SUCCEEDED Function succeeded FAILED Function failed SDKINITFAILED SDK not initialized DEVICENUMERROR Invalid device number PARAMERROR Invalid parameter INPUTERROR Invalid video input mux Description This function gets saturation value of a specified capture port See Also AdvDVP_Se...

Page 71: ...is value must be set 1 when no switching channels lValue A value to set saturation 0 100 Return Value SUCCEEDED Function succeeded FAILED Function failed SDKINITFAILED SDK not initialized DEVICENUMERROR Invalid device number PARAMERROR Invalid parameter INPUTERROR Invalid video input mux Description This function sets saturation value of a specified capture port See Also AdvDVP_GetSaturation ...

Page 72: ...ecifies the digital input number 0 3 pValue A pointer to get the value of the specified digital input Return Value SUCCEEDED Function succeeded FAILED Function failed SDKINITFAILED SDK not initialized PARAMERROR Invalid parameter Description This function gets the value of the specified digital input See Also AdvDVP_GPIOSetData ...

Page 73: ...igital output number 0 3 bValue A value to set the value of the specified digital output Return Value SUCCEEDED Function succeeded FAILED Function failed SDKINITFAILED SDK not initialized PARAMERROR Invalid parameter Description This function sets the value of the specified digital output See Also AdvDVP_GPIOGetData ...

Page 74: ...0B Encoding Functions Reference Data Type 2 6 1 EncRes Syntax typedef enum tagRes ENC_SUCCEEDED 1 ENC_FAILED 0 ENC_SDKINITFAILED 1 ENC_ENCINITFAILED 2 ENC_PARAMERROR 3 ENC_ENCNUMERROR 4 ENC_BUFFERFULL 5 EncRes Description The method returned code ...

Page 75: ...d PSTREAMREADBEGIN int nEncNum Parameters nEncNum Specifies the encoder number Return Value None Description The pointer to the Stream Read Begin callback function called when begins the video stream read process See Also STREAMREAD_STRUCT ...

Page 76: ...encoded video frame lBufSize Specifies the size of the encoded video frame dwCompFlags Specifies if this encoded video frame is I frame The AVIIF_KEYFRAME value means the frame is I frame define AVIIF_KEYFRAME 0x00000010L Return Value None Description The pointer to the Stream Read Process callback function called after every video frame is encoded User can use this function to get every encoded v...

Page 77: ...PSTREAMREADEND int nEncNum Parameters nEncNum Specifies the encoder number Return Value None Description The pointer to the Stream Read End callback function called when the video stream read process is finished See Also STREAMREAD_STRUCT ...

Page 78: ...ADEND int nEncNum STREAMREAD_STRUCT Parameters PSTREAMREADBEGIN The pointer to the Stream Read Begin callback function called when begins the video stream read process PSTREAMREADPROC The pointer to the Stream Read Process callback function called after every video frame is encoded PSTREAMREADEND The pointer to the Stream Read End callback function called when the video stream read process is fini...

Page 79: ... 79 This structure stores the Stream Read callback function pointers See Also PSTREAMREADBEGIN PSTREAMREADPROC PSTREAMREADEND AdvDVP_SetStreamReadCB ...

Page 80: ...tence Syntax int AdvDVP_CreateEncSDKInstence void pp Parameters pp A pointer to the encoding SDK instance Return Value ENC_SUCCEEDED Function succeeded ENC_FAILED Function failed ENC_PARAMERROR Parameter error Description This function creates the encoding SDK instance ...

Page 81: ... AdvDVP_InitSDK Syntax int AdvDVP_InitSDK void Parameters None Return Value ENC_SUCCEEDED Function succeeded Description This function initializes all parameters of the SDK in the system See Also AdvDVP_CloseSDK ...

Page 82: ...tax int AdvDVP_CloseSDK void Parameters None Return Value ENC_SUCCEEDED Function succeeded ENC_SDKINITFAILED SDK does not be initialized successfully Description This function cleans all parameters of the SDK and closes up the SDK See Also AdvDVP_InitSDK ...

Page 83: ...ffer size Return Value ENC_SUCCEEDED Function succeeded ENC_FAILED Function failed ENC_SDKINITFAILED SDK does not be initialized successfully ENC_ENCNUMERROR Invalid encoder number Description This function opens and initializes the specified video encoder After initializing the encoder the encoding state would be set as ENC_STOPPED See Also AdvDVP_CloseEncoder AdvDVP_GetState ...

Page 84: ...NC_FAILED Function failed ENC_SDKINITFAILED SDK does not be initialized successfully ENC_ENCNUMERROR Invalid encoder number ENC_ENCINITFAILED Encoder does not be initialized successfully Description This function closes and releases the specified video encoder After successfully calling this function the encoding state would be set as ENC_UNINITIALIZED See Also AdvDVP_InitEncoder AdvDVP_GetState ...

Page 85: ...failed ENC_SDKINITFAILED SDK does not be initialized successfully ENC_ENCNUMERROR Invalid encoder number ENC_ENCINITFAILED Encoder does not be initialized successfully Description This function notifies the specified video encoder to prepare to encode the video The encode state would be set as ENC_RUNNING after a successful beginning See Also AdvDVP_VideoEncode AdvDVP_StopVideoEncode AdvDVP_GetSta...

Page 86: ...InBufSize Specifies the size of the input buffer bKeyFrame Specifies if the video frame is encoded as a I frame Return Value ENC_SUCCEEDED Function succeeded ENC_FAILED Function failed ENC_SDKINITFAILED SDK does not be initialized successfully ENC_ENCNUMERROR Invalid encoder number ENC_ENCINITFAILED Encoder does not be initialized successfully ENC_PARAMERROR Parameter error ENC_BUFFERFULL Encoding...

Page 87: ... 87 buffer Description This function writes the video frame to the encoding buffer to encode it by the specified encoder See Also AdvDVP_StartVideoEncode AdvDVP_StopVideoEncode ...

Page 88: ...failed ENC_SDKINITFAILED SDK does not be initialized successfully ENC_ENCNUMERROR Invalid encoder number ENC_ENCINITFAILED Encoder does not be initialized successfully Description This function notifies the specified video encoder to stop encoding and releases all relational resources The encoding state would be set as ENC_STOPPED after a successful stop See Also AdvDVP_StartVideoEncode AdvDVP_Vid...

Page 89: ...number 0 15 Return Value ENC_ENCNUMERROR Invalid encoder number Description This function gets encoding state of a specified video encoder typedef enum ENC_STOPPED 1 ENC_RUNNING 2 ENC_UNINITIALIZED 1 EncoderState See Also AdvDVP_InitEncoder AdvDVP_CloseEncoder AdvDVP_StartVideoEncode AdvDVP_StopVideoEncode ...

Page 90: ...B STREAMREAD_STRU CT pStreamRead Parameters pStreamRead A pointer to STREAMREAD_STRUCT structure recording the pointers to the StreamRead callback functions Return Value None Description This function registers the Stream Read callback functions to the SDK See Also STREAMREAD_STRUCT structure ...

Page 91: ...eturn Value ENC_SUCCEEDED Function succeeded ENC_FAILED Function failed ENC_SDKINITFAILED SDK does not be initialized successfully ENC_ENCNUMERROR Invalid encoder number ENC_ENCINITFAILED Encoder does not be initialized successfully Description This function gets video quant of the specified video encoder The lower video quant can get the compressed video with higher quality and bit rate vice vers...

Page 92: ...lity is 4 Return Value ENC_SUCCEEDED Function succeeded ENC_FAILED Function failed ENC_SDKINITFAILED SDK does not be initialized successfully ENC_ENCNUMERROR Invalid encoder number ENC_ENCINITFAILED Encoder does not be initialized successfully Description This function sets video quant of the specified video encoder The lower video quant can get the compressed video with higher quality and bit rat...

Page 93: ...to get the video frame rate Return Value ENC_SUCCEEDED Function succeeded ENC_FAILED Function failed ENC_SDKINITFAILED SDK does not be initialized successfully ENC_ENCNUMERROR Invalid encoder number ENC_ENCINITFAILED Encoder does not be initialized successfully Description This function gets video frame rate of the specified video encoder See Also AdvDVP_SetVideoFrameRate ...

Page 94: ...o frame rate The range is 1 30 The default video frame rate is 30 Return Value ENC_SUCCEEDED Function succeeded ENC_FAILED Function failed ENC_SDKINITFAILED SDK does not be initialized successfully ENC_ENCNUMERROR Invalid encoder number ENC_ENCINITFAILED Encoder does not be initialized successfully Description This function sets video frame rate of the specified video encoder See Also AdvDVP_GetVi...

Page 95: ...e width of the video nHeight A pointer to get the height of the video Return Value ENC_SUCCEEDED Function succeeded ENC_SDKINITFAILED SDK does not be initialized successfully ENC_ENCNUMERROR Invalid encoder number ENC_ENCINITFAILED Encoder does not be initialized successfully Description This function gets video resolution of the specified video encoder See Also AdvDVP_SetVideoResolution ...

Page 96: ...fault width is 320 nHeight A value to set the height of the video The default height is 240 Return Value ENC_SUCCEEDED Function succeeded ENC_FAILED Function failed ENC_SDKINITFAILED SDK does not be initialized successfully ENC_ENCNUMERROR Invalid encoder number ENC_ENCINITFAILED Encoder does not be initialized successfully Description This function sets video resolution of the specified video enc...

Page 97: ...erval of the video key frame Return Value ENC_SUCCEEDED Function succeeded ENC_FAILED Function failed ENC_SDKINITFAILED SDK does not be initialized successfully ENC_ENCNUMERROR Invalid encoder number ENC_ENCINITFAILED Encoder does not be initialized successfully Description This function gets the interval of the video key frame of the specified video encoder See Also AdvDVP_SetVideoKeyInterval ...

Page 98: ...deo key frame The range is 1 99 The default video frame rate is 60 Return Value ENC_SUCCEEDED Function succeeded ENC_FAILED Function failed ENC_SDKINITFAILED SDK does not be initialized successfully ENC_ENCNUMERROR Invalid encoder number ENC_ENCINITFAILED Encoder does not be initialized successfully Description This function sets the interval of the video key frame of the specified video encoder S...

Page 99: ...ileName Specifies the file name of the AVI file nWidth nHeight nFrameRate Specifies the frame rate of the video Return Value If the function succeeds the file handle is returned Otherwise the function returns NULL Description This function creates the AVI file to save the encoded video stream See Also AdvDVP_WriteAVIFile AdvDVP_CloseAVIFile ...

Page 100: ...lBufSize Specifies the size of the video stream data buffer dwCompFlags Flag associated with this data The AVIIF_KEYFRAME flag is defined to indicate this data does not rely on preceding data in the file define AVIIF_KEYFRAME0x00000010L Return Value ENC_SUCCEEDED Function succeeded ENC_FAILED Function failed ENC_SDKINITFAILED SDK does not be initialized successfully Description This function write...

Page 101: ... 101 AdvDVP_CloseAVIFile ...

Page 102: ...hAVIFile Parameters hAVIFile Specifies the AVI file handle Return Value ENC_SUCCEEDED Function succeeded ENC_FAILED Function failed ENC_SDKINITFAILED SDK does not be initialized successfully Description This function closes the specified AVI file See Also AdvDVP_CreateAVIFile AdvDVP_WriteAVIFile ...

Page 103: ...010B 7020B Player Functions Reference Data Type 2 8 1 PlayerRes Syntax typedef enum tagRes PLAYER_SUCCEEDED 1 PLAYER_FAILED 0 PLAYER_SDKINITFAILED 1 PLAYER_PARAMERROR 2 PlayerRes Description The method returned code ...

Page 104: ...ence Syntax int AdvDVP_CreatePlayerSDKInstence void pp Parameters pp A pointer to the player SDK instance Return Value PLAYER_SUCCEEDED Function succeeded PLAYER_FAILED Function failed PLAYER_PARAMERROR Parameter error Description This function creates playback SDK instance ...

Page 105: ...f the source video file Return Value PLAYER_SUCCEEDED Function succeeded PLAYER_FAILED Function failed Description This function opens the source video file and initializes the video player The playback status would be set as PLAYER_STOPPED after successfully calling this function See Also AdvDVP_CloseFile AdvDVP_GetStatus ...

Page 106: ...lue PLAYER_SUCCEEDED Function succeeded PLAYER_FAILED Function failed Description This function closes the source video file and free resources allocated for video player The playback status would be set as PLAYER_NOTOPENED after successfully calling this function See Also AdvDVP_OpenFile AdvDVP_GetStatus ...

Page 107: ... the display area is resized automatically according to the video resolution Return Value PLAYER_SUCCEEDED Function succeeded PLAYER_FAILED Function failed Description This function plays the file that has been opened The playback status would be set as PLAYER_PLAYING after successfully calling this function See Also AdvDVP_Pause AdvDVP_Stop AdvDVP_GetStatus ...

Page 108: ...urn Value PLAYER_SUCCEEDED Function succeeded PLAYER_FAILED Function failed Description This function pauses or continues the file that has been opened The playback status would be set as PLAYER_PAUSED after successfully calling this function See Also AdvDVP_Play AdvDVP_Stop AdvDVP_GetStatus ...

Page 109: ...Value PLAYER_SUCCEEDED Function succeeded PLAYER_FAILED Function failed Description This function stops the file that is playing The playback status would be set as PLAYER_STOPPED after successfully calling this function See Also AdvDVP_Play AdvDVP_Pause AdvDVP_GetStatus ...

Page 110: ...YER_SUCCEEDED Function succeeded PLAYER_FAILED Function failed Description This function improves the current play speed by one time 4 times at most The playback status would be set as PLAYER_PLAYING after successfully calling this function See Also AdvDVP_Pause AdvDVP_Stop AdvDVP_Slow AdvDVP_GetStatus ...

Page 111: ...DED Function succeeded PLAYER_FAILED Function failed Description This function slows the current play speed by one time 4 times at most The playback status would be set as PLAYER_PLAYING after successfully calling this function See Also AdvDVP_Pause AdvDVP_Stop AdvDVP_Fast AdvDVP_GetStatus ...

Page 112: ...one Return Value PLAYER_SUCCEEDED Function succeeded PLAYER_FAILED Function failed Description This function makes the video to step forward one frame The playback status would be set as PLAYER_PAUSED after successfully calling this function See Also AdvDVP_Pause AdvDVP_Stop AdvDVP_GetStatus ...

Page 113: ... PLAYER_FAILED Function failed Description This function gets playback status typedef enum tagPlayerStatus PLAYER_NOTOPENED 0 PLAYER_OPENED 1 PLAYER_PLAYING 2 PLAYER_STOPPED 3 PLAYER_PAUSED 4 PlayerStatus See Also AdvDVP_OpenFile AdvDVP_CloseFile AdvDVP_Play AdvDVP_Pause AdvDVP_Stop AdvDVP_Fast AdvDVP_Slow AdvDVP_PlayStep ...

Page 114: ...ge LPBYTE lpImage long pBufSize Parameters lpImage A pointer to a image buffer pBufSize A long pointer to receive the returned image buffer size Return Value PLAYER_SUCCEEDED Function succeeded PLAYER_FAILED Function failed Description This function gets current played image See Also ...

Page 115: ...sage When this message is received it means some event of the playback occur such as the file playing is end Return Value PLAYER_SUCCEEDED Function succeeded PLAYER_FAILED Function failed Description This function registers a user define message When an event of the playback occurs this message will be sent to the specified window This function must be called after AdvDVP_OpenFile function ...

Page 116: ...DVP 7010BE User s Manual 116 See Also AdvDVP_CheckFileEnd ...

Page 117: ...DVP_CheckFileEnd Parameters None Return Value If the event that the file playing end is detected this function returns TRUE Otherwise the function returns FALSE Description This function checks if the file playing is end See Also AdvDVP_RegNotifyMsg ...

Page 118: ...int nWidth int nHeight Parameters nWidth An integer pointer to get the width of the video nHeight An integer pointer to get the height of the video Return Value PLAYER_SUCCEEDED Function succeeded PLAYER_FAILED Function failed Description This function gets width and the height of the video See Also ...

Page 119: ...uble AdvDVP_GetPlayRate Parameters None Return Value If the function succeeded the playback ratio is returned Otherwise the function returns 0 Description This function retrieves the playback rate See Also AdvDVP_Play AdvDVP_Fast AdvDVP_Slow ...

Page 120: ... double AdvDVP_GetFileTime Parameters None Return Value If the function succeeded the total file time is returned Otherwise the function returns 0 Description This function retrieves total file time in seconds See Also AdvDVP_GetPlayedTime AdvDVP_SetPlayPosition ...

Page 121: ...P_GetPlayedTime Parameters None Return Value If the function succeeded the current file time is returned Otherwise the function returns 0 Description This function retrieves current file time in seconds See Also AdvDVP_GetFileTime AdvDVP_SetPlayPosition ...

Page 122: ..._SetPlayPosition double dTime Parameters dTime Specifies the file time in seconds Return Value PLAYER_SUCCEEDED Function succeeded PLAYER_FAILED Function failed Description This function seeks the file to the specified file time See Also AdvDVP_GetFileTime AdvDVP_GetPlayedTime ...

Page 123: ...tFileTotalFrames Parameters None Return Value If the function succeeded the total number of the frame of the file is returned Otherwise the function returns 0 Description This function retrieves total number of the frame of the file See Also AdvDVP_GetPlayedFrames ...

Page 124: ...NGLONG AdvDVP_GetPlayedFrames Parameters None Return Value If the function succeeded the current frame number of the file is returned Otherwise the function returns 0 Description This function retrieves current frame number of the file See Also AdvDVP_GetFileTotalFrames ...

Reviews: