Recherche avancée

Médias (3)

Mot : - Tags -/plugin

Autres articles (29)

  • Des sites réalisés avec MediaSPIP

    2 mai 2011, par

    Cette 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.

  • Les statuts des instances de mutualisation

    13 mars 2010, par

    Pour des raisons de compatibilité générale du plugin de gestion de mutualisations avec les fonctions originales de SPIP, les statuts des instances sont les mêmes que pour tout autre objets (articles...), seuls leurs noms dans l’interface change quelque peu.
    Les différents statuts possibles sont : prepa (demandé) qui correspond à une instance demandée par un utilisateur. Si le site a déjà été créé par le passé, il est passé en mode désactivé. publie (validé) qui correspond à une instance validée par un (...)

  • Les autorisations surchargées par les plugins

    27 avril 2010, par

    Mediaspip core
    autoriser_auteur_modifier() afin que les visiteurs soient capables de modifier leurs informations sur la page d’auteurs

Sur d’autres sites (5442)

  • avcodec/mpeg2dec : Fix motion vector rounding for chroma components

    11 février 2018, par Nekopanda
    avcodec/mpeg2dec : Fix motion vector rounding for chroma components
    

    In 16x8 motion compensation, for lower 16x8 region, the input to mpeg_motion() for motion_y was "motion_y + 16", which causes wrong rounding. For 4:2:0, chroma scaling for y is dividing by two and rounding toward zero. When motion_y < 0 and motion_y + 16 > 0, the rounding direction of "motion_y" and "motion_y + 16" is different and rounding "motion_y + 16" would be incorrect.

    We should input "motion_y" as is to round correctly. I add "is_16x8" flag to do that.

    Signed-off-by : Michael Niedermayer <michael@niedermayer.cc>

    • [DH] libavcodec/mpegvideo_motion.c
    • [DH] tests/ref/fate/filter-mcdeint-fast
    • [DH] tests/ref/fate/filter-mcdeint-medium
    • [DH] tests/ref/fate/filter-w3fdif-complex
    • [DH] tests/ref/fate/filter-w3fdif-simple
    • [DH] tests/ref/fate/filter-yadif-mode0
    • [DH] tests/ref/fate/filter-yadif-mode1
    • [DH] tests/ref/fate/filter-yadif10
    • [DH] tests/ref/fate/filter-yadif16
    • [DH] tests/ref/fate/mpeg2-field-enc
    • [DH] tests/ref/fate/mpeg2-ticket6677
  • Thinking about switching to GeoIP2 for better location detection ? Here’s what you should know

    5 juin 2018, par Matomo Core Team

    In Matomo 3.5.0 we added a new feature to improve the location detection (country, region, city) of your visitors. Especially when it comes to IPv6 addresses, you will see less “Unknown” locations and more accurate results in general. This feature is now enabled for all new installations but needs to be manually enabled for existing Matomo self-hosted users.

    Why is the Matomo plugin not enabled for existing users ?

    When you enable the GeoIP2 plugin, a database update will need to be executed on two datatable tables (“log_visit” and “log_conversion”) which stores some of the raw data. Please be aware that this update could take several hours depending on the size of your database.

    If you store many visits in your database, it is recommended to execute the update through the command line by executing the command ./console core:update to avoid the update from timing out. You may also have to put your Matomo into maintenance mode during this time and replay the missed traffic from logs afterwards as explained in the FAQ article.

    GeoIP2 may slow down your tracking

    In the past we have seen that a few Matomo databases with high traffic volumes struggle to handle all the tracking requests after enabling GeoIP2. The reason for this is the location database now contains many more entries because it has to store all the IPv6 addresses and the database itself has a different format. Hence, the location lookup takes longer.

    It is hard to say how much slower the location lookup gets, but we found GeoIP2-PHP is about 20 times slower than GeoIP1-PHP. On a fast CPU the lookup time for an IP with GeoIP2 takes about 1ms, but can also take much longer depending on the server.

    Making location lookups fast again

    There is a PHP extension available that makes lookups very fast, even faster than the old GeoIP1-PHP provider. If you can install additional PHP extensions on your server and have a high traffic website, you may want to install the GeoIP2 extension.

    There is also an Nginx module and an Apache module. Unfortunately, we don’t have any performance metrics for these providers.

    How do I activate the GeoIP2 location provider ?

    As a Super User, log in to your Matomo and go to “Administration => Plugins”. There you can activate the “GeoIP2” plugin. As mentioned, this will trigger a database update which can take a while and you may want to perform this update through the command line.

    Now you can go to “Administration => Geolocation”. Here you will first need to install the GeoIP2 databases at the bottom of the page before you can activate the GeoIP2-PHP provider. To activate any of the other GeoIP2 providers, you will need to install the required modules.

    You will be able to check if the detection works on the right next to location provider. Once you selected one of the available providers, you’re all good to go.

    The post Thinking about switching to GeoIP2 for better location detection ? Here’s what you should know appeared first on Analytics Platform - Matomo.

  • How to crop and scale multiple landscape regions into a new portrait video ? FFmpeg

    27 août 2023, par 3V1LXD

    I have an electron program that selects multiple regions of a landscape video and lets you rearrange them in a portrait canvas. I'm having trouble building the proper ffmpeg command to create the video. I have this somewhat working. I can export 2 layers, but i can't export if i only have 1 layer or if i have 3 or more layers selected.

    &#xA;

    2 regions of video selected

    &#xA;

    layers [&#xA;  { top: 0, left: 658, width: 576, height: 1080 },&#xA;  { top: 262, left: 0, width: 576, height: 324 }&#xA;]&#xA;newPositions [&#xA;  { top: 0, left: 0, width: 576, height: 1080 },&#xA;  { top: 0, left: 0, width: 576, height: 324 }&#xA;]&#xA;filtergraph [0]crop=576:1080:658:0,scale=576:1080[v0];[0]crop=576:324:0:262,scale=576:324[v1];[v0][v1]overlay=0:0:0:0[out]&#xA;&#xA;No Error export successful&#xA;

    &#xA;

    1 region selected

    &#xA;

    layers [ { top: 0, left: 650, width: 576, height: 1080 } ]&#xA;newPositions [ { top: 0, left: 0, width: 576, height: 1080 } ]&#xA;filtergraph [0]crop=576:1080:650:0,scale=576:1080[v0];[v0]overlay=0:0[out]&#xA;&#xA;FFmpeg error: [fc#0 @ 000001dd3b6db0c0] Cannot find a matching stream for unlabeled input pad overlay&#xA;Error initializing complex filters: Invalid argument&#xA;

    &#xA;

    3 regions of video selected

    &#xA;

    layers [&#xA;  { top: 0, left: 641, width: 576, height: 1080 },&#xA;  { top: 250, left: 0, width: 576, height: 324 },&#xA;  { top: 756, left: 0, width: 576, height: 324 }&#xA;]&#xA;newPositions [&#xA;  { top: 0, left: 0, width: 576, height: 1080 },&#xA;  { top: 0, left: 0, width: 576, height: 324 },&#xA;  { top: 756, left: 0, width: 576, height: 324 }&#xA;]&#xA;filtergraph [0]crop=576:1080:641:0,scale=576:1080[v0];[0]crop=576:324:0:250,scale=576:324[v1];[0]crop=576:324:0:756,scale=576:324[v2];[v0][v1][v2]overlay=0:0:0:0:0:756[out]&#xA;&#xA;FFmpeg error: [AVFilterGraph @ 0000018faf2189c0] More input link labels specified for filter &#x27;overlay&#x27; than it has inputs: 3 > 2&#xA;[AVFilterGraph @ 0000018faf2189c0] Error linking filters&#xA;&#xA;FFmpeg error: Failed to set value &#x27;[0]crop=576:1080:698:0,scale=576:1080[v0];[0]crop=576:324:0:264,scale=576:324[v1];[0]crop=576:324:0:756,scale=576:324[v2];[v0][v1][v2]overlay=0:0:0:0:0:0[out]&#x27; for option &#x27;filter_complex&#x27;: Invalid argument&#xA;Error parsing global options: Invalid argument&#xA;

    &#xA;

    I can't figure out how to construct the proper overlay command. Here is the js code i'm using from my electron app.

    &#xA;

    ipcMain.handle(&#x27;export-video&#x27;, async (_event, args) => {&#xA;  const { videoFile, outputName, layers, newPositions } = args;&#xA;  const ffmpegPath = path.join(__dirname, &#x27;bin&#x27;, &#x27;ffmpeg&#x27;);&#xA;  const outputDir = checkOutputDir();&#xA;  &#xA;  // use same video for each layer as input&#xA;  // crop, scale, and position each layer&#xA;  // overlay each layer on top of each other&#xA;&#xA;  // export video&#xA;  console.log(&#x27;layers&#x27;, layers);&#xA;  console.log(&#x27;newPositions&#x27;, newPositions);&#xA;&#xA;  let filtergraph = &#x27;&#x27;;&#xA;&#xA;  for (let i = 0; i &lt; layers.length; i&#x2B;&#x2B;) {&#xA;    const { top, left, width, height } = layers[i];&#xA;    const { width: newWidth, height: newHeight } = newPositions[i];&#xA;    const filter = `[0]crop=${width}:${height}:${left}:${top},scale=${newWidth}:${newHeight}[v${i}];`;&#xA;    filtergraph &#x2B;= filter;&#xA;  }&#xA;&#xA;  for (let i = 0; i &lt; layers.length; i&#x2B;&#x2B;) {&#xA;    const filter = `[v${i}]`;&#xA;    filtergraph &#x2B;= filter;&#xA;  }&#xA;&#xA;  filtergraph &#x2B;= `overlay=`;&#xA;  for (let i = 0; i &lt; layers.length; i&#x2B;&#x2B;) {&#xA;    const { top: newTop, left: newLeft } = newPositions[i];&#xA;    const overlay = `${newLeft}:${newTop}:`;&#xA;    filtergraph &#x2B;= overlay;&#xA;  }&#xA;&#xA;  filtergraph = filtergraph.slice(0, -1); // remove last comma&#xA;  filtergraph &#x2B;= `[out]`;&#xA;  &#xA;  console.log(&#x27;filtergraph&#x27;, filtergraph);&#xA;&#xA;  const ffmpeg = spawn(ffmpegPath, [&#xA;    &#x27;-i&#x27;, videoFile,&#xA;    &#x27;-filter_complex&#x27;, filtergraph,&#xA;    &#x27;-map&#x27;, &#x27;[out]&#x27;,&#xA;    &#x27;-c:v&#x27;, &#x27;libx264&#x27;,&#xA;    &#x27;-preset&#x27;, &#x27;ultrafast&#x27;,&#xA;    &#x27;-crf&#x27;, &#x27;18&#x27;,&#xA;    &#x27;-y&#x27;,&#xA;    path.join(outputDir, `${outputName}`)&#xA;  ]);  &#xA;&#xA;  ffmpeg.stdout.on(&#x27;data&#x27;, (data) => {&#xA;    console.log(`FFmpeg output: ${data}`);&#xA;  });&#xA;&#xA;  ffmpeg.stderr.on(&#x27;data&#x27;, (data) => {&#xA;    console.error(`FFmpeg error: ${data}`);&#xA;  });&#xA;&#xA;  ffmpeg.on(&#x27;close&#x27;, (code) => {&#xA;    console.log(`FFmpeg process exited with code ${code}`);&#xA;    // event.reply(&#x27;ffmpeg-export-done&#x27;); // Notify the renderer process&#xA;  });&#xA;});&#xA;

    &#xA;

    Any advice might be helpful, The docs are confusing, Thanks.

    &#xA;