Hi,
i have the .avi file. 4 video channels are multiplexed in it. how to demultiplex this video and display it as a quad screen view. like ch1 -cam1, ch-2 cam2, ch-3 cam3 ,ch-4 cam4..pls help me out..
Azhagiri.s
Try StreamFab Downloader and download from Netflix, Amazon, Youtube! Or Try DVDFab and copy Blu-rays! or rip iTunes movies!
+ Reply to Thread
Results 1 to 26 of 26
Thread
-
-
What is the source?
Most cam systems that I've dealt with do not create a video file with multiple video streams/channels. The recording hardware simply combines all of the cam inputs into a single video stream.Google is your Friend -
Hi, Krispy Kritter
Thank u for your reply. The video source which we are getting from one dvr. one electronic unit which multiplexes the 4 camera inputs and give it to recorder. the recorder output is PAL standard multiplexed video. Composite or S-video. this video i have to demultiplex it as a quad screen. based on which things we can split the frames source and display it. -
there is not agreement between what VH members here would normally refer to as multiplexed (or demultiplexed) compared to what YOU seem to be referring to. in fact those terms mean a number of things under different contexts.
give us the details on the model of your camera & recorder system.
older analog systems similar to what you are talking about did a quad split composite (aka 4-way pip - picture in picture) merged onto one image.
other older analog systems did a time sequential interleave (a then b then c then d then a again...) continually alernating
some modern digital systems save multiple independent streams as "layers" within a single file, where the "player" lays them out as a quad split in playback, though they are still discreet
all of those formats have at one time or another been termed "multiplexed".
yours could be one of those or something else altogether.
need more info...
scott -
Hi Scott..
We don t know the system using which camera.. but this system is an older version of analog system. which multiplexes the 4 video channels, this system will give 1 video output (composite- 4 channels muxed).
We use this multiplexed output for recording. the multiplexing unit have the 16 different preset settings based on this settings the video will get multiplexed. now i have to split this multiplexed video in to quad screen.
Preset will be (1-16)
Preset 1 CH-1 [100%], CH-2 [0%], CH-3 [0%], CH-4 [0%]
.....
Preset 11 CH-1 [25%], CH-2 [25%], CH-3 [25%], CH-4 [25%]
up to 16..
the camera input will be 4 cameras (visual, color bar1,color bar2,color bar3)
azhagiri.s -
That's no better than the first time!!
Repeat exactly what you just said, without using the term "muxed" or "multiplexed" (to avoid circular reference). Use a term which either electrically, visually, mathematically, or software-logically describes what's happening.
What do you mean you "don't know the system"? Can't you look at the back/side/top/front of the cameras or device? Isn't there a manual? How do you know how to work it, then?
Do you have a screen cap sample?
So the settings are a composite PIP quad split arrangement, with the "presets" determining channel priority? If so, why didn't you just say "it's like your 1st example."?
Assuming that is correct, you now need to describe (in enough detail) what your edit system is. Do you know how to use AVISynth? ffmpeg? Which cam(s) did you want to work with?
Scott -
Here the system means multiplexing unit.
Multiplexing unit is an older version of analog system. which multiplexes the 4 video channels, this system will give 1 video (composite output).
We use this output for recording. the system have the 16 different preset settings based on this settings the video will get multiplexed. now i have to split this video in to quad screen.
Preset will be (1-16)
Preset 1 CH-1 [100%], CH-2 [0%], CH-3 [0%], CH-4 [0%]
.....
Preset 11 CH-1 [25%], CH-2 [25%], CH-3 [25%], CH-4 [25%]
up to 16..
the camera input will be 4 cameras (visual, color bar1,color bar2,color bar3)
the camera used here is dome cctv security camera.
azhagiri.s -
You STILL have not been clear about what you have, nor about what you want to have DONE to it.
That module is a Video Processing S.O.C. What is your "development" intention? I'm not a mind reader.
I asked you to rephrase your statement WITHOUT using that ambiguous term, yet you chose to repeat it almost verbatim USING that term!
I'm seriously losing patience with this: speak plainly or I won't be responding further.
Scott -
Sir,
We are working with the TMS320DM6446 Davinci evaluation module. it is video processing soc (ARM+DSP) dual core system.
our task is to record the multiplexed video in to a solid state memory device (compact flash). when play back we have to demux the
recorded video, split and display it as quad window.
Only the information we have about the multiplexing unit is preset inputs. how to find the video source from the video and display it..
azhagiri -
The source hardware (ie: the device that is providing the "multiplexed" composite signal) is required. Once the hardware is known, the exact video type can be determined. A sample of the video output may help as well.
Next, we need to understand what you are wanting to do.
You should already be able to view and/or capture/record the video. No processing of any type should be needed to view or store the video. So we need to know what you are trying to do.Google is your Friend -
Ok, that at least got us somewhere!
That is not a "multiplexed" stream in the sense of discreet independent multiple views encapsulated within the one container file.
Neither is that a quad-split overlay PIP type of multiplexed video.
Rather, it is a time-sequential interleave type of multiplexed video (which only the security world even refer to as multiplexed).
This is easily "de-multiplexed" by using a video processor (such as AVISynth script) that saves each 4th image to its own stream of the 4.
However, I note that your file is corrupted and doesn't even follow its own pattern. Occasionally there is a loss of 1 or part of 1 frame. This will make extraction MUCH more difficult. Better to see why it is being created that way: is it a problem with interlacing? with frame-dropping? with HDD corruption? with a bad source file(s)? bad DV compression?
Once that is figured out, and you have (again?) 4 separate video streams, you can re-process them to the way you'd like, such as a quad split. This is also easily doable in AVISynth.
Since you seemed to be unfamiliar with AVISynth, you need to let us know on WHAT PLATFORM and API you are intending to utilize this. Also, is this a general, recurring job or is this a one-off?
Scott
(see what more info you can get when you actually play ball?!)Last edited by Cornucopia; 27th Jan 2015 at 06:42.
-
Here's what Cornucopia suggested:
1. Download and install Avisynth 2.6 from http://avisynth.nl/index.php/Main_Page
2. create a FFMS2 folder inside your avisynth plugins folder (C:\Program Files (x86)\AviSynth 2.6\plugins)
3. Download FFMS2 from https://github.com/FFMS/ffms2/releases and extract the content of the x86 folder and the FFMS2.avsi into the FFMS2 folder you created.
4. create a text file and name it test.avs
Inside the .avs file write the the following (and save the file):
Code:LoadCPlugin("C:\Program Files (x86)\AviSynth 2.6\plugins\FFMS2\ffms2.dll") # here you need to adjust the path to the ffms2.dll Import("C:\Program Files (x86)\AviSynth 2.6\plugins\FFMS2\FFMS2.avsi") # here you need to adjust the path to the FFMS2.avsi FFVideoSource("C:\Users\Selur\Desktop\UVS141~1.AVI") # here you need to adjust the path to your input file bob() # deinterleces the video by bobbing selecteven() # throws out every odd field FFInfo(frametype = false, cfrtime = false, vfrtime = false) # shows the frame number inside the upper left corner v1 = SelectEvery(4,1).Subtitle("1 of 4", align=9) # shows that this is the first of every four frames inside the upper right corner v2 = SelectEvery(4,2).Subtitle("2 of 4", align=9) # shows that this is the second of every four frames inside the upper right corner v3 = SelectEvery(4,3).Subtitle("3 of 4", align=9) # shows that this is the third of every four frames inside the upper right corner v4 = SelectEvery(4,4).Subtitle("4 of 4", align=9) # shows that this is the fourth of every four frames inside the upper right corner return StackVertical(StackHorizontal(v1,v2), StackHorizontal(v3,v4)) # arranges the different views
Scrolling through the frames in Virtual Dub one can clearly see that the interleaving of your streams isn't done consistently which is why the camera views change.
---------------
Seeing that you are using a C++ development enviroment which is ment for embedded developing, this way to approach the problem is probably not what you are looking for. -> Your programmers might want to look into libav and ffmpegsource2.
Cu Selurusers currently on my ignore list: deadrats, Stears555 -
i tried as per your guidance..
i am getting the following error.. image i attached..
* The problems which i faced during this downloading of this avi synth from the website u suggested. it shows the version name is 2.5, when i installed it shows 2.6 on the installation screen.
The test.avs which i used is
LoadCPlugin("C:\Program Files (x86)\AviSynth 2.6\plugins\FFMS2\ffms2.dll") # here you need to adjust the path to the ffms2.dll
Import("C:\Program Files (x86)\AviSynth 2.6\plugins\FFMS2\FFMS2.avsi") # here you need to adjust the path to the FFMS2.avsi
FFVideoSource("C:\Users\Selur\Desktop\UVS141~1.AVI ") # here you need to adjust the path to your input file
bob() # deinterleces the video by bobbing
selecteven() # throws out every odd field
FFInfo(frametype = false, cfrtime = false, vfrtime = false) # shows the frame number inside the upper left corner
v1 = SelectEvery(4,1).Subtitle("1 of 4", align=9) # shows that this is the first of every four frames inside the upper right corner
v2 = SelectEvery(4,2).Subtitle("2 of 4", align=9) # shows that this is the second of every four frames inside the upper right corner
v3 = SelectEvery(4,3).Subtitle("3 of 4", align=9) # shows that this is the third of every four frames inside the upper right corner
v4 = SelectEvery(4,4).Subtitle("4 of 4", align=9) # shows that this is the fourth of every four frames inside the upper right corner
return StackVertical(StackHorizontal(v1,v2), StackHorizontal(v3,v4)) # arranges the different views
-------------------------------
and the pc which i am using is
Microsoft Windows XP
Version 2002 service pack 2
--------------------------------------
What could be the problem? -
Change 'LoadCPlugin' to 'LoadPlugin' (I'm using a modified version from http://forum.doom9.org/showthread.php?t=127037&page=49 which is a CPlugin)
users currently on my ignore list: deadrats, Stears555 -
i changed from LoadcPlugin to loadplugin in the test.avs file. still i am getting avi synth open failure.
.avs file i used
LoadPlugin("C:\Program Files\AviSynth 2.6\plugins\FFMS2\ffms2.dll") # here you need to adjust the path to the ffms2.dll
Import("C:\Program Files\AviSynth 2.6\plugins\FFMS2\FFMS2.avsi") # here you need to adjust the path to the FFMS2.avsi
FFVideoSource("C:\Documents and Settings\azhagiri\Desktop\123.AVI") # here you need to adjust the path to your input file
bob() # deinterleces the video by bobbing
selecteven() # throws out every odd field
FFInfo(frametype = false, cfrtime = false, vfrtime = false) # shows the frame number inside the upper left corner
v1 = SelectEvery(4,1).Subtitle("1 of 4", align=9) # shows that this is the first of every four frames inside the upper right corner
v2 = SelectEvery(4,2).Subtitle("2 of 4", align=9) # shows that this is the second of every four frames inside the upper right corner
v3 = SelectEvery(4,3).Subtitle("3 of 4", align=9) # shows that this is the third of every four frames inside the upper right corner
v4 = SelectEvery(4,4).Subtitle("4 of 4", align=9) # shows that this is the fourth of every four frames inside the upper right corner
return StackVertical(StackHorizontal(v1,v2), StackHorizontal(v3,v4)) # arranges the different views
The error image i attached here. -
Just use i just replaced AVISource() instead of FFVideoSource() & ShowFrameNumber() Instead of FFInfo()
Still the error is retains.
.avs file is
LoadPlugin("C:\Program Files\AviSynth 2.6\plugins\FFMS2\ffms2.dll") # here you need to adjust the path to the ffms2.dll
Import("C:\Program Files\AviSynth 2.6\plugins\FFMS2\FFMS2.avsi") # here you need to adjust the path to the FFMS2.avsi
AVISource ("C:\Documents and Settings\azhagiri\Desktop\123.AVI") # here you need to adjust the path to your input file
bob() # deinterleces the video by bobbing
selecteven() # throws out every odd field
ShowFrameNumber (frametype = false, cfrtime = false, vfrtime = false) # shows the frame number inside the upper left corner
v1 = SelectEvery(4,1).Subtitle("1 of 4", align=9) # shows that this is the first of every four frames inside the upper right corner
v2 = SelectEvery(4,2).Subtitle("2 of 4", align=9) # shows that this is the second of every four frames inside the upper right corner
v3 = SelectEvery(4,3).Subtitle("3 of 4", align=9) # shows that this is the third of every four frames inside the upper right corner
v4 = SelectEvery(4,4).Subtitle("4 of 4", align=9) # shows that this is the fourth of every four frames inside the upper right corner
return StackVertical(StackHorizontal(v1,v2), StackHorizontal(v3,v4)) # arranges the different views -
Take ffms2.dll out of the avisynth/plugins folder (e.g. move it into a subfolder)
Do not use other arguments for Showframenumber() . (Don't use CFR time etc.... those are for FFInfo)
This AVI sample has lots of errors, is that typical for this recording setup? -
Here is an example of ffmpeg 4way code that you can modify. It is based on your sample stream characteristics (interlaced DV, bottom field first, duplicate fields), you might have to modify it if the characteristics change. FFmpeg reports many errors on your sample stream (Scott mentioned that above earlier as wel)
You can drag and drop an AVI onto the .bat file and ffplay will spawn a viewer/player screen. This is done by piping the ffmpeg filter_complex chain to ffplay . ffmpeg and ffplay have to be in the search path (e.g in the same folder, or setup as an environment variable)
Code:ffmpeg -i %1 -filter_complex "[0:0]yadif=0:1,scale=640x480,framestep=4[a];[0:0]yadif=0:1,scale=640x480,trim=start_frame=1,framestep=4[b];[0:0]yadif=0:1,scale=640x480,trim=start_frame=2,framestep=4[c];[0:0]yadif=0:1,scale=640x480,trim=start_frame=3,framestep=4[d];[a]pad=iw*2:ih*2:0:0[int2];[int2][b]overlay=0:H/2[int3];[int3][c]overlay=W/2:0[int4];[int4][d]overlay=W/2:H/2[out]" -map [out] -f yuv4mpegpipe - | ffplay -i -
-
i thank u for your guidance.. quad screen video is working.
but the different video source is not displaying the same frame it is moving. example in a visual camera output display is moving like frame2,and some times frame4 etc.. the image i attached.. what could be the reason?
The images i attached..
if only 2 input we connect other 2 cameras are not connected means what will happen.. remaining 2 screen what could be the display status.. -
what could be the reason?
However, I note that your file is corrupted and doesn't even follow its own pattern.
Cornucopia already advised:
Better to see why it is being created that way: is it a problem with interlacing? with frame-dropping? with HDD corruption? with a bad source file(s)? bad DV compression?users currently on my ignore list: deadrats, Stears555 -
Hi
we are getting the video input to our system from multiplexing unit. after viewing this frame interchanging in the quad window, i read the detail of that unit. The unit will take 4 video inputs and multiplex it based on preset values, mentioned earlier. when it is multiplexing the video it will stamp some headers on active video lines for frame identification. it will be useful for playback.
To identify this frame headers, i opened this .avi file in RIFF Viewer and seen the header section it is not in the headers and vaux lines. for different sources same headers are there, it will be in the active video lines. how to identify this header and play back.
azhagiri.s