Problem with mp4 (x264) when using effects (agingtv) plugin

classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

Problem with mp4 (x264) when using effects (agingtv) plugin

bojan74
This works ok - I see agingtv effect in window that opened because of autovideosink:
videotestsrc -> capsfilter -> queue1 -> videoconvert1 -> agingtv -> videoconvert2 -> queue2 -> autovideosink

This works ok - I get mp4 file but here I don't have agingtv effect:
videotestsrc -> capsfilter -> queue1 -> videoconvert1 -> videoconvert2 -> queue2 -> x264enc -> h264parse -> mp4mux -> filesink

I know it is nonsense to have two times videoconvert above but I put it just to have minimal diff with next pipeline.

This pipeline (added agingtv) gives me black video that does not play (nothing happens when click play) but length of video is correct and I can click on any time slider position:
videotestsrc -> capsfilter -> queue1 -> videoconvert1 -> agingtv -> videoconvert2 -> queue2 -> x264enc -> h264parse -> mp4mux -> filesink

Any idea why agingtv (similar is with gaussianblur) cause that video is black and can't be played?
Do I have to set any additional setting?

Reply | Threaded
Open this post in threaded view
|

Re: Problem with mp4 (x264) when using effects (agingtv) plugin

Jan Schmidt-6


On 13/02/17 07:16, bojan74 wrote:

> This works ok - I see agingtv effect in window that opened because of
> autovideosink:
> videotestsrc -> capsfilter -> queue1 -> videoconvert1 -> agingtv ->
> videoconvert2 -> queue2 -> autovideosink
>
> This works ok - I get mp4 file but here I don't have agingtv effect:
> videotestsrc -> capsfilter -> queue1 -> videoconvert1 -> videoconvert2 ->
> queue2 -> x264enc -> h264parse -> mp4mux -> filesink
>
> I know it is nonsense to have two times videoconvert above but I put it just
> to have minimal diff with next pipeline.
>
> This pipeline (added agingtv) gives me black video that does not play
> (nothing happens when click play) but length of video is correct and I can
> click on any time slider position:
> videotestsrc -> capsfilter -> queue1 -> videoconvert1 -> *agingtv* ->
> videoconvert2 -> queue2 -> x264enc -> h264parse -> mp4mux -> filesink

gst-launch-1.0 videotestsrc num-buffers=100  ! queue ! videoconvert !
agingtv ! videoconvert ! x264enc ! h264parse ! mp4mux ! filesink
location=test.mp4

This creates a working file for me with gstreamer git master. What are
you using for your capsfilter?

> Any idea why agingtv (similar is with gaussianblur) cause that video is
> black and can't be played?

No obvious reason. You can try running with GST_DEBUG=3 and see if any
errors / warnings are emitted.

If you're still having trouble, put a sample video online somewhere for
us to look at.

Regards,
Jan.

> Do I have to set any additional setting?
>
>
>
>
>
> --
> View this message in context: http://gstreamer-devel.966125.n4.nabble.com/Problem-with-mp4-x264-when-using-effects-agingtv-plugin-tp4681851.html
> Sent from the GStreamer-devel mailing list archive at Nabble.com.
> _______________________________________________
> gstreamer-devel mailing list
> [hidden email]
> https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
>
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Problem with mp4 (x264) when using effects (agingtv) plugin

bojan74
First, thank you very much for help.

I tried "your" pipeline but I got exactly the same problem as I was describing before. This mp4 file doesn't play, length is above 3s and anywhere on slider I click I get "black" video.
I upload test_NOK.mp4 file here: https://1fichier.com/?lql9ml6yaf
Hope you will get any idea, what is wrong in my environment if this is normally played in yours.

gst-launch-1.0 videotestsrc num-buffers=100  ! queue ! videoconvert ! agingtv ! videoconvert ! x264enc ! h264parse ! mp4mux ! filesink location=test_NOK.mp4


Then I try same pipeline just without agintv and this is played without problem as I my case in C code.
I upload test_OK.mp4 file here: https://1fichier.com/?rjwpvgkw5l

gst-launch-1.0 videotestsrc num-buffers=100  ! queue ! videoconvert ! videoconvert ! x264enc ! h264parse ! mp4mux ! filesink location=test_OK.mp4


GST_DEBUG=*:3 gives me same result (also both FIXME messages) in both cases except in test_OK.mp4 I don't get this line:
WARN               videopool gstvideopool.c:216:video_buffer_pool_set_config:<videobufferpool0> no caps in config


Setting pipeline to PAUSED ...
Pipeli0:00:02.030224827 ne is PREROLLING ...
15196 00000000032A2740 FIXME                default gstutils.c:3826:gst_pad_create_stream_id_internal:<videotestsrc0:src> Creating random stream-id, consider implementing a deterministic way of creating a stream-id
Redistrib0:00ute l:a0te2ncy.0639755...
64 15196 00000000032A2700 WARN               videopool gstvideopool.c:216:video_buffer_pool_set_config:<videobufferpool0> no caps in config
0:00:02.170803348 15196 00000000032A2700 FIXME               basesink gstbasesink.c:3077:gst_base_sink_default_event:<filesink0> stream-start event without group-id. Consider implementing group-id handling in the upstream elements
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
Got EOS from element "pipeline0".
Execution ended after 0:00:00.610572697
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...


If gstreamer version is maybe important, I was testing with x86_64-1.10.2
And I am testing this in Windows 10.

Reply | Threaded
Open this post in threaded view
|

Re: Problem with mp4 (x264) when using effects (agingtv) plugin

bojan74
Any idea why I got that "black not playable" mp4 file?

