Commit 361fa06f authored by Simon Morlat's avatar Simon Morlat
Browse files

remove useless and unimplemented function ms_filter_get_factory(), which was breaking compilation

parent 25754e7b
......@@ -246,12 +246,7 @@ extern "C"{
*/
MS2_PUBLIC MS2_DEPRECATED void ms_filter_register(MSFilterDesc *desc);
/**
* Get the factory that created a filter.
* @param[in] f MSFilter object
* @return The MSFactory that created the filter
*/
MS2_PUBLIC struct _MSFactory * ms_filter_get_factory(MSFilter *f);
/**
* Retrieve capture filter that supports encoding to codec name.
......
......@@ -75,7 +75,6 @@ typedef struct V4lState{
bool_t v4lv2; /*we interface with a V4Lv2 driver */
bool_t force_v1;
bool_t auto_started;
MSFactory *factory;
}V4lState;
static void *v4l_thread(void *s);
......@@ -293,7 +292,6 @@ static void v4l_init(MSFilter *f){
s->queued=0;
s->force_v1=FALSE;
s->auto_started=FALSE;
s->factory = ms_filter_get_factory(f);
f->data=s;
}
......@@ -771,10 +769,10 @@ static mblk_t * v4l_make_mire(V4lState *s){
return s->mire;
}
static mblk_t * v4l_make_nowebcam(V4lState *s){
static mblk_t * v4l_make_nowebcam(MSFilter * f, V4lState *s){
if (s->mire==NULL && s->frame_ind==0){
#if !defined(NO_FFMPEG)
s->mire=ms_load_nowebcam(s->factory, &s->vsize, -1);
s->mire=ms_load_nowebcam(f->factory, &s->vsize, -1);
#endif
}
s->frame_ind++;
......@@ -914,7 +912,7 @@ static void v4l_process(MSFilter * obj){
if (s->usemire){
om=dupmsg(v4l_make_mire(s));
}else {
mblk_t *tmpm=v4l_make_nowebcam(s);
mblk_t *tmpm=v4l_make_nowebcam(obj, s);
if (tmpm) {
om=dupmsg(tmpm);
mblk_set_precious_flag(om,1);
......
......@@ -72,7 +72,6 @@ typedef struct V4wState{
int frame_count;
bool_t running;
bool_t startwith_yuv_bug; /* avoid bug with USB vimicro cards. */
MSFactory *factory;
}V4wState;
static V4wState *s_callback=NULL;
......@@ -624,8 +623,6 @@ static void v4w_init(MSFilter *f){
s->start_time=0;
s->frame_count=-1;
s->fps=15;
s->factory = ms_filter_get_factory(f);
f->data=s;
}
......@@ -841,7 +838,7 @@ static void v4w_uninit(MSFilter *f){
ms_free(s);
}
static mblk_t * v4w_make_nowebcam(V4wState *s){
static mblk_t * v4w_make_nowebcam(MSFilter *f, V4wState *s){
#if defined(_WIN32_WCE)
return NULL;
#else
......@@ -851,12 +848,12 @@ static mblk_t * v4w_make_nowebcam(V4wState *s){
/* load several images to fake a movie */
for (idx=0;idx<10;idx++)
{
s->mire[idx]=ms_load_nowebcam(s->factory, &s->vsize, idx);
s->mire[idx]=ms_load_nowebcam(f->factory, &s->vsize, idx);
if (s->mire[idx]==NULL)
break;
}
if (idx==0)
s->mire[0]=ms_load_nowebcam(s->factory, &s->vsize, -1);
s->mire[0]=ms_load_nowebcam(f->factory, &s->vsize, -1);
}
for (count=0;count<10;count++)
{
......@@ -910,7 +907,7 @@ static void v4w_process(MSFilter * obj){
om=m;
}
}else {
mblk_t *nowebcam = v4w_make_nowebcam(s);
mblk_t *nowebcam = v4w_make_nowebcam(obj, s);
if (nowebcam!=NULL)
om=dupmsg(nowebcam);
}
......
......@@ -59,7 +59,6 @@ typedef struct V4wState{
bool_t started;
bool_t autostarted;
bool_t invert_rgb;
MSFactory *factory;
}V4wState;
static void dummy(void*p){
......@@ -272,8 +271,6 @@ static void v4w_init(MSFilter *f){
ms_cond_init(&s->thread_cond,NULL);
s->thread_running = FALSE;
#endif
s->factory = ms_filter_get_factory(f);
f->data=s;
}
......@@ -446,19 +443,19 @@ static void v4w_uninit(MSFilter *f){
ms_free(s);
}
static mblk_t * v4w_make_nowebcam(V4wState *s){
static mblk_t * v4w_make_nowebcam(MSFilter *f, V4wState *s){
int idx;
int count;
if (s->mire[0]==NULL && s->frame_ind==0){
/* load several images to fake a movie */
for (idx=0;idx<10;idx++)
{
s->mire[idx]=ms_load_nowebcam(s->factory, &s->vsize, idx);
s->mire[idx]=ms_load_nowebcam(f->factory, &s->vsize, idx);
if (s->mire[idx]==NULL)
break;
}
if (idx==0)
s->mire[0]=ms_load_nowebcam(s->factory, &s->vsize, -1);
s->mire[0]=ms_load_nowebcam(f->factory, &s->vsize, -1);
}
for (count=0;count<10;count++)
{
......@@ -533,7 +530,7 @@ static void v4w_process(MSFilter * obj){
}
}
}else {
mblk_t *nowebcam = v4w_make_nowebcam(s);
mblk_t *nowebcam = v4w_make_nowebcam(obj, s);
if (nowebcam!=NULL){
om=dupmsg(nowebcam);
mblk_set_precious_flag(om,1);
......
......@@ -69,7 +69,6 @@ typedef struct V4wState{
float fps;
uint64_t start_time;
int frame_count;
MSFactory *factory;
}V4wState;
static V4wState *s_callback=NULL;
......@@ -1021,8 +1020,6 @@ static void v4w_init(MSFilter *f){
s->frame_count=-1;
s->fps=15;
memset(s->dev, 0, sizeof(s->dev));
s->factory = ms_filter_get_factory(f);
f->data=s;
}
......@@ -1196,7 +1193,7 @@ static void v4w_uninit(MSFilter *f){
ms_free(s);
}
static mblk_t * v4w_make_nowebcam(V4wState *s){
static mblk_t * v4w_make_nowebcam(MSFilter *f, V4wState *s){
#if defined(_WIN32_WCE)
return NULL;
#else
......@@ -1210,12 +1207,12 @@ static mblk_t * v4w_make_nowebcam(V4wState *s){
/* load several images to fake a movie */
for (idx=0;idx<10;idx++)
{
s->mire[idx]=ms_load_nowebcam(s->factory, &s->vsize, idx);
s->mire[idx]=ms_load_nowebcam(f->factory, &s->vsize, idx);
if (s->mire[idx]==NULL)
break;
}
if (idx==0)
s->mire[0]=ms_load_nowebcam(s->factory, &s->vsize, -1);
s->mire[0]=ms_load_nowebcam(f->factory, &s->vsize, -1);
}
for (count=0;count<10;count++)
{
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment