View Full Version : video truncated while playing
MathMath
4th October 2007, 00:05
Hi,
This is my first post, I don't really where I should put. It is so general.
I am using the ipp simple player and the ffplay. The video is a 1440*1040 encoded in h264 (using the JM soft).
Once the video is played with ffplay I have only a part of the movie. Let me explain what I mean by a part.
The down right part is well played, the upper one it can be seen that a color component is missing, and after I have nothing (black) and the left side all black.
This video has been test as well on another computer and it works fine. I have also try directly with the same video onto a raw format but it is doing exactly the same.
The video is played onto a linux machine.
I am thinking of kind of memory limitation due to fact that my graphic card has only 32 MB. But normally this should not matter as ffplay sets the SDL into a software surface.
So I have no clue how to make this working.
Math
nm
4th October 2007, 00:31
I am thinking of kind of memory limitation due to fact that my graphic card has only 32 MB. But normally this should not matter as ffplay sets the SDL into a software surface.
Yes, that's not likely to be the problem. Have you tried playing it with MPlayer or VLC? Can you upload a clip somewhere?
MathMath
4th October 2007, 00:45
Yep, I have tried with the ipp-sample and it is the same result, even worst segment fault.
But I have tried onto another machine with the same linux version and it works fine with ffplay and simple-player (ipp-player). I have also played this file under VLC but onto windows not linux and it run.
I have also the same sequence encoded in two different baselines. Both files have exactly the same comportment…. :s
I am thinking about something but I am not able to test this right now. the swap.
Do you think this could lead to that kind of wired stuff?
Dark Shikari
4th October 2007, 00:49
Could you upload the clip to someplace like Mediafire so we can check it out?
nm
4th October 2007, 01:03
Yep, I have tried with the ipp-sample and it is the same result, even worst segment fault.
But I have tried onto another machine with the same linux version and it works fine with ffplay and simple-player (ipp-player). I have also played this file under VLC but onto windows not linux and it run.
I have also the same sequence encoded in two different baselines. Both files have exactly the same comportment…. :s
Ok, in that case it could be a video rendering problem, although not strictly related to memory on the graphics card. To make sure, I would recommend trying something like mplayer -vo x11 (other vo's to try are xv, sdl and possibly gl).
MathMath
4th October 2007, 01:24
Oki, for the video I can post it, but I do not have the file here, I will try to do something tomorrow.
I have also forget to tell you something, I have another 264 video with a lower resolution (that has been encoded using the same parameters than the preious one) 848x352, and it works fine.
thanks for you help. I will try with other video output as well tomorrow and will let you know..
MathMath
4th October 2007, 12:09
Hi,
I have uploaded my file, so you can have a look here. (http://www.mediafire.com/?2yk9d9ri2uc)
If you want to play this movie under mplayer fps=30
I have test mplayer with vo X11 and it’s working fine, but if I set sdl it’s doing the truncate things.
What X11 uses hardware surface or software?
I suppose that is hardware…
What kind of limitation can do that :S
I need to run this video onto a software surface.
nm
4th October 2007, 13:52
I have test mplayer with vo X11 and it’s working fine, but if I set sdl it’s doing the truncate things.
What X11 uses hardware surface or software?
I suppose that is hardware…
x11 uses a software surface without any hardware acceleration. Xv (and probably -vo sdl, although it can be configured otherwise) do scaling and colorspace conversions on hardware.
Which graphics card do you have? Some older cards may have restrictions in the maximum overlay size (which can be something like 1024x1024) and that could be the problem here, or maybe the graphics driver you are using is just buggy. Did you try -vo xv with MPlayer? What does xvinfo tell?
Well, if you only need a software surface (why?), I guess there is no problem other than figuring out how to use one with the tools you want to use.
MathMath
4th October 2007, 15:47
Hi
I don’t have xv.
Available video output drivers:
x11 X11 ( XImage/Shm )
xover General X11 driver for overlay capable video output drivers
gl X11 (OpenGL)
gl2 X11 (OpenGL) - multiple textures version
sdl SDL YUV/RGB/BGR renderer (SDL v1.1.7+ only!)
xvidix X11 (VIDIX)
cvidix console VIDIX
null Null video output
mpegpes Mpeg-PES to DVB card
yuv4mpeg yuv4mpeg output for mjpegtools
tga Targa output
pnm PPM/PGM/PGMYUV file
md5sum md5sum of each frame
My graphic card is a pci-e matrox G550 of 32 MB.
I have check matrox website for the card driver. The required a X11 of 7.0 and I have 7.1. So not able to installed the provided one by them. Under RHEL5 the driver selected for this card is the good one and the G 550 is “supported”.
The fact that xv is no present can show that the graphic card is not well installed?
One question about SDL If I a set the software surface everything will be made onto software.
I would like to used only software to no depend of the graphic card used.
My xvinfo:
X-Video Extension version 2.2
screen #0
Adaptor #0: "Matrox G-Series Backend Scaler"
number of ports: 1
port base: 73
operations supported: PutImage
supported visuals:
depth 24, visualID 0x23
depth 24, visualID 0x24
depth 24, visualID 0x25
depth 24, visualID 0x26
depth 24, visualID 0x27
depth 24, visualID 0x28
depth 24, visualID 0x29
depth 24, visualID 0x2a
depth 24, visualID 0x2b
depth 24, visualID 0x2c
depth 24, visualID 0x2d
depth 24, visualID 0x2e
depth 24, visualID 0x2f
depth 24, visualID 0x30
depth 24, visualID 0x31
depth 24, visualID 0x32
number of attributes: 4
"XV_COLORKEY" (range 0 to 16777215)
client settable attribute
client gettable attribute (current value is 66046)
"XV_BRIGHTNESS" (range -128 to 127)
client settable attribute
client gettable attribute (current value is 0)
"XV_CONTRAST" (range 0 to 255)
client settable attribute
client gettable attribute (current value is 128)
"XV_DOUBLE_BUFFER" (range 0 to 1)
client settable attribute
client gettable attribute (current value is 1)
maximum XvImage size: 1024 x 1024
Number of image formats: 4
id: 0x32595559 (YUY2)
guid: 59555932-0000-0010-8000-00aa00389b71
bits per pixel: 16
number of planes: 1
type: YUV (packed)
id: 0x32315659 (YV12)
guid: 59563132-0000-0010-8000-00aa00389b71
bits per pixel: 12
number of planes: 3
type: YUV (planar)
id: 0x30323449 (I420)
guid: 49343230-0000-0010-8000-00aa00389b71
bits per pixel: 12
number of planes: 3
type: YUV (planar)
id: 0x59565955 (UYVY)
guid: 55595659-0000-0010-8000-00aa00389b71
bits per pixel: 16
number of planes: 1
type: YUV (packed)
I have seen that : maximum XvImage size: 1024 x 1024
Does this mean that this card won’t be able to handle more that 1024*1024, Cause I am able to set a 1600*1200 resolution onto my screen.
And if so why is it working with X11.
To be honest, I am a little bit lost. I had never dig so deeper…
Edit: http://www.matrox.com/graphics/en/finent/products/gseries/g550pcie.php
He are the features of my graphic card. I am using it in analog mode. So as you can see it should be oki. So maybe Xv is linked to the Digital spec?
nm
4th October 2007, 16:17
My graphic card is a pci-e matrox G550 of 32 MB.
I have check matrox website for the card driver. The required a X11 of 7.0 and I have 7.1. So not able to installed the provided one by them. Under RHEL5 the driver selected for this card is the good one and the G 550 is “supported”.
Yes, the default X.org Matrox driver is about as good as it can be.
The fact that xv is no present can show that the graphic card is not well installed?
No, since xvinfo showed that the backend scaler is available, the problem is in your MPlayer binary. It was probably built without XVideo headers for some reason.
One question about SDL If I a set the software surface everything will be made onto software.
I would think so. At least the video overlay wouldn't be used.
I would like to used only software to no depend of the graphic card used.
Pure software rendering can be very slow compared to using a hardware overlay or video blitter, especially if you are dealing with HD video. Nowadays Xv or OpenGL is almost always available, at least in properly configured systems, so software rendering is rarely necessary. Of course, it depends on the application: if you don't need to play the video in realtime or scaling is not required, it doesn't matter that much.
I have seen that : maximum XvImage size: 1024 x 1024
Does this mean that this card won’t be able to handle more that 1024*1024, Cause I am able to set a 1600*1200 resolution onto my screen.
The maximum XvImage size means that you can only (properly) play video that has a resolution of 1024x1024 or less using the overlay. Screen resolution is not related to this restriction.
MathMath
4th October 2007, 16:43
Thanks for all of this.
So I am limited by the overlay and SDL used that.
Thanks for all this info, one last question how X11 is handling that?
I mean why does it is working with it? I guess because it is not using the overlay, but what is is using?
nm
4th October 2007, 17:20
Thanks for all of this.
So I am limited by the overlay and SDL used that.
Thanks for all this info, one last question how X11 is handling that?
I mean why does it is working with it? I guess because it is not using the overlay, but what is is using?
With x11 output, MPlayer scales the video itself (or by default, doesn't scale at all) and converts the video colorspace (usually YV12) to RGB. It blits the resulting images with XPutImage or XShmPutImage and Xlib and the X server handle the rest. This is the same mechanism that is used by ordinary X programs to draw images, so as long as the machine has enough RAM to hold the frames, it will always work.
MathMath
4th October 2007, 17:45
But using that way it is not more CPU consuming than directly use overlay?
nm
4th October 2007, 18:33
As I said, software rendering is usually much more CPU-consuming than using overlay or opengl video blitter and the difference gets even larger when the video is scaled.
For example, I tested the outputs with a PAL clip using mplayer -nosound -benchmark.
-vo x11:
BENCHMARKs: VC: 31.335s VO: 80.623s A: 0.000s Sys: 1.922s = 113.879s
-vo opengl (which is a bit faster than xv on my hardware and drivers):
BENCHMARKs: VC: 37.480s VO: 34.644s A: 0.000s Sys: 5.120s = 77.245s
Overall, x11 is about 30 % slower. And this was without scaling. If I try to resize to full screen (1600 x1200), I get this:
-vo x11 -zoom -sws 0 (fast bilinear filtering):
BENCHMARKs: VC: 31.588s VO: 231.298s A: 0.000s Sys: 3.536s = 266.422s
-vo opengl:
BENCHMARKs: VC: 32.789s VO: 51.947s A: 0.000s Sys: 4.651s = 89.387s
vBulletin® v3.8.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.