public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-user] Help playing simultaneously splitted videos (sort of)
@ 2007-05-13 15:41 Javier Krausbeck
  2007-05-13 19:27 ` YoYo Siska
  0 siblings, 1 reply; 8+ messages in thread
From: Javier Krausbeck @ 2007-05-13 15:41 UTC (permalink / raw
  To: gentoo-user

Hi there,

I've been asked something strange. I have to take a video input and split it 
in three parts, sending it to three outputs simultaneously.

The first thing I thought of was creating a pipe, sending there the video and 
trying to read from there. I did my firsts tests with mplayer, but as soon as 
I launched the second instance of the video output, the mplayer which was 
feeding the pipe exited.

Does any of you have any good idea to accomplish this in a simple and elegant 
way?

Probably I should be focusing more on the capturing more than doing this 
rubbish tests, nonetheless, since I still don't have any hardware to do 
anything proper, any feedback will be wellcome ;)


-- 
Javier Krausbeck <javier@krausbeck.org>
-- 
gentoo-user@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [gentoo-user] Help playing simultaneously splitted videos (sort of)
  2007-05-13 15:41 [gentoo-user] Help playing simultaneously splitted videos (sort of) Javier Krausbeck
@ 2007-05-13 19:27 ` YoYo Siska
  2007-05-13 23:20   ` [gentoo-user] Real time video streaming (was: Help playing simultaneously splitted videos (sort of)) Javier Krausbeck
  0 siblings, 1 reply; 8+ messages in thread
From: YoYo Siska @ 2007-05-13 19:27 UTC (permalink / raw
  To: gentoo-user

Javier Krausbeck wrote:
> Hi there,
> 
> I've been asked something strange. I have to take a video input and split it 
> in three parts, sending it to three outputs simultaneously.
> 
> The first thing I thought of was creating a pipe, sending there the video and 
> trying to read from there. I did my firsts tests with mplayer, but as soon as 
> I launched the second instance of the video output, the mplayer which was 
> feeding the pipe exited.
> 
> Does any of you have any good idea to accomplish this in a simple and elegant 
> way?

just expanding your idea with pipes:

mkfifo f1
mkfifo f2
mkfifo f3
mplayer  whatever_options_you_want_and_make_it_write_to_stdout  | tee f1
| tee f2 >f3

and then reading from f1, f2, f3 doesn't do the thing you want ?

yoyo


-- 
gentoo-user@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 8+ messages in thread

* [gentoo-user] Real time video streaming (was: Help playing simultaneously splitted videos (sort of))
  2007-05-13 19:27 ` YoYo Siska
@ 2007-05-13 23:20   ` Javier Krausbeck
  2007-05-14  0:02     ` [gentoo-user] " Grant Edwards
  0 siblings, 1 reply; 8+ messages in thread