Can anyone please test this pipeline and check if got ok or "black" mp4 file?

gst-launch-1.0 videotestsrc num-buffers=100  ! queue ! videoconvert ! agingtv ! videoconvert ! x264enc ! h264parse ! mp4mux ! filesink location=test.mp4

And if there is any idea what can be wrong to get "black" mp4 file.

Thank you!
Reply | Threaded
Open this post in threaded view
|

Re: Problem with mp4 (x264) when using effects (agingtv) plugin

Myzhar
Try to add "-e" at the end of the pipeline. It will force an "End of Stream" message at the "Ctrl+C" pression and the file will be closed in the right way.

2017-02-16 9:13 GMT+01:00 bojan74 <[hidden email]>:
Any idea why I got that "black not playable" mp4 file?

Can anyone please test this pipeline and check if got ok or "black" mp4
file?

gst-launch-1.0 videotestsrc num-buffers=100  ! queue ! videoconvert !
agingtv ! videoconvert ! x264enc ! h264parse ! mp4mux ! filesink
location=test.mp4

And if there is any idea what can be wrong to get "black" mp4 file.

Thank you!



--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/Problem-with-mp4-x264-when-using-effects-agingtv-plugin-tp4681851p4681905.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel



--

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Walter Lucetti
www.myzhar.com
Reply | Threaded
Open this post in threaded view
|

Re: Problem with mp4 (x264) when using effects (agingtv) plugin

bojan74
I tried with "-e" but this not help. Also if you look at my log messages from previous posts there is detected EOS cause videotestsrc is limited with num-buffers=100. So I guess mp4 file is correct.

Did you maybe try this pipeline in your environment? If so, did you get correct mp4 file?

I am asking cause Jan said above that he got working file. So I guess there is some problem in my environment (os, gstreamer, version, setting, etc.?). So I would like to know what environment have users that got working file.
Reply | Threaded
Open this post in threaded view
|

Re: Problem with mp4 (x264) when using effects (agingtv) plugin

Myzhar
Under Windows, GStreamer 1.9, it works correctly and I get a playable video

2017-02-16 10:16 GMT+01:00 bojan74 <[hidden email]>:
I tried with "-e" but this not help. Also if you look at my log messages from
previous posts there is detected EOS cause videotestsrc is limited with
num-buffers=100. So I guess mp4 file is correct.

Did you maybe try this pipeline in your environment? If so, did you get
correct mp4 file?

I am asking cause Jan said above that he got working file. So I guess there
is some problem in my environment (os, gstreamer, version, setting, etc.?).
So I would like to know what environment have users that got working file.




--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/Problem-with-mp4-x264-when-using-effects-agingtv-plugin-tp4681851p4681907.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel



--

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Walter Lucetti
www.myzhar.com
Reply | Threaded
Open this post in threaded view
|

Re: Problem with mp4 (x264) when using effects (agingtv) plugin

Mailing List SVR
It works on linux too using both git master and 1.10.3,

Nicola

Il 16/02/2017 10:25, Walter Lucetti ha scritto:
Under Windows, GStreamer 1.9, it works correctly and I get a playable video

2017-02-16 10:16 GMT+01:00 bojan74 <[hidden email]>:
I tried with "-e" but this not help. Also if you look at my log messages from
previous posts there is detected EOS cause videotestsrc is limited with
num-buffers=100. So I guess mp4 file is correct.

Did you maybe try this pipeline in your environment? If so, did you get
correct mp4 file?

I am asking cause Jan said above that he got working file. So I guess there
is some problem in my environment (os, gstreamer, version, setting, etc.?).
So I would like to know what environment have users that got working file.




--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/Problem-with-mp4-x264-when-using-effects-agingtv-plugin-tp4681851p4681907.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel



--
Walter Lucetti

email: [hidden email]
web: www.robot-home.it



_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Problem with mp4 (x264) when using effects (agingtv) plugin

Tim Müller
In reply to this post by bojan74
On Thu, 2017-02-16 at 01:16 -0800, bojan74 wrote:

Maybe you get black because the video decoder can't handle the profile
it negotiates to.

Try:

 ... ! video/x-raw,format=I420 ! x264enc ! video/x-h264,profile=main !
...

Cheers
 -Tim
--
Tim Müller, Centricular Ltd - http://www.centricular.com
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Problem with mp4 (x264) when using effects (agingtv) plugin

bojan74
Thanks a lot to everyone!

Tim, your suggestion solved the problem, now I got playable file. :)

gst-launch-1.0 videotestsrc num-buffers=100  ! queue ! videoconvert ! agingtv ! videoconvert ! video/x-raw,format=I420 ! x264enc ! video/x-h264,profile=main ! h264parse ! mp4mux ! filesink location=test.mp4 -e


Is there any explanation why it works with others without that extra code?
Reply | Threaded
Open this post in threaded view
|

Re: Problem with mp4 (x264) when using effects (agingtv) plugin

Nicolas Dufresne-5
Le jeudi 16 février 2017 à 01:57 -0800, bojan74 a écrit :
> Is there any explanation why it works with others without that extra
> code?

This depends ont the H264 decoder being used. x264enc by default will
choose the "high" profile. Most users on Linux will use the FFMPEG
decoder, which supports this profile (hence report a working MP4). But
you may be using something or have an older version of FFMPEG, which
may not support it. If the player was your phone, then your phone
hardware may not support that. You would need to share further
information about how your are playing back the file, and which version
of everything you are using for more specific explanations.

Encoding is an art, which requires great knowledge ;-P

regards,
Nicolas
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

signature.asc (188 bytes) Download Attachment