Home
API Manual - 1stVision
Contents
1. value to write RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function can be used to read 32 bit data from the configuration ROM address specified in IEEE 1394 1995 and IEEE 1394 2000 and the Camera Control Register described in IIDC V1 30 With this function you can write only 32 bit data at once 84 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 7 For previous version user API Version 1 4 x x The API has been changed to support compilers other than Microsoft Visual C For convenience of the users using previous version we named the new function as follows 7 1 Naming conventions In the previous version we export ICamera class itself but from the version 2 0 we export only the member function of the previous ICamera class as follows Camera Member Function is changed to ImCam MemberFunction ex ICamera Open gt ImCamOpen ex ICamera 0 Open gt ImCamOpen 0 7 2 Return values of the functions The most return value of the function is changed to BOOL which is indicating success or fail Please check the return value of the functions 7 3 Enum type We don t use enum type any more IMC_VIDEO_FORMAT enum type is changed to define values in ImCamDef h The elements have same value to the previous version Change the IMC_VIDE_FORMAT to INT IMC_VIDEO_MODE enum type is changed to define values in ImCamDef h The elements have same
2. Else mirror effect is disabled REMARKS 73 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 8 3 ImCamSetFlip DEFINITION BOOL ImCamSetFlip IN INT nCamIndex IN BOOL bFlip PARAMETERS nCamindex index of the camera to control bFlip flag for setting flip effect RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS When using flip effect frame rate can be reduced because the calculated volume of the CPU becomes much larger Flip effect can be used only if user calls ImCamOpen with IMC_GRAB_RGB888 74 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 8 4 ImCamGetFlip DEFINITION BOOL ImCamGetFlip IN INT nCamindex PARAMETERS nCamindex index of the camera to control RETURN VALUE IMC_SUCCESS flip effect is enabled Else flip effect is disabled REMARKS 75 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 8 5 ImCamSetNegative DEFINITION BOOL ImCamSetNegative IN INT nCamindex IN BOOL bNegative PARAMETERS nCamindex index of the camera to control bNegative flag for setting negative effect RETURN VALUE IMC_SUCCESS success Else fail REMARKS When using this effect frame rate can be reduced because the calculated volume of the CPU becomes much larger Negative effect can be used only if user calls ImCamOpen
3. and frame rate For example consider the situation where a camera has 2 formats 4 modes and frame rates like as follows To decide what format should be out from the camera user should select the format first And user selects one mode supported by the format selected and selects frame rate supported by the mode selected sequentially IMC_FORMAT_Y800 IMC_MODE_ 640x480 IMC_MODE_1024x768 IMC_FRATE_3_75 IMC_FRATE_7 5 IMC_FRATE_15 IMC_FORMAT_Y422 IMC_MODE_ 640x480 IMC_MODE_1024x768 21 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 3 1 ImCamGetFormatList DEFINITION BOOL ImCamGetFormatList IN INT nCamindex IN OUT INT pnListSize OUT INT pFormat PARAMETERS nCamindex index of the camera to get the format list supported nListSize number of the valid format in the list This value should be set to the count of the pFormat array when calling this function pFormat format list supported by the selected camera RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function is used to get the list of the format supported by the camera The pnListSize value should be 6 at least when call this function If this value is smaller than the format supported by the camera this function will return error The relation between the format value provided by the API and the real camera data format is like as follows and these values are defined in the ImCamDef h header f
4. dida 67 670 lmCamGet Max TA AAA oui ni aoa dean Senda omens 68 TOCA ad a ES 69 6 7 7F TmCamS etCurrent Area di 70 6 8 IMAGE EFFECT FUNCTIONG a a aaa aa aAa a aaa aaa aa aa a aa oaa o nih suka aia aia raia 71 6 8 1 dinGams MO di ae 72 6 8 2 MCAMESAMITOD A A A A A ASS 73 O a 74 BS A NN T5 6 8 MCIMSAN de had a a a e do a E 76 Roa iaa erna LEANE a ve AATA A 77 6 9 TRIGGER FUNCTIONS saranin aenea auian a Eee AEAEE AKEE AEAEE EAEE AEAEE EEE EEE aE aa 78 6 9 1 mMCamGetIngeModes nnn a ed ous A Lio ii 79 6 9 2 IMC ALA MA A A la 80 6 10 REGISTER FUNCTIONS ccc csseeeeceeeeccccessnneeeeeesceccasnneeeeeesooooassaneseeeeaoogeasasseseeesooogensasaeseessooooansnasseesenoags 81 6 10 ImCamRcadO Ta IE 0 see tes A ETNE EEE E E EE 82 6 10 2 ImCamReadBlock ias 83 6 103 ImCam Write Quadlet miii iia E EEEE EEE Ea a aE aE E aa S 84 7 FOR PREVIOUS VERSION USER API VERSION 1 4 X X oooooocccoconocococcccccccccnnnannnnnnonnnnnnnaaannnnos 85 T A NAMING CONVENTIONS cuaccocciocoonosnmanrncncococoseseonrn anaana aeaa aaan Eaa aiaa kanarka uku aaru a akakaa AKAA a EEEE NENEKA 85 7 2 RETURN VALUES OF THE FUNCTIONS csccceeeceeeeceeseeeeeeeeeceaasaaeeeeesseoaassaaaeeeeesseoaassaaaseessssooaasnaeeeeesssaoas 85 TS ENUM TYPE 0 dia 85 1 4 FUNCTION CHANGES ocio ricr cidcid 85 4 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 1 License 1 1 Evaluation Version Limit amp License The Evaluation Version without 1stVision Inc Camera
5. nCamindex index of the camera to set the feature feature feature id to set to auto or manual mode bAuto flag for auto TRUE or manual FALSE RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS 42 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 5 5 ImCamSetOnePush DEFINITION BOOL SetOnePush IN INT Camindex IN INT feature IN BOOL bOnePush PARAMETERS nCamindex index of the camera to set the feature feature feature id to set one push mode bOnePush flag for one push mode RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS 43 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 5 6 ImCamGetFeatureRange DEFINITION BOOL ImCamGetFeatureRange IN INT nCamindex IN INT feature OUT INT pMin OUT INT pMax PARAMETERS nCamindex index of the camera to get feature information feature feature id to get the range pMin minimum value of the feature pMax maximum value of the feature RETURN VALUE IMC_SUCCESS Success Else FAIL REMARKS 44 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 5 6 ImCamGetFeatureValue DEFINITION BOOL ImCamGetFeatureValue IN INT nCamindex IN INT feature OUT INT pValue PARAMETERS nCamindex index of the camera to get feature value feature feature id to get informatio
6. regardless of the image format streamed out by the camera by setting the argument of the ImCamOpen function The API calls user callback function if user has registered his own callback function with every frame data with the format user defined 31 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 4 1 ImCamOpen DEFINITION BOOL ImCamOpen IN INT nCamindex IN BOOL bUseCallBack IN BOOL bUsePreview IN HWND hPreviewWnd IN ULONG ulResizeView IN BOOL bFullView IN INT grabMode PARAMETERS nCamindex index of the camera to open bUseCallback flag to specify whether to use callback function or not bUsePreview flag to specify whether to use preview window or not hPreviewWnd handle of the user window used for display ulResizeView method of the preview window layout bFullView flag to specify whether to user full window mode or not when the bUsePreview is TRUE grabMode image data format passed to callback function RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS hPreviewWnd is not NULL This argument defines the layout of the camera stream data in the display data size The default value of this argument is IMC_VIEW_FILL function Please refer to ImCamSetCallback section If the bUsePreview is TRUE and hPreviewWnd is NULL the API will use DirectX preview window for display and If hPreviewWnd is not NULL the API use user window
7. value to the previous version Change the IMC_VIDEO_MODE to INT IMC_VIDEO_FRATE enum type is changed to define values in ImCamDef h The elements have same value to the previous version Change the IMC_VIDEO_MODE to INT IMC_FEATURE enum type is changed to define values in ImCamDef h The elements have same value to the previous version Change the IMC_FEATURE to INT IMC_GRAB_MODE enum type is changed to define values in ImCamDef h The elements have same value to the previous version Change the IMC_GRAB_MODE to INT 7 4 Function changes The bool type argument is changed to BOOL type Camera GetCurrentFormat is removed Instead use ImCamGetVideoFormat Camera SetCurrentFormat is renamed to ImCamSetVideoFormat Camera SetCurrentMode is removed Instead use ImCamSetVideoMode Camera GetCurrentMode is renamed to ImCamGetVideoMode 85 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 ImCamSetVideoMode s usage is changed ICamera GetCurrentFrate is changed to ImCamGetFrameRate ImCamOpen s usage is changed Functions regarding ROI is fixed ImCamSaveResizeBMP ImCamSaveResizeJPG ImCamSaveResizeTIF functions merged to ImCamSaveBMP ImCamSaveJPG ImCamSaveTIF respectively Please refer to section 5 86 86 1stVision Inc
8. with IMC_GRAB_RGB888 76 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 8 6 ImCamGetNegative DEFINITION BOOL ImCamGetNegative IN INT nCamindex PARAMETERS nCamindex index of the camera to control RETURN VALUE IMC_SUCCESS flip effect is enabled Else flip effect is disabled REMARKS 77186 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 9 Trigger Functions Trigger is supported by the camera so user should check the camera manual to see whether the camera support trigger mode or not The trigger functions handles only mode setting for hardware trigger In trigger mode all the features is applied as in live mode and the difference is only the camera outputs one frame data after ths trigger signal is pulsed 78 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 9 1 ImCamGetTrigMode DEFINITION BOOL ImCamGetTrigMode IN INT nCamIndex OUT BOOL bTrig OUT INT pMode OUT INT pParam PARAMETERS nCamindex index of the camera to get information bTrig pointer to get the trigger state pMode pointer to get the mode value pParam pointer to get parameter for the mode RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function can be used to set trigger mode The trigger mode and parameter is working as defined in the IIDC Specification 1 30 79
9. 0 0 6 5 10 ImCamGetDataBits DEFINITION BOOL ImCamGetDataBits IN INT nCamindex OUT INT pnDataBits PARAMETERS nCamindex index of the camera to get information pnDataBits real valid bit at Y1600 mode RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function is used to get the real valid data bits among the 16bits data transferred from the camera when Y1600 mode is set The valid data bits is dependent on the camera so users have to check the camera manual for this function 49 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 5 11 ImCamSetAWBRegion DEFINITION BOOL InCamSetAWBRegion IN INT nCamindex IN INT nLeft IN INT nTop IN INT nRight IN INT nBottom PARAMETERS nCamindex index of the camera to set information nLeft nTop x and y coordinates of the left top point to set region of the AWB nRight nBottom x and y coordinates of the right bottom point to set region of the AWB RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS The region designated by this function defines the region for processing AWB Auto White Balancing algorithm and this region has meaning only in auto or one push mode This function is dependent on the camera so users should check camera manual to check whether the camera support this function or not 50 86 1stVision Inc 1stVision Inc IEEE 1394 Camera AP
10. 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 9 2 ImCamSetTrigMode DEFINITION BOOL ImCamSetTrigMode IN INT nCamindex IN BOOL bTrig IN INT nMode IN INT nParam PARAMETERS nCamindex index of the camera to set information bTrig flag for setting trigger mode on TRUE off FALSE nMode trigger mode to set please refer to the camera manual nParam trigger mode argument RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function can be used to set trigger mode and following parameter for the mode If user sets the trigger mode to 0 the API ignores parameter argument 80 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 10 Register Functions For the 1394 camera all cameras should provide memory and register defined by the IEEE 1394 1995 IEEE 1394 2000 and IIDC Specification The API provides function for user to read and write these areas directly All the data for reading and writing is handled in 32bits 81 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 10 1 ImCamReadQuadlet DEFINITION BOOL ImCamReadQuadlet IN INT nCamindex IN ULONG address OUT ULONG pulValue PARAMETERS nCamindex index of the camera to control address address of the 1394 Configuration ROM or camera control register to read pulValue pointer to receive register value RETURN VALUE
11. API ImCam Library s license can be used only for 1stVision Inc Cameras You can use it for the first one 1 hour and then this API is automatically closed and you cannot use all the functions of API You use Evaluation Version for a certain period and the expiry expiration date will be announced at the time of its distribution But when you begin the application again it can be used for the additional one hour You shall refer to the standard EULA Document regarding other License regulations When you have any question to the formal Version purchase please do not hesitate to call our company 1 2 Note 1stVision Inc Camera API ImCam Library only supports 1stVision Inc hardware and you are not allowed to use this Camera API to build Application for other camera hardware The EVALUATION VERSION SOFTWARE is provided to you AS IS without warranty The entire risk of the quality and performance of the software is with you We appreciate any feedback and bug report however we can not guarantee satisfactory response 1 3 Legal Notice By installing copying or otherwise using the SOFTWARE you agree to be bound by the terms of the End User License Agreements EULA The SOFTWARE includes 1stVision Inc and 1stVision Inc suppliers intellectual property Please read 1stVision Inc and 1stVision Inc suppliers EULA before installing the SOFTWARE If you do not accept the terms of the license agreements please do not install
12. CHAR pstrName PARAMETERS nCamindex index of the camera to get information pnSize length of the valid string in the sttName strName model name of the camera RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function returns only the camera model name 19 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 2 4 ImCamGetFirmwareVersion DEFINITION BOOL ImCamGetFirmwareVersion IN INT nCamindex CHAR pstrVersion PARAMETERS nCamindex index of the camera to get information pstrVersion version information RETURN VALUE IMC_SUCCESS Success Else Ffail REMARKS This function can be used to check the H W version of the camera made by 1stVision Inc The H W version is expressed as X XXX Y Y YY where X XXX means micom version and Y YYY means FPGA version 20 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 3 Video Format Mode Frame rate Functions The image streamed out from the camera is decided by the image format image size and frame rate The API classifies the stream information with 3 categories format mode frame rate The format means data format camera outs and the mode means image size for the designated format The frame rate will vary to the designated format and mode So if user changes format or mode for the camera user should recompose the mode
13. Camera API Version 2 0 0 0 User Manual 3 Edition Document Revision 2 0 1stVision Inc www 1stVision com Tel 978 474 0044 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 Contents 1 LICENSE A P EA a a 5 1 1 EVALUATION VERSION LIMIT amp LICENSE 0ccescceecceeccesccecceccecececceeccenececceuceeseeeeeeeeeeseceeseneeeseeeseeeeeeseeeseneeeses 5 Aen aE E E E E AEEA EA EA AEAEE dance E 5 13 S e7 AN o o 500 a A A E EEEE EOE E E 5 2 SYSTEM SOFTWARE REQUIREMENT ccccccccscsscsssescssesenesseseeesseeseeenssenuuseeenueeeausseneueesenes 6 21 SYSTEM druida dara ER ERES 6 22 SOF WARE ici Eara aa Paaa 6 SE SETUP iia aia AEE E EEPE EEE EEE EEA EE A E E EE A dee 7 3 1 CONSTRUCTION OF API FILE 0 ccecceecceecceecececcecceeccecececcuaceecececcueeeeseeaceeneeeeseucauaeeeseeuseuseeessueeuaeeeeseueeeneeeeees 7 ESA A A A 7 3 3 VISUAL STUDIO ENVIRONMENT iia adidas 7 3 4 C BUIEDERENVIRONMEN Tai n 8 3 5 VISUAL BASIC ENVIRONMENT Soi lalo canolan cine Dees 8 4 IMCAM 1STVISION INC CAMERA API SAMPLE APPLICATION ooccocccccccoccncnonononononanarnanannnanas 9 5 SUMMARY OF FUNCTIONS ui ac 10 6 API FUNCTION DETAILS ii coo da iii 13 6 1 CAMERA AND API INITIALIZATION FUNCTIONS 2 cecceeeceecceecceeccecceccenceeceeeceeneeeseeuceuaeeeseeueeeneceseceeeeeeeeeseeeeees 13 A NA 14 6 1 2 mCam mni en a a a a AA it 15 6 2 CAMERA INFORMATION FUNCTIONS 0eccesecceeccecceeceeccecceecceneeeceeecceneceeseuceeneeesseuceua
14. E aE E an Sa TSE TEE ER 42 6 5 3 ImCamSetOnePush siii asia 43 6 5 6 ImCamG et EF eatureR ME A A ada 44 6 5 6 ImCamGetF eattire Valde ui a Id 45 6 52 7FlmCamSetFeatre A ae to tdE 46 6 5 8 ImCamsetEcatureD alt 47 6 5 9 ImCamsSetAllFeatureDetaU licencias diante cus cutis coves seu cevacueagssebues ae osaisi i a aar e dai 48 65410 IMCamGetDataB its ii A A A AAA tot 49 6 311 IMC IMSCCAWBR EM A A bates AAA 50 6 5 12 ImCamSetDefaultAWBRegl0N cesiones rc cid ada dead teta 51 6 6 SIZE AND CAPTURE FUNCTIONS Di r aa eieaa a a ra a aAa aa a aan aaa ra a aAa du be sa dele ca dada dante Taie EEEE 52 6 6 1 ImCam Get ma eS 12 niania iesaisti ee ES EEE de 53 6 6 2 ImCamGetBursize ui e E ice AEE a E E a E a S 54 6 0 3 TnGamS etCall backs e iena hea AE E O TA ETE EAN EE ES 55 6 6 4 ImCamSaveBMP oein aa aae dd 56 6 6 3 ImCamsSave LIFs inaua a aa a dtr o de de o dd 57 0 6 6 lmCamSaveIRG e AAA 58 6 6 7 ImCamStart AVI Capture osiin iniaa oe i E EEE EEE aE ESSE S EEEE E E E 59 6 6 8 lmCamStopAv A A K EE a K A E cebubeeeere 60 6 6 9 ImCamStart WMV Capture sen i e E E E a E RAE RAS 61 6 6 10 ImCamstop WMV Captures aiat ieee aei ii ds a lia a heh eto bib 62 6 7 FORMAT 7 ROI FUNCTIONS td dl 63 607 1 ImCamisRO SUPPORT 64 3 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 72 ImCamEnableROIMOd E yi na hrten stan Aaecnside dd ae ce dret desd cda eo 65 6 1 3 linGamDisableROIM odes sass Ale ti oe aia 66 6 74 ImC am GetROISIZE neona nade r Site
15. I Ver 2 0 0 0 6 5 12 ImCamSetDefaultAWBRegion DEFINITION BOOL ImCamSetDefaultAWBRegion IN INT nCamIndex PARAMETERS nCamindex index of the camera to set information RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function is used to set the AWB region to the factory default value This function is dependent on the camera so users should check camera manual to check whether the camera support this function or not 51 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 6 Size and Capture Functions The API provides information about the image size currently camera stream out and also provides function which can save this stream data into the image or stream If the user callback is registered the user processed data is passed to the saving functions Data flow in capture is as follows BMP JPG Camera secr Capture TIF Callback AVI WMV But in case WMV capture user should install Windows Media Encoder because the API use this codec 52 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 6 1 ImCamGetlmageSize DEFINITION BOOL ImCamGetWidth IN INT nCamIndex OUT INT pnWidth OUT INT pnHeight PARAMETERS nCamindex index of the camera to get information pnWidth image width size of the current mode pnHeight image height size of the current mode RETURN VALUE IMC_SUCCESS Succe
16. IMC_SUCCESS Success Else Fail REMARKS This function can be used to read 32 bit data from the configuration ROM address specified in IEEE 1394 1995 and IEEE 1394 2000 and the Camera Control Register described in IIDC V1 30 With this function you can read only 32 bit data at once 82 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 10 2 ImCamReadBlock DEFINITION BOOL ImCamReadBlock IN INT nCamindex IN ULONG ulAddress IN ULONG nQuadCount OUT ULONG pRet PARAMETERS nCamindex index of the camera to control ulAddress address of the 1394 Configuration ROM or camera control register to read nQuadCount the number of quadlet 32bit unit to read pRet pointer to receive return values RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function can be used to read 32 bit data from the configuration ROM address specified in IEEE 1394 1995 and IEEE 1394 2000 and the Camera Control Register described in IIDC V1 30 With this function you can read any size of data you want 83 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 10 3 ImCamWriteQuadlet DEFINITION BOOL ImCamWriteQuadlet IN INT nCamIndex IN ULONG ulAddress IN ULONG ulValue PARAMETERS nCamindex index of the camera to control ulAddress address of the 1394 Configuration ROM or camera control register to write ulValue
17. ION BOOL SetFrameRate IN INT nCamindex IN INT Frate PARAMETERS nCamindex index of the camera to set frame rate Frate frame rate value to set RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function is used to set the frame rate to use 29 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 3 9 ImCamGetFrameRate DEFINITION BOOL ImCamGetFrameRate IN INT nCamindex IMC_VIDEO_FRATE pFrate PARAMETERS nCamindex index of the camera to get frame rate pFrate frame rate value currently set in the camera RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS 30 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 4 Display Functions After setting the format mode and frame rate user can get the data from the camera The API uses DirectX and so to get the camera we should create DirectX graph first and set the camera to output the data While getting the camera user can use preview or not and user can get every frame data for his own use Following figure describes the data flow for display To set the camera to stream out user should call ImCamOpen and ImCamStart function sequentially and to stop the stream out user should call ImCamStop and ImCamClose function sequentially User P Camera Callback e Display The API user can set data format passed to the callback function
18. ImCamClose to close preview window If user calls this function followed by ImCamStart user can live stream again in the preview window 37 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 5 Feature Control Functions The feature supported by the camera is varies to the camera So the feature has to be verified whether the camera support or not before use the feature The API now handle amount to 17 features defined in the ImCamDef h header file and the supported feature by the API can be expanded The user must know the support of the feature support of the auto mode support of the one push and valid range of the feature value before using the feature Because the API gets feature information from the camera when the ImCamlsFeatureSupport is called this function should be called before any other feature control functions 38 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 5 1 ImCamlsFeatureSupport DEFINITION BOOL ImCamlsFeatureSupport IN INT nCamIndex IN INT feature PARAMETERS nCamindex index of the camera to verify feature feature feature id to verify RETURN VALUE IMC_SUCCESS camera support this feature Else camera doesn t support this feature REMARKS According to the camera supported feature the property of the feature range auto and one push support can vary so user first call this function with all t
19. ImCamsStartAVICapture Start AVI stream capture ImCamStopAVI Capture Stop AVI stream capture ImCamStartWMVCapture Start WMV stream capture ImCamStopWMVCapture Stop WMV stream capture ROI Functions ImCamlsROISupport Check if ROI mode is supported by the camera ImCamEnableROlMode Activate ROI mode ImCamDisableROlMode Inactivate ROI mode ImCamGetROlSize Get the ROI region size currently set ImCamGetMaxArea Get the maximum ROI region size ImCamGetCurrentArea Get the ROI information currently set ImCamSetCurrentArea Set the ROI information Image Effect Functions ImCamSetMirror Set the Mirror effect ImCamGetMirror Get the state of the Mirror effect ImCamSetFlip Set the Flip effect ImCamGetFlip Get the state of the Flip effect ImCamSetNegative Set the Negative effect ImCamGetNegative Get the state of the Negative effect Trigger Functions ImCamGetTrigMode Get the Trigger mode state ImCamSetTrigMode Set the Trigger mode Read Write functions ImCamReadQuadlet Read 32bit data form the 1394 register 11 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 ImCamReadBlock Read multiple of 32bit data from the 1394 register ImCamWriteQuadlet Write data to the 1394 register 12 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 API Function Details 6 1 Ca
20. Name file name to save the AVI file including extension bUseCallback flag for selecting whether to use the callback or not bView flag for preview while capturing hPreviewWnd handle of the preview window If the bView is true the API display data in the window designated by this handle RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function is used to capture the image data as WMV stream data The file extension can be asf or wmv To use this function user should install Windows Media Encoder 9 61 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 6 10 ImCamStopWMVCapture DEFINITION BOOL ImCamStopWMVCapture IN INT nCamindex PARAMETERS nCamindex index of the camera to control RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function stop WMV capture 62 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 7 Format 7 ROI Functions The ROI is supported by the camera functions in this section is supported only the camera which support ROI mode User should check the camera manual before using these functions ROI means that the camera output data only for the area defined by the user but in this mode all the image size may not be controllable So the user refer to the camera manual for valid step size for width and height direction 63 86 1stVision Inc 1stVision I
21. RS nCamindex index of the camera to save pstrFileName file name to save the image bResize flag for selecting resize nDestWidth destination width if resize flag is set to TRUE nDestHeight destination height if resize flag is set to TRUE RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function is used to save frame data as TIFF image This function can save the image in original size or in modified size If the bResize flag is set to FALSE next arguments of size are ignored by the API 57 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 6 6 ImCamSaveJPG DEFINITION BOOL ImCamSaveJPG IN INT nCamindex IN CHAR pstrFileName IN BOOL bResize IN INT nDestWidth IN INT nDestHeight PARAMETERS nCamindex index of the camera to save pstrFileName file name to save the image bResize flag for selecting resize nDestWidth destination width if resize flag is set to TRUE nDestHeight destination height if resize flag is set to TRUE RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function is used to save frame data as JPG image This function can save the image in original size or in modified size If the bResize flag is set to FALSE next arguments of size are ignored by the API 58 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 6 7 ImCamS
22. _SUCCESS and IMC_FAIL is defined in ImCamDef h as 1 and 0 respectively Category Function Description Initialize Functions ImCaminit Initialize API and returns the number of camera connected to the system ImCamUninit Terminate the use of API Information Functions ImCamSelectCam Select one camera among the cameras connected to the system ImCamGetName Read the name of the camera including company name model name and serial number ImCamGetModelName Read the model name of the camera ImCamGetFirmwareVersion Read the H W version of the camera Format Mode Frame rate ImCamGetFormatList Get the format list the camera supports ImCamSetVideoFormat Set the camera to the designated format ImCamGetVideoFormat Get the format currently set from the camera ImCamGetModeList Get the mode list the camera supports for the format defined ImCamSetVideoMode Set the camera to the designated mode ImCamGetVideoMode Get the mode currently set from the camera ImCamGetFrameRateList Get the frame rate list the camera support for the format and mode defined ImCamSetFrameRate Set the camera to the designated frame rate ImCamGetFrameRate Get the frame rate currently set from the camera Display Control ImCamOpen Prepare the API for displaying the camera ImCamClose Resolve the API for stopping the camera display ImCamlsOpen Check the state of the c
23. amera ImCamStart Set the camera to start data out ImCamStop Set the camera to stop data out Feature Control ImCamlsFeatureSupport Check if the feature is supported by the camera ImCamlsFeatureAuto Check the auto state of the feature ImCamSetFeatureAuto Set the feature to auto manual state ImCamlsOnePushSupport Check if the one push is supported by the feature 10 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 ImCamSetOnePush Set the feature to one push mode ImCamGetFeatureRange Get the valid range of the feature ImCamGetFeatureValue Get the current value of the feature ImCamSetFeatureValue Set the feature to the designated value ImCamSetFeatureDefault Set the feature to the factory default state ImCamSetAllFeatureDefault Set all features to the factory default state ImCamGetDataBits Get the valid data bits ImCamSetAWBRegion Set the AWB region for white balancing ImCamSetDefaultAWBRegion Set the AWB region to the factory default state Capture Functions ImCamGetlmageSize Get the image size of the current mode ImCamGetBufSize Get the data buffer size of the current mode ImCamsSetCallback Register callback function ImCamSaveBMP Save frame data to BMP image ImCamSaveTIF Save frame data to TIF image ImCamSaveJPG Save frame data to JPG image
24. amera streams unchanged If user set grabMode to IMC_GRAB_RGB888 user can receive RGB24 formatted data If the callback function is registered user can receive every frame of the camera but the process in the callback function can be overhead to the CPU and this can reduce the frame rate transferred to the API For the detailed use of this function please refer to the sample source code 55 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 6 4 ImCamSaveBMP DEFINITION BOOL ImCamSaveBMP IN INT nCamindex IN CHAR pstrFileName IN BOOL bResize IN INT nDestWidth IN INT nDestHeight PARAMETERS nCamindex index of the camera to save pstrFileName file name to save the image bResize flag for selecting resize nDestWidth destination width if resize flag is set to TRUE nDestHeight destination height if resize flag is set to TRUE RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function is used to save frame data as BMP image This function can save the image in original size or in modified size If the bResize flag is set to FALSE next arguments of size are ignored by the API 56 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 6 5 ImCamSaveTIF DEFINITION BOOL ImCamSaveTIF IN INT nCamindex IN CHAR pstrFileName IN BOOL bResize IN INT nDestWidth IN INT nDestHeight PARAMETE
25. copy or use the SOFTWARE 5 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 2 System Software Requirement 2 1 SYSTEM 1stVision Inc Camera API ImCam Library is the library functions to control the cameras produced by 1stVision Inc and the performance of CPU is the most important to process all the real time data transmitted by the camera The API operates in the CPU with PI Ill 1 0 up without a hitch however the actual number of frame can be reduced under it 2 2 SOFTWARE The following software are required to use 1stVision Inc Camera API 1stVision Inc IEEE 1394 Camera Device Driver e Compiler Microsoft Visual C 6 0 C Builder 6 0 or Visual Basic 6 0 e DirectX 8 1 or higher in Windows2000 Windows98 DirectX 9 0 is recommended in Windows XP e Windows Media Encoder 9 series http www microsoft com windows windowsmedia It is necessary for saving WMV type stream capture Please refer to library reference 6 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 3 Setup Installing library and setting up the project to use 1stVision Inc camera API ImCam API 3 1 Construction of API File e 3files are in Lib directory ImCamDef h structure definition file ImCamApi h API Header file ImCam lib API Library file for Visual C users e 2files are in Builder directory Apilmport h API import header file for Builder or Visual C users Apilmport
26. cpp API import header file for Builder or Visual C users e 1 file is in VBasic directory ImCamApi bas API import module file for Visual Basic users e 2files is in Bin directory ImCam dll API runtime dil file LibSample exe Sample project execution file e Sample project is in LibSample directory Sample code Example application source using the ImCam API We provide sample code for Visual C only 3 2 Setup Copy Lib directory including the provided library files to a new project directory or adds up the library necessary for those library and Direct Show Refer to 3 3 Setting of Project 3 3 Visual Studio Environment Please refer to LibSample project regarding actual set up Adds up the next libraries in Link tab of Project Setting dialog This is necessary if user want to use ImCam lib file while compilling the program If user want to use Apilmport h and Apilmport cpp just insert these source into user project without linking with the ImCam lib file lib ImCam lib winmm lib quartz lib 7186 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 Project Settings 21x Settings For Win32 Release General Debug C C Link Resources M LibSample Category TE gt Reset Output file name Release LibSample exe Object library modules lib ijl1 51 1ib lib Imcam lib winmm lib quar
27. eeeseeeeeueeeesecesaueeeeseeeeees 16 0 2 tmCamSe lect Mn A A A A Dd 17 62 2 IMCEAMEIAN AMEN A is 18 6 2 3 ImCam Get Mod eIName ah nanna aa a a a a aa a a a aa ar 19 6 2 AMOG e Ware VOM A A AN ur caus S A 20 6 3 VIDEO FORMAT MODE FRAME RATE FUNCTIONS ccsssscssecseesseseeecseesceeseenecseeseussanscsessueeeseeeseseessenseenseseess 21 6 3 1 IMCAMES TEO Mali e A E ars 22 0 32 mEamsetVide0 ROMA A DI EA A ence ates Ed LAA dave Menarini 23 0 33 MEMO AVISO CDA A A AAA AA E AS 24 6 3 4 Im Camm Get Mode bist mitin iii di ias 25 0 3 AMC AMS NEMESIO 0aa 26 63 06 1MEAMEIAVIdEO MOE A A A a AN 27 2 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 3 7 ImCamGetEramerateList ai a a Bo 28 6 38 lmCamS eth rameR ate AAA EA AAA do 29 6 3 9 ImCamGetFrameR o tratan a Radial 30 0 4 DISPLAY FUNG TIONS a r D aa a aaa li aaa a cacaos aaa aa a aa aa litio cli Eaa aaa araea lio aaa aiaa 31 CALI AMO pen ied wok E EE TE E E E AE Ei 32 6 4 2 IMC SE isis peiin aiea eieiei ae iia uneusetce i aa eana a a a n aa Ee 34 K E iiaia ELD aE EEA EEE T ET E EEE AS 35 CAICARA 36 CAD IOMA ODA A A A T E AAA 37 6 5 FEATURE CONTROL FUNCTIONS ccccccssessseeesenneeeceeaasenaeeeeeeeeeaaassaaeeeeeseeoaassaaaeeeeessegaassaaaeesssssooagssaeeeessssaoas 38 6 5 1 ImCamisFcatlre UPpOTE sre cessions datada da dad did eddie id 39 6 52 MC ans Feature AUO ianea dd aa di dd 40 6 5 3 a EOT RTS y ESSEET A T T 41 6 5 4 ImCamSetF ature Auto niaior E SEa ER EEEa aa Sa E
28. ent ROI mode pnHeight height size of the current ROI mode RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function is used to get the image size of the current ROI mode 67 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 7 5 ImCamGetMaxArea DEFINITION BOOL ImCamGetMaxArea IN INT nCamIndex OUT PIMC_ROI_PROPERTY pProp PARAMETERS nCamindex index of the camera to get information pProp pointer to get the information RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function is used to get maximum ROI area size supported by the camera The structure for ROI information is like as follows and defined in the ImCamDef h header file typedef struct int hpos int vpos int hsize int vsize int bpp_min int bpp_max int bpp y IMC_ROI_PROPERTY PIMC_ROI_PROPERTY 68 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 7 6 ImCamGetCurrentArea DEFINITION BOOL ImCamGetCurrentArea IN INT nCamindex OUT PIMC_ROI_PROPERTY pProp PARAMETERS nCamindex index of the camera to control pProp pointer to the ROI information RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function is used to get the area size currently set by the user 69 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 7 7 ImCamSetC
29. he feature define in the ImCamDef h Before this function is called the API doesn t get the feature information from the camera 39 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 5 2 ImCamlsFeatureAuto DEFINITION BOOL ImCamlsFeatureAuto IN INT nCamindex IN INT feature PARAMETERS nCamindex index of the camera to verify feature feature feature id to check whether the auto mode is supported or not RETURN VALUE 1 feature doesn t support auto mode 1 feature supports auto mode and currently set to auto mode O feature supports auto mode and currently set to manual mode REMARKS This function is used to check the auto mode supported or not for the feature 40 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 5 3 ImCamlsOnePushSupport DEFINITION BOOL ImCamlsOnePushSupport IN INT nCamindex IN INT feature PARAMETERS nCamindex index of the camera to verify the feature feature feature id to check whether the one push is supported or not RETURN VALUE IMC_SUCCESS feature supports one push mode Else feature doesn t support one push mode REMARKS 41 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 5 4 ImCamSetFeatureAuto DEFINITION BOOL ImCamSetFeatureAuto IN INT nCamindex IN INT feature IN BOOL bAuto PARAMETERS
30. ile IMC_VIDEO_FORMAT RGB 24bit IMC_FORMAT_RGB24 Y 800 IMC_FORMAT_Y800 Y 1600 IMC_FORMAT_Y1600 YUV 4 1 1 IMC_FORMAT_Y411 YUV 4 2 2 IMC_FORMAT_Y422 YUV 4 4 4 IMC_FORMAT_Y444 IMC_FORMAT_UNKNOWN In case mono where more than 8 bits only 8 bits is used for display 22 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 3 2 ImCamSetVideoFormat DEFINITION BOOL ImCamSetVideoFormat IN INT nCamindex IN INT format PARAMETERS nCamindex index of the camera to set video format Format the format value to set This argument should have one of the value get by the ImCamGetFormatList function RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function is used to set the camera to the designated format 23 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 3 3 ImCamGetVideoFormat DEFINITION BOOL ImCamGetVideoFormat IN INT nCamindex OUT INT pFormat PARAMETERS nCamindex index of the camera to get format information pFormat the format value currently set RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS 24 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 3 4 ImCamGetModeList DEFINITION BOOL ImCamGetModeList IN INT nCamindex IN INT Format IN OUT INT pnListNum OUT INT pModel PARAMETERS nCamindex index of the came
31. lose RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function stops preview and closes all interfaces opened by the ImCamOpen function This function should be called after ImCamStop function 34 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 4 3 ImCamisOpen DEFINITION BOOL ImCamlsOpen IN INT nCamindex PARAMETERS nCamindex index of the camera to check open state RETURN VALUE IMC_SUCCESS camera is opened Else camera is not opened REMARKS 35 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 4 4 ImCamStart DEFINITION BOOL ImCamsStart IN INT nCamIndex PARAMETERS nCamindex index of the camera to stream out data RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function controls the camera to stream out data If the preview window is set the API use the preview window for display so the user can live image in the preview window 36 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 4 5 ImCamStop DEFINITION BOOL ImCamStop IN INT nCamindex PARAMETERS nCamindex index of the camera to stop stream data RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function controls camera to stop stream data This function doesn t close the preview window so user should call
32. lue currently set in the camera RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS 27 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 3 7 ImCamGetFramerateList DEFINITION BOOL ImCamGetFramerateList IN INT nCamindex IN INT Format IN INT Mode IN OUT INT pnListNum OUT INT pRate PARAMETERS nCamindex index of the camera to get frame rate information Format format value currently set in the camera Mode mode value currently set in the camera pnListNum the size of the valid frame rate list This value should be set to the count of the pRate array when calling this function pRate list of the frame rate for the format and mode RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function is used to get the frame rate supported for the format and mode The ImCamSetVideoMode function should be called before this function The relation between the values retained in the frame rate list and real frame is like as follows and these values are defined in the ImCamDef h header file 1 875 fps IMC_FRATE_1_875 3 250 fps IMC_FRATE_3 75 7 500 fps IMC_FRATE_7 5 15 000 fps IMC_FRATE_15 30 000 fps IMC_FRATE_30 60 000 fps IMC_FRATE_60 120 000 fps IMC_FRATE_120 240 000 fps IMC_FRATE_240 IMC_FRATE_UNKNOWN 28 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 3 8 ImCamSetFrameRate DEFINIT
33. mera and API initialization Functions API should be initialized before calling any other API function If API function is called while is not initialized the function will always return 1 After completing the use of the API user should call the ImCamUninit function before closing the user application 13 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 1 1 ImCaminit DEFINITION BOOL ImCamInit PARAMETERS None RETURN VALUE Number of the camera API detects REMARKS This function initializes the API and returns the number of the camera detects So this function should be called before any other API function This function will return 1 if it can not initialize the API 14 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 1 2 ImCamUninit DEFINITION VOID ImCamUninit PARAMETERS None RETURN VALUE REMARKS After completing the use of the API user should call this function before terminating the user application to inform the API to release information contained 15 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 2 Camera Information Functions After initializing the API user should select the camera first to control This is important for synchronization with the API and user should call this function once when the camera to control is changed For the 1394 camera all cameras sh
34. n pValue feature value currently set RETURN VALUE IMC_SUCCESS Success Minus Value Fail REMARKS 45 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 5 7 ImCamSetFeatureValue DEFINITION BOOL ImCamsSetFeatureValue IN INT nCamIndex IN INT feature IN INT nValue PARAMETERS nCamindex index of the camera to set the feature feature feature id to set nValue value of the feature RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS 46 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 5 8 ImCamsSetFeatureDefault DEFINITION BOOL SetFeatureDefault IN INT nCamindex IN INT feature PARAMETERS nCamindex index of the camera to set the feature feature feature id to set to the factory default value RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS 47 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 5 9 ImCamSetAllFeatureDefault DEFINITION BOOL ImCamsSetAllFeatureDefault IN INT nCamIndex PARAMETERS nCamindex index of the camera to set the feature RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function is used to set all the features supported by the camera to the factory default values 48 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0
35. nc IEEE 1394 Camera API Ver 2 0 0 0 6 7 1 ImCamisROISupport DEFINITION BOOL ImCamlsROISupport IN INT nCamIndex PARAMETERS nCamindex index of the camera to check RETURN VALUE IMC_SUCCESS camera supports ROI Format 7 mode Else camera doesn t support ROI Format 7 mode REMARKS This function is used to check whether the camera supports the ROI mode or not Please refer to the camera manual 64 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 7 2 ImCamEnableROlMode DEFINITION BOOL ImCamEnableROIMode IN INT nCamindex PARAMETERS nCamindex index of the camera to control RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function is used to activate ROI mode 65 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 7 3 ImCamDisableROIMode DEFINITION BOOL ImCamDisableROlMode IN INT nCamindex PARAMETERS nCamindex index of the camera to control RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function is used to inactivate the ROI mode 66 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 7 4 ImCamGetROISize DEFINITION BOOL ImCamGetROISize IN INT nCamIndex OUT INT pnWidth OUT INT pnHeight PARAMETERS nCamindex index of the camera to control pnWidth width size of the curr
36. nctions of JPEG BMP and TIF are included in the API Please refer to the sample source regarding the executing of the function each ImCam API Sample 2000 1 IMl Tech IMB 80FT 10 S60FFFFF View Control Format List format list supported lt v1 600 y Play Resolution 800 x 600 y Pause mode list supported AAA Lib Feature Framerate Grab Image Frame rate list supported E 15 000 _Srab Image Stream Capture Start Stop Show ROI control dialog lt ROI Control Capture With No Preview JPG Select mirror flip effect t J Mirror 7 Flip Select RGB24 convert t RGB24 Convert 15 x List of cameras Open close preview window Start preview Stop Preview Open feature control dialog Display raw image data size while previewing Start stream capture Stop stream capture Save JPEG Image with no preview Callback RGB24 Start Save Stop Save Set callback function lt One Shot Capture ____ JPEG BMP TIF Capture JPEG image Start stop multi image capture Capture tiff image Capture BMP image 9 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 5 Summary of Functions The functions which have BOOL type as return value in the API will return IMC_SUCESS if it succeeds and return IMC_FAIL or minus value if it fails IMC
37. ould have regions defined in IEEE1394 1995 IEEE1394 2000 IEEE1212 and IIDC specification to save information about the camera maker camera model and other characteristics User can read this area by calling the ImCamGet Model Name function or functions explained in section 6 10 16 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 2 1 ImCamSelectCam DEFINITION BOOL ImCamSelectCam IN INT index PARAMETERS index Index of the camera installed in the system It begins with 0 and should be in the range of the number return by the ImCamlnit function RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS Selects the camera corresponding to the index among the cameras installed 17 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 2 2 ImCamGetName DEFINITION BOOL ImCamGetName IN INT nCamindex OUT INT pnSize OUT CHAR pstrName PARAMETERS nCamindex camera index to get information pnSize length of the valid string strName strName name of the camera RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS The company model and GUID is included in the name and is expressed as company model GUID 18 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 2 3 ImCamGetModelName DEFINITION BOOL ImCamGetModelName IN INT nCamindex OUT INT pnSize OUT
38. ra to get mode list Format the format to get mode list pnListNum size of the list of supported mode for the format This value should be set to the count of the pMode array when calling this function pMode list of modes supported for the format RETURN VALUE true Success false Fail REMARKS The mode expresses image size and has the followings These values are defined in the ImCamDef h header file IMC_MODE_160x120 IMC_MODE_320x240 IMC_MODE_640x480 IMC_MODE_800x600 IMC_MODE_1024x768 IMC_MODE_1280x960 IMC_MODE_ 1280x1024 IMC_MODE_ 1360x1032 IMC_MODE_ 1600x1200 IMC_MODE_VARIABLE_ MODEO MODE7 IMC_MODE_UNKNOWN 25 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 3 5 ImCamSetVideoMode DEFINITION BOOL ImCamSetVideoMode IN INT nCamindex IN INT Mode PARAMETERS nCamindex index of the camera to set mode Mode mode to set RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function can be used to set the camera as mode user select The ImCamGetModeList function should be called before calling this function to get the modes supported for the format 26 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 3 6 ImCamGetVideoMode DEFINITION BOOL ImCamGetVideoMode IN INT nCamIndex OUT INT pMode PARAMETERS nCamindex index of the camera to get mode pMode mode va
39. ss Else Fail REMARKS This function can be used after calling the ImCamOpen function 53 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 6 2 ImCamGetBufSize DEFINITION LONG ImCamGetBufSize IN INT nCamindex PARAMETERS nCamindex index of the camera to get information RETURN VALUE Buffer size in bytes for one frame data REMARKS This function is used to get the buffer size for current mode 54 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 6 3 ImCamsSetCallback DEFINITION BOOL ImCamSetCallback IN INT nCamindex IN INT pCallbackFunc DOUBLE SampleTime BYTE pBuffer LONG IBufferSize PARAMETERS nCamindex index of the camera to set pCallbackFunc pointer of the user callback function RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS If user wants to get the frame data from the camera user should register his own callback function by calling this function And the API calls user callback when one frame data is available In case use of callback function user should set the first argument of ImCamOpen to TRUE after calling this function with user callback function User can receive raw image format or RGB24 image format according to the grabMode argument of the ImCamOpen function If user set grabMode to IMC_GRAB_RAW user can receive image data the c
40. tartAVICapture DEFINITION BOOL StartAVICapture IN INT nCamindex IN CHAR pstrFileName IN BOOL bUseCallback IN BOOL bView IN HWND hPreviewWnd PARAMETERS nCamindex index of the camera to capture pstrFileName file name to save the AVI file including extension bUseCallback flag for selecting whether to use the callback or not bView flag for preview while capturing hPreviewWnd handle of the preview window If the bView is true the API display data in the window designated by this handle RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS If user wants to capture stream after his own processing user should register callback function and call this function The processed data will be captured to the captured stream file 59 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 6 8 ImCamStopAviCapture DEFINITION BOOL ImCamStopAVICapture IN INT nCamindex PARAMETERS nCamindex index of the camera to control RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function stops AVI capture 60 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 6 9 ImCamStartWMVCapture DEFINITION BOOL StartWMVCapture IN INT nCamindex IN CHAR pstrFileName IN BOOL bUseCallback IN BOOL bView IN HWND hPreviewWnd PARAMETERS nCamindex index of the camera to capture pstrFile
41. to display The ulResizeView can be set as one of the IMC_VIEW_RESIZE IMC_VIEW_STATIC IMC_VIEW_FILL and has meaning only if the If the ulResizeView is set to IMC_VIEW_RESIZE the API will resize the preview window to the size of the real stream data If the value is set to IMC_VIEW_STATIC the API will not resize the preview and display the real stream data in the preview window regardless of the size If the value is set to IMC_VIEW_FILL the API will expand or reduce the real stream data to the size of preview window and it results in display image which is not clean if the preview window is set to more larger than the real stream If user wants to get every frame data user should register by calling ImCamSetCallback before this 32 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 The grabMode argument defines the format passed to the user callback function and can be set as one the following values defined in ImCamDef h header file IMC_GRAB_RAW camera original data format IMC_GRAB_RGB888 RGB24 IMC_GRAB_RGB555 RGB16 IMC_GRAB_RGB565 RGB16 This function doesn t set the camera to stream out data so user should call ImCamStart function to set the camera to stream out 33 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 4 2 ImCamClose DEFINITION BOOL ImCamClose IN INT nCamindex PARAMETERS nCamindex index of the camera to c
42. tz lib Y Generate debug info M Ignore all default libraries M Link incrementally J Generate mapfile l Enable profiling Project Options lib ijl151 lib lib Imcam lib winmm lib quartz lib nologo subsystem windows fincremental no El pdb Release LibSample pdb debug machine I386 coca 3 4 C Builder Environment For C Builder user can simply add Apilmport cpp and Apilmport source to the project and build program But in the program the LoadlmCamAP function should be called before using other API functions The LoadImcamAPI load the runtime library and get function pointer for each library function And the UnloadimCamApi function should be called before the application terminates Please refer to the source code for details 3 5 Visual Basic Environment For Visual Basic user can imply add the ImCamApi bas module file to the project and build the application This module also fines all the functions included in the ImCamAPI library Please refer to the source code for details 8 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 4 ImCam 1stVision Inc Camera API Sample Application LibSample as a sample project shows the example of how to use the individual functions in 1stVision Inc Camera API and provides the function of saving the captured image into the Jpeg Bmp and Tiff file as well as the basic functions the capturing fu
43. urrentArea DEFINITION BOOL ImCamGetCurrentArea IN INT nCamIndex IN IMC_ROI_PROPERTY Prop PARAMETERS nCamindex inex of the camera to control Prop ROI information to set RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS This function is used to set ROI area size 70 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 8 Image Effect Functions The API provides some image effect functions including mirror flip and negative and these functions are valid in RGB 24 mode The user can enable or disable this effect when open the camera with RGB24 mode 71 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 8 1 ImCamSetMirror DEFINITION BOOL ImCamSetMirror IN INT nCamindex IN BOOL bMirror PARAMETERS nCamindex index of the camera to set bMirror flag for setting mirror effect RETURN VALUE IMC_SUCCESS Success Else Fail REMARKS When using this function frame rate can be reduced because the calculated volume of the CPU becomes much larger Mirror effect can be used only if user calls ImCamOpen with IMC_GRAB_RGB888 72 86 1stVision Inc 1stVision Inc IEEE 1394 Camera API Ver 2 0 0 0 6 8 2 ImCamGetMirror DEFINITION BOOL ImCamGetMirror IN INT nCamindex PARAMETERS nCamindex index of the camera to control RETURN VALUE IMC_SUCCESS mirror effect is enabled
Download Pdf Manuals
Related Search
Related Contents
clique aqui para ver na íntegra Model 2300T OWNER`S MANUAL Bedienungsanleitung Philips SensoTouch wet and dry electric shaver RQ1180 VENTOWER - Alpha Samsung GT-I8700/M8 Manuel de l'utilisateur (Windows 7) Samsung 2233RZ ユーザーマニュアル Copyright © All rights reserved.
Failed to retrieve file