From: Javier Krausbeck @ 2007-05-13 23:20 UTC (permalink / raw
  To: gentoo-user

On Sunday 13 May 2007, YoYo Siska wrote:

> > I've been asked something strange. I have to take a video input and split
> > it in three parts, sending it to three outputs simultaneously.

> > The first thing I thought of was creating a pipe, sending there the video
> > and trying to read from there. I did my firsts tests with mplayer, but as
> > soon as I launched the second instance of the video output, the mplayer
> > which was feeding the pipe exited.

> > Does any of you have any good idea to accomplish this in a simple and
> > elegant way?

> just expanding your idea with pipes:

> mkfifo f1
> mkfifo f2
> mkfifo f3
> mplayer  whatever_options_you_want_and_make_it_write_to_stdout  | tee f1

> | tee f2 >f3

> and then reading from f1, f2, f3 doesn't do the thing you want ?

Just one caveat, mplayer does not do output to stdout, you only have the 
option of using yuv4mpeg as video out, which means a pipe. I tried catting 
this first pipe to multiple ones, but as I guessed, it didn't work.

Anyway, the more I think about it, the less I like it. Let's say it it's not 
elegant at all. Much less nice. I think the best way would be streaming the 
video and do various reads of it, showing different parts of the video on 
each of the clients.

So far I only know of vlc. Is there any other software which can do streaming 
of video only (I don't need sound) to multiple clients (on the same machine)?

Besides, I don't need it to travel multiple routers or anything like that.
My only constraint is that it has to be real time, all the clients need to 
synchronized.


-- 
Javier Krausbeck <javier@krausbeck.org>
-- 
gentoo-user@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 8+ messages in thread

* [gentoo-user]  Re: Real time video streaming (was: Help playing simultaneously splitted videos (sort of))
  2007-05-13 23:20   ` [gentoo-user] Real time video streaming (was: Help playing simultaneously splitted videos (sort of)) Javier Krausbeck
@ 2007-05-14  0:02     ` Grant Edwards
  2007-05-14  3:25       ` Boyd Stephen Smith Jr.
  0 siblings, 1 reply; 8+ messages in thread
From: Grant Edwards @ 2007-05-14  0:02 UTC (permalink / raw
  To: gentoo-user

On 2007-05-13, Javier Krausbeck <gentoo@krausbeck.org> wrote:

>> mkfifo f1
>> mkfifo f2
>> mkfifo f3
>> mplayer  whatever_options_you_want_and_make_it_write_to_stdout  | tee f1
>
>> | tee f2 >f3
>
>> and then reading from f1, f2, f3 doesn't do the thing you want ?
>
> Just one caveat, mplayer does not do output to stdout,

So use another fifo.

-- 
Grant Edwards
grante@visi.com

-- 
gentoo-user@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [gentoo-user]  Re: Real time video streaming (was: Help playing simultaneously splitted videos (sort of))
  2007-05-14  0:02     ` [gentoo-user] " Grant Edwards
@ 2007-05-14  3:25       ` Boyd Stephen Smith Jr.
  2007-05-16 14:04         ` Javier Krausbeck
  0 siblings, 1 reply; 8+ messages in thread
From: Boyd Stephen Smith Jr. @ 2007-05-14  3:25 UTC (permalink / raw
  To: gentoo-user

[-- Attachment #1: Type: text/plain, Size: 903 bytes --]

On Sunday 13 May 2007, Grant Edwards <grante@visi.com> wrote 
about '[gentoo-user]  Re: Real time video streaming (was: Help playing 
simultaneously splitted videos (sort of))':
> On 2007-05-13, Javier Krausbeck <gentoo@krausbeck.org> wrote:
> >> mkfifo f1
> >> mkfifo f2
> >> mkfifo f3
> >> mplayer  whatever_options_you_want_and_make_it_write_to_stdout  | tee
> >> f1
> >>
> >> | tee f2 >f3
> >
> > Just one caveat, mplayer does not do output to stdout,
>
> So use another fifo.

To elaborate:

mkfifo queue
mkfifo vo1
mkfifo vo2
mkfifo vo3
mplayer lots_of_options_and_write_output_to queue &
tee vo1 < queue | tee vo2 > vo3 &

or similar.

-- 
Boyd Stephen Smith Jr.                     ,= ,-_-. =. 
bss03@volumehost.net                      ((_/)o o(\_))
ICQ: 514984 YM/AIM: DaTwinkDaddy           `-'(. .)`-' 
http://iguanasuicide.org/                      \_/     

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [gentoo-user]  Re: Real time video streaming (was: Help playing simultaneously splitted videos (sort of))
  2007-05-14  3:25       ` Boyd Stephen Smith Jr.
@ 2007-05-16 14:04         ` Javier Krausbeck
  2007-05-16 15:49           ` Pongracz Istvan
  2007-05-16 16:35           ` [gentoo-user] Re: Real time video streaming YoYo Siska
  0 siblings, 2 replies; 8+ messages in thread
From: Javier Krausbeck @ 2007-05-16 14:04 UTC (permalink / raw
  To: gentoo-user

On Monday 14 May 2007, Boyd Stephen Smith Jr. wrote:

> simultaneously splitted videos (sort of))':

> > >> mkfifo f1
> > >> mkfifo f2
> > >> mkfifo f3
> > >> mplayer  whatever_options_you_want_and_make_it_write_to_stdout  | tee
> > >> f1

> > >> | tee f2 >f3

> > > Just one caveat, mplayer does not do output to stdout,

> > So use another fifo.

> To elaborate:

> mkfifo queue
> mkfifo vo1
> mkfifo vo2
> mkfifo vo3
> mplayer lots_of_options_and_write_output_to queue &
> tee vo1 < queue | tee vo2 > vo3 &

> or similar.

I'm sorry to say that it just doesn't work.
There's no way of getting two reads from the initial fifo mplayer creates.

I'm trying to find the kernel patch that makes FIFOs readable in parallel by 
several processes. But, damn it, I can't find it right now.


-- 
Javier Krausbeck <javier@krausbeck.org>
-- 
gentoo-user@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [gentoo-user]  Re: Real time video streaming (was: Help playing simultaneously splitted videos (sort of))
  2007-05-16 14:04         ` Javier Krausbeck
@ 2007-05-16 15:49           ` Pongracz Istvan
  2007-05-16 16:35           ` [gentoo-user] Re: Real time video streaming YoYo Siska
  1 sibling, 0 replies; 8+ messages in thread
From: Pongracz Istvan @ 2007-05-16 15:49 UTC (permalink / raw
  To: gentoo-user

Hi,

Use vloopback.
I never tried to split one input to several, but who knows ?

REgards,
IStván
-- 
IT szolgáltatások, alkalmazásszolgáltatás
http://www.osbusiness.hu

-- 
gentoo-user@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [gentoo-user]  Re: Real time video streaming
  2007-05-16 14:04         ` Javier Krausbeck
  2007-05-16 15:49           ` Pongracz Istvan
@ 2007-05-16 16:35           ` YoYo Siska
  1 sibling, 0 replies; 8+ messages in thread
From: YoYo Siska @ 2007-05-16 16:35 UTC (permalink / raw
  To: gentoo-user

Javier Krausbeck wrote:

>> To elaborate:
> 
>> mkfifo queue
>> mkfifo vo1
>> mkfifo vo2
>> mkfifo vo3
>> mplayer lots_of_options_and_write_output_to queue &
>> tee vo1 < queue | tee vo2 > vo3 &
> 
>> or similar.
> 
> I'm sorry to say that it just doesn't work.
> There's no way of getting two reads from the initial fifo mplayer creates.
I don't understand.
You don't need to do multiple reads from the fifo that mplayer writes to
(queue). Only one tee process (the first in the command) reads from it,
it "doubles" it and writes it to vo1 and its  stdout, and the second tee
reads that and doubles it again into vo2 and vo3. So after running that
command you can read simlutaneosly from vo1-3
(well you _have_ to read from all of them, otherwise tee will pause
writing to others)

yoyo
-- 
gentoo-user@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2007-05-16 16:44 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-05-13 15:41 [gentoo-user] Help playing simultaneously splitted videos (sort of) Javier Krausbeck
2007-05-13 19:27 ` YoYo Siska
2007-05-13 23:20   ` [gentoo-user] Real time video streaming (was: Help playing simultaneously splitted videos (sort of)) Javier Krausbeck
2007-05-14  0:02     ` [gentoo-user] " Grant Edwards
2007-05-14  3:25       ` Boyd Stephen Smith Jr.
2007-05-16 14:04         ` Javier Krausbeck
2007-05-16 15:49           ` Pongracz Istvan
2007-05-16 16:35           ` [gentoo-user] Re: Real time video streaming YoYo Siska

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox