#include <vlc_plugin.h>
#include <vlc_filter.h>
#include <vlc_vout.h>
-#include "filter_common.h"
#include <vlc_image.h>
#include "filter_event_info.h"
set_subcategory( SUBCAT_VIDEO_VFILTER2 )
set_callbacks( OpenFilter, CloseFilter )
- add_string( "opencv-haarcascade-file", "c:\\haarcascade_frontalface_alt.xml", NULL,
+ add_string( "opencv-haarcascade-file", "c:\\haarcascade_frontalface_alt.xml",
N_("Haar cascade filename"),
N_("Name of XML file containing Haar cascade description"), false);
vlc_module_end ()
/****************************************************************************
* Filter: Check for faces and raises an event when one is found.
- ****************************************************************************
- * p_pic: A picture_t with its p_data_orig member set to an array of
- * IplImages (one image for each picture_t plane).
****************************************************************************/
static picture_t *Filter( filter_t *p_filter, picture_t *p_pic )
{
msg_Err( p_filter, "no image array" );
return NULL;
}
- if (!(p_pic->p_data_orig))
- {
- msg_Err( p_filter, "no image array" );
- return NULL;
- }
//(hack) cast the picture_t to array of IplImage*
- p_img = (IplImage**) p_pic->p_data_orig;
+ p_img = (IplImage**) p_pic->p[0].p_pixels;
i_planes = p_pic->i_planes;
//check the image array for validity