Home » Source Code » Face recognition » highgui.h

highgui.h ( File view )

Description: 1  Pro...
  • By 辞海之鱼 2012-11-02
  • View(s):55
  • Download(s):1
  • Point(s): 1
//  By downloading, copying, installing or using the software you agree to this license.
//  If you do not agree to this license, do not download, install,
//  copy or use the software.
//                        Intel License Agreement
//                For Open Source Computer Vision Library
// Copyright (C) 2000, Intel Corporation, all rights reserved.
// Third party copyrights are property of their respective owners.
// Redistribution and use in source and binary forms, with or without modification,
// are permitted provided that the following conditions are met:
//   * Redistribution's of source code must retain the above copyright notice,
//     this list of conditions and the following disclaimer.
//   * Redistribution's in binary form must reproduce the above copyright notice,
//     this list of conditions and the following disclaimer in the documentation
//     and/or other materials provided with the distribution.
//   * The name of Intel Corporation may not be used to endorse or promote products
//     derived from this software without specific prior written permission.
// This software is provided by the copyright holders and contributors "as is" and
// any express or implied warranties, including, but not limited to, the implied
// warranties of merchantability and fitness for a particular purpose are disclaimed.
// In no event shall the Intel Corporation or contributors be liable for any direct,
// indirect, incidental, special, exemplary, or consequential damages
// (including, but not limited to, procurement of substitute goods or services;
// loss of use, data, or profits; or business interruption) however caused
// and on any theory of liability, whether in contract, strict liability,
// or tort (including negligence or otherwise) arising in any way out of
// the use of this software, even if advised of the possibility of such damage.

#ifndef _HIGH_GUI_
#define _HIGH_GUI_


  #include "cxcore.h"
  #if defined WIN32 || defined _WIN32 || defined WIN64 || defined _WIN64
    #include <windows.h>


  #if defined WIN32 || defined _WIN32 || defined WIN64 || defined _WIN64
    #define CV_CDECL __cdecl
    #define CV_STDCALL __stdcall
    #define CV_CDECL
    #define CV_STDCALL

  #ifndef CV_EXTERN_C
    #ifdef __cplusplus
      #define CV_EXTERN_C extern "C"
      #define CV_DEFAULT(val) = val
      #define CV_EXTERN_C
      #define CV_DEFAULT(val)

    #ifdef __cplusplus
      #define CV_EXTERN_C_FUNCPTR(x) extern "C" {
 typedef x; 
      #define CV_EXTERN_C_FUNCPTR(x) typedef x

  #ifndef CV_INLINE
    #if defined __cplusplus
      #define CV_INLINE inline
    #elif (defined WIN32 || defined _WIN32 || defined WIN64 || defined _WIN64) && !defined __GNUC__
      #define CV_INLINE __inline
      #define CV_INLINE static
  #endif /* CV_INLINE */

  #if (defined WIN32 || defined _WIN32 || defined WIN64 || defined _WIN64) && defined CVAPI_EXPORTS
    #define CV_EXPORTS __declspec(dllexport)
    #define CV_EXPORTS

  #ifndef CVAPI
    #define CVAPI(rettype) CV_EXTERN_C CV_EXPORTS rettype CV_CDECL


#if defined(_CH_)
  #pragma package <chopencv>
  #include <chdl.h>

