
Recherche avancée
Autres articles (60)
-
Des sites réalisés avec MediaSPIP
2 mai 2011, parCette page présente quelques-uns des sites fonctionnant sous MediaSPIP.
Vous pouvez bien entendu ajouter le votre grâce au formulaire en bas de page. -
HTML5 audio and video support
13 avril 2011, parMediaSPIP uses HTML5 video and audio tags to play multimedia files, taking advantage of the latest W3C innovations supported by modern browsers.
The MediaSPIP player used has been created specifically for MediaSPIP and can be easily adapted to fit in with a specific theme.
For older browsers the Flowplayer flash fallback is used.
MediaSPIP allows for media playback on major mobile platforms with the above (...) -
Librairies et binaires spécifiques au traitement vidéo et sonore
31 janvier 2010, parLes logiciels et librairies suivantes sont utilisées par SPIPmotion d’une manière ou d’une autre.
Binaires obligatoires FFMpeg : encodeur principal, permet de transcoder presque tous les types de fichiers vidéo et sonores dans les formats lisibles sur Internet. CF ce tutoriel pour son installation ; Oggz-tools : outils d’inspection de fichiers ogg ; Mediainfo : récupération d’informations depuis la plupart des formats vidéos et sonores ;
Binaires complémentaires et facultatifs flvtool2 : (...)
Sur d’autres sites (6033)
-
ffmpeg : How can I send a H.265 encoded stream to wowza ?
24 avril 2015, par FuzzI managed to encode H.265 to an output file like this :
ffmpeg -i test.m2ts -c:v libx265 -c:a copy output.mp4
and I managed to stream a H.264 file to wowza like this :
ffmpeg -re -i sample.mp4 -vcodec libx264 -vprofile default -vprofile baseline -r 24 -g 48 -vb 150000 -strict experimental -acodec aac -ab 96000 -ar 48000 -ac 2 -f rtsp -muxdelay 0.1 rtsp://username:password@127.0.0.1:1935/ApplicationName/myStream
But I just cant seem to stream a H.265 to a rtsp stream.
If I use the libx265 in the command above I get the error :
Error while opening encoder for output stream #0:0 - maybe incorrect parameters such as bit_rate, rate, width or height
Any hints would be greatly appreciated.
Here is the console message with -loglevel verbose
>ffmpeg -re -i sample.mp4 -vcodec libx265 -vprofile default -vprofile baseline -r 24 -g 48 -vb 150000 -strict experimental -acodec aac -ab 96000 -ar 48000 -ac 2 -f rtsp -muxdelay 0.1 rtsp://username:password@127.0.0.1:1935/ApplicationName/myStream -l
oglevel verbose
ffmpeg version N-69156-gff5b9a1c Copyright (c) 2000-2015 the FFmpeg developers
built on Jan 20 2015 00:38:00 with gcc 4.9.2 (GCC)
configuration: --enable-gpl --enable-version3 --disable-w32threads --enable-avisynth --enable-bzlib --enable-fontconfig --enable-frei0r --enable-gnutls --enable-iconv --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libfreetype --enable-libgme --enable-libgsm --enable-
libilbc --enable-libmodplug --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-librtmp --enable-libschroedinger --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvo-aacenc --
enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs --enable-libxvid --enable-lzma --enable-decklink --enable-zlib
libavutil 54. 17.100 / 54. 17.100
libavcodec 56. 20.100 / 56. 20.100
libavformat 56. 19.100 / 56. 19.100
libavdevice 56. 4.100 / 56. 4.100
libavfilter 5. 8.100 / 5. 8.100
libswscale 3. 1.101 / 3. 1.101
libswresample 1. 1.100 / 1. 1.100
libpostproc 53. 3.100 / 53. 3.100
Routing option strict to both codec and muxer layer
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'sample.mp4':
Metadata:
major_brand : qt
minor_version : 512
compatible_brands: qt
creation_time : 1970-01-01 00:00:00
encoder : Lavf52.73.0
Duration: 00:09:56.46, start: 0.000000, bitrate: 524 kb/s
Stream #0:0(eng): Video: h264 (Constrained Baseline) (avc1 / 0x31637661), yuv420p, 424x240 (432x240), 420 kb/s, 24 fps, 24 tbr, 24 tbn, 48 tbc (default)
Metadata:
creation_time : 1970-01-01 00:00:00
handler_name : DataHandler
encoder : libx264
Stream #0:1(eng): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 99 kb/s (default)
Metadata:
creation_time : 1970-01-01 00:00:00
handler_name : DataHandler
[graph 0 input from stream 0:0 @ 00000000050f6e60] w:424 h:240 pixfmt:yuv420p tb:1/24 fr:24/1 sar:0/1 sws_param:flags=2
[graph 1 input from stream 0:1 @ 0000000002c38700] tb:1/48000 samplefmt:fltp samplerate:48000 chlayout:0x3
[libx265 @ 0000000002c172a0] [Eval @ 000000000022aca0] Undefined constant or missing '(' in 'baseline'
[libx265 @ 0000000002c172a0] Unable to parse option value "baseline"
[libx265 @ 0000000002c172a0] Error setting option profile to value baseline.
Output #0, rtsp, to 'rtsp://username:password@127.0.0.1:1935/ApplicationName/myStream':
Metadata:
major_brand : qt
minor_version : 512
compatible_brands: qt
encoder : Lavf52.73.0
Stream #0:0(eng): Video: hevc, none, q=2-31, 128 kb/s, 24 fps (default)
Metadata:
creation_time : 1970-01-01 00:00:00
handler_name : DataHandler
encoder : Lavc56.20.100 libx265
Stream #0:1(eng): Audio: aac, 0 channels, 128 kb/s (default)
Metadata:
creation_time : 1970-01-01 00:00:00
handler_name : DataHandler
encoder : Lavc56.20.100 aac
Stream mapping:
Stream #0:0 -> #0:0 (h264 (native) -> hevc (libx265))
Stream #0:1 -> #0:1 (aac (native) -> aac (native))
Error while opening encoder for output stream #0:0 - maybe incorrect parameters such as bit_rate, rate, width or height -
Remove a set-but-unused variable (lastdelta) in the encode-side lsp
2 mars 2015, par MontyRemove a set-but-unused variable (lastdelta) in the encode-side lsp code. Note that the code in question is effectively dead as it's for floor0 encoding, and floor zero has been deprecated for over a decade.
git-svn-id : http://svn.xiph.org/trunk/vorbis@19453 0101bb08-14d6-0310-b084-bc0e0c8e3800
-
How to write unit tests for your plugin – Introducing the Piwik Platform
17 novembre 2014, par Thomas Steur — DevelopmentThis is the next post of our blog series where we introduce the capabilities of the Piwik platform (our previous post was How to verify user permissions). This time you’ll learn how to write unit tests in Piwik. For this tutorial you will need to have basic knowledge of PHP, PHPUnit and the Piwik platform.
When is a test a unit test ?
There are many different opinions on this and it can be sometimes hard to decide. At Piwik we consider a test as a unit test if only a single method or class is being tested and if a test does not have a dependency to the filesystem, web, config, database or to any other plugin.
If a test is slow it can be an indicator that it is not a unit test. “Slow” is of course a bit vague. We will cover how to write other type of tests, such as integration tests, in one of our next blog posts.
Getting started
In this post, we assume that you have already installed Piwik 2.9.0 or later via git, set up your development environment and created a plugin. If not, visit the Piwik Developer Zone where you’ll find the tutorial Setting up Piwik and other Guides that help you to develop a plugin.
Let’s create a unit test
We start by using the Piwik Console to create a new unit test :
./console generate:test --testtype unit
The command will ask you to enter the name of the plugin the created test should belong to. I will use the plugin name “Insights”. Next it will ask you for the name of the test. Here you usually enter the name of the class you want to test. I will use “Widgets” in this example. There should now be a file
plugins/Insights/tests/Unit/WidgetsTest.php
which contains already an example to get you started easily :- /**
- * @group Insights
- * @group WidgetsTest
- * @group Plugins
- */
- class WidgetsTest extends \PHPUnit_Framework_TestCase
- {
- public function testSimpleAddition()
- {
- $this->assertEquals(2, 1+1);
- }
- }
We don’t want to cover how you should write your unit test. This is totally up to you. If you have no experience in writing unit tests yet, we recommend to read articles on the topic, or a book, or to watch videos or anything else that will help you learn best.
Running a test
To run a test we will use the command
tests:run
which allows you to execute a test suite, a specific file or a group of tests.To verify whether the created test works we will run it as follows :
./console tests:run WidgetsTest
This will run all tests having the group
WidgetsTest
. As other tests can use the same group you might want to pass the path to your test file instead :./console tests:run plugins/Insights/tests/Unit/Widgets.php
If you want to run all tests within your plugin pass the name of your plugin as an argument :
./console tests:run insights
Of course you can also define multiple arguments :
./console tests:run insights WidgetsTest
This will execute all tests within the insights plugin having the group WidgetsTest. If you only want to run unit tests within your plugin you can do the following :
./console tests:run insights unit
Advanced features
Isn’t it easy to create a unit test ? We never even created a file ! You can accomplish even more if you want : You can generate other type of tests, you can run tests on Amazon’s AWS and more. Unfortunately, not everything is documented yet so we recommend to discover more features by executing the commands
./console list tests
and./console help tests:run
.If you have any feedback regarding our APIs or our guides in the Developer Zone feel free to send it to us.