Mailing List archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[linux-dvb] Re: Linux DVB API 4 Q's






> >  > So both DVB_DMX_START and DVB_DMX_STOP ioctls in this case would
have to
> >  > have a handle to the filter required.  In this case, why not specify
the
> >  > pid value as in the proposition for the ADD/DEL ioctl above?
> >
> > For the ADD/DEL ioctl I agree. For the application you are
> > describing using one fd for each channel might make more sense. This
> > way, you setup the PIDs for each channel on separate fds and can
> > start/stop them all at once. You will also already get the packets for
> > each channel in separate buffers (or do you want them in one big TS?).

> Exactly my thinking. In the V4 dmx.h I have:

> //FIXME: necessary? relationship to set filter?
> #define DVB_DMX_START _IO(DVB_IOCTL_BASE, 0x28)
> #define DVB_DMX_STOP  _IO(DVB_IOCTL_BASE, 0x29)

> The reason for the FIXME comment is: I never ever used a filter without
> the DVB_DMX_IMMEDIATE_START flag, i.e. DVB_DMX_START is superfluous.

> The reason for the other FIXME for DVB_DMX_IMMEDIATE_START: If we have
> DVB_DMX_START, it's superfluous; if we don't, it's superfluous, too.
> Tell me if you think different.

Yes, I agree that both do the same thing effectively, but.....

> Also, DVB_DMX_STOP is superfluous because you can just close the fd.

Agreed. Unless we change "close" to return EBUSY saying that you need to
stop a running filter first.  That's just another syscall to slow things
down though.

> OK, one reason to have DVB_DMX_START would be:
> - setup many filters on one fd
> - then start them all at the same time, ensuring that the recorded
>   stream starts properly muxed and not e.g. with just video before the
>   audio filters kick in

> Another reason to have START/STOP would be for temporarily pausing
> all filters on a fd and later resume. Like I said, I never needed that.

> Tell me what you think about it.

.... I need to be able to setup many filters on an fd and then hit the "go
button" to make them active.  Like I said before, it would be nice then to
stop or close filters that you don't need on the fly and add some new ones
altogether and start them all at once on the same fd.

e.g. Currently recording BBC1, then without interruption we want to record
BBC2 as well on the same fd (i.e. the same TS going to the hdd through
whatever h/w that may be between the demux and hdd.  We would need the
ability to add extra PID filters to the existing fd (e.g. audio, video,
subtitle) and then hit the go button on this group so as to get sync.

Maybe having a bitmask that we pass as an arg that says which PID filters
to stop/start would allow this individual/group functionality.  It gets a
bit messy with trying to link a PID value to a bitmask though.  What about
passing in a pointer to a linked list or a fixed size array of PID values
to start/stop?

Ahh, maybe if we implement your DVB_DMX_SET_PID_FILTER with an array of
PIDs to set and start immediately using the DVB_DMX_IMMEDIATE_START flag,
we can nicely obtain this requirement.

Do these ideas sound reasonable?

Rob : )






-- 
Info:
To unsubscribe send a mail to ecartis@linuxtv.org with "unsubscribe linux-dvb" as subject.



Home | Main Index | Thread Index