#ifdef __cplusplus
  extern "C" {

#endif /* __cplusplus */

*                                  Basic GUI functions                                   *

/* this function is used to set some external parameters in case of X Window */
CVAPI(int) cvInitSystem( int argc, char** argv );

CVAPI(int) cvStartWindowThread();

/* create window */
CVAPI(int) cvNamedWindow( const char* name, int flags CV_DEFAULT(CV_WINDOW_AUTOSIZE) );

/* display image within window (highgui windows remember their content) */
CVAPI(void) cvShowImage( const char* name, const CvArr* image );

/* resize/move window */
CVAPI(void) cvResizeWindow( const char* name, int width, int height );
CVAPI(void) cvMoveWindow( const char* name, int x, int y );

/* destroy window and all the trackers associated with it */
CVAPI(void) cvDestroyWindow( const char* name );

CVAPI(void) cvDestroyAllWindows(void);

/* get native window handle (HWND in case of Win32 and Widget in case of X Window) */
CVAPI(void*) cvGetWindowHandle( const char* name );

/* get name of highgui window given its native handle */
CVAPI(const char*) cvGetWindowName( void* window_handle );

typedef void (CV_CDECL *CvTrackbarCallback)(int pos);

/* create trackbar and display it on top of given window, set callback */
CVAPI(int) cvCreateTrackbar( const char* trackbar_name, const char* window_name,
                             int* value, int count, CvTrackbarCallback on_change);

typedef void (CV_CDECL *CvTrackbarCallback2)(int pos, void* userdata);

CVAPI(int) cvCreateTrackbar2( const char* trackbar_name, const char* window_name,
                              int* value, int count, CvTrackbarCallback2 on_change,
                              void* userdata CV_DEFAULT(0));

/* retrieve or set trackbar position */
CVAPI(int) cvGetTrackbarPos( const char* trackbar_name, const char* window_name );
CVAPI(void) cvSetTrackbarPos( const char* trackbar_name, const char* window_name, int pos );

#define CV_EVENT_MOUSEMOVE      0
#define CV_EVENT_LBUTTONUP      4
#define CV_EVENT_RBUTTONUP      5
#define CV_EVENT_MBUTTONUP      6

#define CV_EVENT_FLAG_ALTKEY    32

typedef void (CV_CDECL *CvMouseCallback )(int event, int x, int y, int flags, void* param);

/* assign callback for mouse events */
CVAPI(void) cvSetMouseCallback( const char* window_name, CvMouseCallback on_mouse,
                                void* param CV_DEFAULT(NULL));

/* 8bit, color or not */
/* 8bit, gray */
/* ?, color */
#define CV_LOAD_IMAGE_COLOR       1
/* any depth, ? */
/* ?, any color */

/* load image from file
  iscolor can be a combination of above flags where CV_LOAD_IMAGE_UNCHANGED
  overrides the other flags
  unless CV_LOAD_IMAGE_ANYDEPTH is specified images are converted to 8bit
CVAPI(IplImage*) cvLoadImage( const char* filename, int iscolor CV_DEFAULT(CV_LOAD_IMAGE_COLOR));
CVAPI(CvMat*) cvLoadImageM( const char* filename, int iscolor CV_DEFAULT(CV_LOAD_IMAGE_COLOR));


/* save image to file */
CVAPI(int) cvSaveImage( const char* filename, const CvArr* image,
                        const int* params CV_DEFAULT(0) );

/* decode image stored in the buffer */
CVAPI(IplImage*) cvDecodeImage( const CvMat* buf, int iscolor CV_DEFAULT(CV_LOAD_IMAGE_COLOR));
CVAPI(CvMat*) cvDecodeImageM( const CvMat* buf, int iscolor CV_DEFAULT(CV_LOAD_IMAGE_COLOR));

/* encode image and store the result as a byte vector (single-row 8uC1 matrix) */
CVAPI(CvMat*) cvEncodeImage( const char* ext, const CvArr* image,
                             const int* params CV_DEFAULT(0) );

#define CV_CVTIMG_FLIP      1
#define CV_CVTIMG_SWAP_RB   2
/* utility function: convert one image to another with optional vertical flip */
CVAPI(void) cvConvertImage( const CvArr* src, CvArr* dst, int flags CV_DEFAULT(0));

/* wait for key event infinitely (delay<=0) or for "delay" milliseconds */
CVAPI(int) cvWaitKey(int delay CV_DEFAULT(0));

*                         Working with Video Files and Cameras                           *

/* "black box" capture structure */
typedef struct CvCapture CvCapture;

/* start capturing frames from video file */
CVAPI(CvCapture*) cvCreateFileCapture( const char* filename );

#define CV_CAP_ANY      0     // autodetect

#define CV_CAP_MIL      100   // MIL proprietary drivers

#define CV_CAP_VFW      200   // platform native
#define CV_CAP_V4L      200
#define CV_CAP_V4L2     200

#define CV_CAP_FIREWARE 300   // IEEE 1394 drivers
#define CV_CAP_FIREWIRE 300
#define CV_CAP_IEEE1394 300
#define CV_CAP_DC1394   300
#define CV_CAP_CMU1394  300

#define CV_CAP_STEREO   400   // TYZX proprietary drivers
#define CV_CAP_TYZX     400
#define CV_TYZX_LEFT    400
#define CV_TYZX_RIGHT   401
#define CV_TYZX_COLOR   402
#define CV_TYZX_Z       403

#define CV_CAP_QT       500   // QuickTime

#define CV_CAP_UNICAP   600   // Unicap drivers

#define CV_CAP_DSHOW    700   // DirectShow (via videoInput)

/* start capturing frames from camera: index = camera_index + domain_offset (CV_CAP_*) */
CVAPI(CvCapture*) cvCreateCameraCapture( int index );

/* grab a frame, return 1 on success, 0 on fail.
  this function is thought to be fast               */
CVAPI(int) cvGrabFrame( CvCapture* capture );

/* get the frame grabbed with cvGrabFrame(..)
  This function may apply some frame processing like
  frame decompression, flipping etc.
  !!!DO NOT RELEASE or MODIFY the retrieved frame!!! */
CVAPI(IplImage*) cvRetrieveFrame( CvCapture* capture, int streamIdx CV_DEFAULT(0) );

/* Just a combination of cvGrabFrame and cvRetrieveFrame
   !!!DO NOT RELEASE or MODIFY the retrieved fra
(Not finished, please download and read the complete file)
Expand> <Close

Want complete source code? Download it here

Point(s): 1

0 lines left, continue to read
Sponsored links

File list

Tips: You can preview the content of files by clicking file names^_^
Name Size Date
code file algotest.cppalgotest.cpp765.00 B01-09-10 23:47
code file algotest.halgotest.h384.00 B01-09-10 22:27
源码文件 algotest.vcprojalgotest.vcproj3.76 kB19-08-10 23:28
源码文件 algotest.vcproj.YANKE-COMPUTER.Admin.useralgotest.vcproj.YANKE-COMPUTER.Admin.user1.39 kB02-09-10 13:12
code file feret.cppferet.cpp2.95 kB01-09-10 22:56
code file feret_dupI_list.txtferet_dupI_list.txt28.49 kB20-08-10 20:24
code file feret_fa_list.txtferet_fa_list.txt47.38 kB20-08-10 20:20
code file feret_fb_list.txtferet_fb_list.txt47.43 kB20-08-10 20:21
code file feret_fc_list.txtferet_fc_list.txt7.85 kB20-08-10 20:23
code file feret_train_list.txtferet_train_list.txt39.40 kB20-08-10 20:14
源码文件 histModel.bmphistModel.bmp6.37 kB22-06-10 17:55
源码文件 mask.bmpmask.bmp20.39 kB16-05-10 19:26
code file orl.cpporl.cpp1.53 kB01-09-10 22:56
code file cvNotes.txtcvNotes.txt3.50 kB25-06-10 23:13
源码文件 asmlibrary.dllasmlibrary.dll56.00 kB13-12-09 14:49
源码文件 dggev.dlldggev.dll117.50 kB25-08-10 14:24
源码文件 ASM.tifASM.tif900.83 kB10-05-10 22:51
code file asmfitting.hasmfitting.h3.51 kB04-12-09 18:27
code file asmlibrary.hasmlibrary.h24.76 kB28-07-10 21:50
源码文件 asmlibrary.libasmlibrary.lib44.72 kB13-12-09 14:49
code file FaceAlign.hFaceAlign.h605.00 B01-09-10 22:57
code file FaceAlign.rcFaceAlign.rc2.27 kB09-08-10 16:52
源码文件 FaceAlign.vcprojFaceAlign.vcproj4.06 kB16-08-10 13:50
源码文件 FaceAlign.vcproj.YANKE-COMPUTER.Admin.userFaceAlign.vcproj.YANKE-COMPUTER.Admin.user1.38 kB02-09-10 13:12
code file FaceAlign_ASM.cppFaceAlign_ASM.cpp3.30 kB20-08-10 17:21
code file FaceAlign_ASM.hFaceAlign_ASM.h1.88 kB24-08-10 12:11
code file FaceAlign_coord.cppFaceAlign_coord.cpp1.40 kB20-08-10 22:16
code file FaceAlign_coord.hFaceAlign_coord.h630.00 B24-08-10 12:15
code file FaceAlign_Haar.cppFaceAlign_Haar.cpp2.65 kB14-08-10 15:37
code file FaceAlign_Haar.hFaceAlign_Haar.h1.16 kB24-08-10 12:14
code file resource.hresource.h388.00 B08-08-10 20:11
code file FaceFeature.hFaceFeature.h412.00 B17-08-10 23:53
源码文件 FaceFeature.vcprojFaceFeature.vcproj3.96 kB16-08-10 12:08
源码文件 FaceFeature.vcproj.YANKE-COMPUTER.Admin.userFaceFeature.vcproj.YANKE-COMPUTER.Admin.user1.38 kB02-09-10 13:12
code file FaceFeature_Gabor.cppFaceFeature_Gabor.cpp6.30 kB15-08-10 14:04
code file FaceFeature_Gabor.hFaceFeature_Gabor.h2.20 kB20-08-10 17:30
code file FaceFeature_GaborF.cppFaceFeature_GaborF.cpp6.22 kB01-09-10 23:30
code file FaceFeature_GaborF.hFaceFeature_GaborF.h934.00 B20-08-10 17:30
code file FaceFeature_pixel.cppFaceFeature_pixel.cpp452.00 B15-08-10 13:27
code file FaceFeature_pixel.hFaceFeature_pixel.h421.00 B20-08-10 17:30
code file FaceMngr.hFaceMngr.h886.00 B01-09-10 22:57
源码文件 FaceMngr.vcprojFaceMngr.vcproj3.80 kB17-08-10 23:37
源码文件 FaceMngr.vcproj.YANKE-COMPUTER.Admin.userFaceMngr.vcproj.YANKE-COMPUTER.Admin.user1.38 kB02-09-10 13:12
code file FaceMngr_complete.cppFaceMngr_complete.cpp9.99 kB02-09-10 13:00
code file FaceMngr_complete.hFaceMngr_complete.h4.40 kB24-08-10 11:50
code file FaceMngr_fast.cppFaceMngr_fast.cpp6.40 kB02-09-10 12:58
code file FaceMngr_fast.hFaceMngr_fast.h3.47 kB01-09-10 22:52
code file FaceMngr_fast_fast.cppFaceMngr_fast_fast.cpp1.66 kB17-08-10 22:54
code file FaceMngr_fast_fast.hFaceMngr_fast_fast.h1.29 kB17-08-10 22:53
code file orl_func.cpporl_func.cpp1.88 kB17-08-10 22:56
code file config.iniconfig.ini86.00 B14-08-10 15:42
源码文件 frsetup.vdprojfrsetup.vdproj57.66 kB14-08-10 16:08
code file AdvDlg.cppAdvDlg.cpp871.00 B08-08-10 13:56
code file AdvDlg.hAdvDlg.h414.00 B09-08-10 18:11
源码文件 AsmModel.amfAsmModel.amf824.28 kB30-11-09 10:08
code file config.iniconfig.ini171.00 B14-08-10 15:42
code file dlgStuff.cppdlgStuff.cpp3.27 kB09-08-10 18:11
code file EnrollDlg.cppEnrollDlg.cpp9.37 kB14-08-10 17:26
code file EnrollDlg.hEnrollDlg.h1.23 kB09-08-10 18:11
code file frtest.cppfrtest.cpp1.26 kB17-05-10 11:07
code file frtest.hfrtest.h436.00 B09-08-10 18:11
code file frtest.rcfrtest.rc9.06 kB10-07-10 17:16
源码文件 frtest.vcprojfrtest.vcproj6.15 kB14-08-10 15:38
源码文件 frtest.vcproj.YANKE-COMPUTER.Admin.userfrtest.vcproj.YANKE-COMPUTER.Admin.user1.39 kB02-09-10 13:12
code file frtestDlg.cppfrtestDlg.cpp6.56 kB01-09-10 23:32
code file frtestDlg.hfrtestDlg.h1.30 kB09-08-10 18:11
code file haarcascade_frontalface_alt.xmlhaarcascade_frontalface_alt.xml898.31 kB27-09-09 05:48
源码文件 histModel.bmphistModel.bmp6.37 kB22-06-10 17:55
源码文件 mask.bmpmask.bmp20.39 kB16-05-10 19:26
源码文件 noface.bmpnoface.bmp57.47 kB26-05-10 10:57
源码文件 noimage.bmpnoimage.bmp57.47 kB27-05-10 14:03
code file outline.txtoutline.txt852.00 B14-08-10 15:37
code file ProjDefs.hProjDefs.h293.00 B08-08-10 13:32
code file RecogDlg.cppRecogDlg.cpp7.47 kB12-08-10 22:50
code file RecogDlg.hRecogDlg.h1.14 kB12-08-10 21:43
源码文件 frtest.icofrtest.ico66.19 kB28-11-07 16:21
源码文件 frtest.rc2frtest.rc2362.00 B08-05-10 21:51
code file Resource.hResource.h2.37 kB30-06-10 16:38
源码文件 result.bmpresult.bmp57.47 kB26-05-10 10:56
code file stdafx.cppstdafx.cpp353.00 B25-05-10 09:57
code file stdafx.hstdafx.h882.00 B22-06-10 19:55
code file targetver.htargetver.h1.01 kB01-07-10 14:40
code file TrainDlg.cppTrainDlg.cpp1.86 kB08-08-10 13:32
code file TrainDlg.hTrainDlg.h533.00 B09-08-10 18:11
code file WebCam.cppWebCam.cpp2.77 kB08-08-10 13:32
code file WebCam.hWebCam.h1.14 kB08-08-10 13:29
code file WndUtils.cppWndUtils.cpp2.49 kB14-08-10 17:19
code file WndUtils.hWndUtils.h932.00 B14-08-10 17:19
源码文件 frtest.slnfrtest.sln6.00 kB01-09-10 23:43
源码文件 frtest.suofrtest.suo199.50 kB02-09-10 13:12
code file LightPrep.cppLightPrep.cpp5.07 kB15-08-10 14:53
code file LightPrep.hLightPrep.h1.15 kB20-08-10 19:39
源码文件 LightPrep.vcprojLightPrep.vcproj3.59 kB14-08-10 15:38
源码文件 LightPrep.vcproj.YANKE-COMPUTER.Admin.userLightPrep.vcproj.YANKE-COMPUTER.Admin.user1.38 kB02-09-10 13:12
code file cv.hcv.h69.64 kB27-09-09 05:48
code file cv.hppcv.hpp42.87 kB28-09-09 07:34
源码文件 cv200.libcv200.lib454.84 kB22-06-10 16:45
源码文件 cv200d.libcv200d.lib457.17 kB22-06-10 16:35
code file cvcompat.hcvcompat.h39.73 kB22-06-10 16:59
code file cvtypes.hcvtypes.h12.21 kB27-09-09 05:48
code file cvver.hcvver.h2.48 kB01-10-09 00:08
code file cxcore.hcxcore.h85.45 kB27-09-09 05:48
code file cxcore.hppcxcore.hpp79.70 kB22-06-10 16:34
源码文件 cxcore200.libcxcore200.lib406.90 kB22-06-10 16:43
源码文件 cxcore200d.libcxcore200d.lib408.23 kB22-06-10 16:34
code file cxerror.hcxerror.h8.60 kB22-06-10 16:25
code file cxflann.hcxflann.h6.77 kB27-09-09 05:48
code file cxmat.hppcxmat.hpp148.29 kB01-10-09 00:56
code file cxmisc.hcxmisc.h27.40 kB27-09-09 05:48
code file cxoperations.hppcxoperations.hpp84.18 kB01-10-09 00:08
code file cxtypes.hcxtypes.h51.87 kB01-10-09 01:32
源码文件 frtest.suofrtest.suo99.00 kB28-07-10 16:51
code file highgui.hhighgui.h17.74 kB27-09-09 05:48
code file highgui.hpphighgui.hpp4.51 kB27-09-09 05:48
源码文件 highgui200.libhighgui200.lib232.50 kB22-06-10 16:47
源码文件 highgui200d.libhighgui200d.lib233.15 kB22-06-10 16:35
code file PublicHeaders.hPublicHeaders.h518.00 B01-09-10 23:45
code file output.txtoutput.txt26.97 kB19-08-10 19:34
code file pnotes.txtpnotes.txt4.22 kB12-08-10 22:16
code file readme.txtreadme.txt1.79 kB01-09-10 23:57
code file dggev.hdggev.h2.02 kB25-08-10 19:30
源码文件 dggev.libdggev.lib1.64 kB25-08-10 14:24
code file Subspace.cppSubspace.cpp8.01 kB20-08-10 19:43
code file Subspace.hSubspace.h2.21 kB24-08-10 12:30
源码文件 Subspace.vcprojSubspace.vcproj3.65 kB14-08-10 15:38
源码文件 Subspace.vcproj.YANKE-COMPUTER.Admin.userSubspace.vcproj.YANKE-COMPUTER.Admin.user1.38 kB02-09-10 13:12
源码文件 svn-commit.tmpsvn-commit.tmp42.00 B02-09-10 11:08
code file tnotes.txttnotes.txt1.27 kB30-08-10 18:51
code file CompDefs.hCompDefs.h162.00 B14-08-10 12:45
code file cvTools.cppcvTools.cpp5.17 kB17-08-10 10:08
code file FreqTools.cppFreqTools.cpp5.29 kB20-08-10 19:46
源码文件 tools.deftools.def15.00 B28-07-10 21:30
code file tools.htools.h3.97 kB20-08-10 19:46
源码文件 tools.vcprojtools.vcproj4.04 kB14-08-10 15:38
源码文件 tools.vcproj.YANKE-COMPUTER.Admin.usertools.vcproj.YANKE-COMPUTER.Admin.user1.38 kB02-09-10 13:12
源码文件 程序文档.doc程序文档.doc45.50 kB24-08-10 22:01
源码文件 <res><res>0.00 B20-08-10 22:06
源码文件 <algotest><algotest>0.00 B02-09-10 13:13
源码文件 <exe><exe>0.00 B02-09-10 13:14
源码文件 <FaceAlign><FaceAlign>0.00 B02-09-10 13:13
源码文件 <FaceFeature><FaceFeature>0.00 B02-09-10 13:13
源码文件 <FaceMngr><FaceMngr>0.00 B02-09-10 13:13
源码文件 <frsetup><frsetup>0.00 B20-08-10 22:06
源码文件 <frtest><frtest>0.00 B02-09-10 13:13
源码文件 <LightPrep><LightPrep>0.00 B02-09-10 13:13
源码文件 <opencv><opencv>0.00 B01-09-10 23:45
源码文件 <Subspace><Subspace>0.00 B02-09-10 13:13
源码文件 <tools><tools>0.00 B02-09-10 13:13
源码文件 <frtest_dlls><frtest_dlls>0.00 B01-08-12 22:35
Sponsored links

highgui.h (1.42 MB)

Need 1 point
Your Point(s)

Your Point isn't enough.

Get point immediately by PayPal

More(Debit card / Credit card / PayPal Credit / Online Banking)

Submit your source codes. Get more point



Don't have an account? Register now
Need any help?
Mail to: support@codeforge.com


CodeForge Chinese Version
CodeForge English Version

Where are you going?


^_^"Oops ...

Sorry!This guy is mysterious, its blog hasn't been opened, try another, please!

Warm tip!

CodeForge to FavoriteFavorite by Ctrl+D