Recherche avancée

Médias (1)

Mot : - Tags -/book

Autres articles (89)

  • Websites made ​​with MediaSPIP

    2 mai 2011, par

    This page lists some websites based on MediaSPIP.

  • Les tâches Cron régulières de la ferme

    1er décembre 2010, par

    La gestion de la ferme passe par l’exécution à intervalle régulier de plusieurs tâches répétitives dites Cron.
    Le super Cron (gestion_mutu_super_cron)
    Cette tâche, planifiée chaque minute, a pour simple effet d’appeler le Cron de l’ensemble des instances de la mutualisation régulièrement. Couplée avec un Cron système sur le site central de la mutualisation, cela permet de simplement générer des visites régulières sur les différents sites et éviter que les tâches des sites peu visités soient trop (...)

  • Publier sur MédiaSpip

    13 juin 2013

    Puis-je poster des contenus à partir d’une tablette Ipad ?
    Oui, si votre Médiaspip installé est à la version 0.2 ou supérieure. Contacter au besoin l’administrateur de votre MédiaSpip pour le savoir

Sur d’autres sites (14231)

  • Using Qt Media Player on Raspberry Pi 1

    18 mai 2015, par Mauker

    I have a project built using Qt5 which has to play a video. Just like in the videowidget sample code.

    I’ve followed these instructions to build qt5 on my Pi. And it went just fine. But when I try to run any qt program that uses QMediaPlayer, I get the error message :

    defaultServiceProvider::requestService(): no service found for - "org.qt-project.qt.mediaplayer"

    Which means I don’t have a backend to play the video, right ? Is there any one that I can use which will with Qt, like ffmpeg ? And how can I get it to work ? Specially for h264 videos.

    I’ve tried to install gstreamer as is told on this link, but it’s not working. Will I have to rebuild the entire qt5 again ?

    P.S. : I have the raspberry pi 1 model B with raspbian installed.

    Edit : As mentioned by Greenflow, I checked the ./configure log and saw that the GStreamer was compiled in, but the video apps are still not working...

    The message on the log was like this :

    GStreamer .............. yes (0.10)

    And the message on Greenflow’s log was like this :

    GStreamer .............. yes (1.0)

    Clearly it’s another version of GStreamer, but is it the problem ?

    I’ve also found this post which says QtMultimedia on the Pi is rather useless, but the post is from 2013, so I’m not sure if it’s really relevant. I’d like to have this app playing hardware accelerated videos on my Raspberry Pi, but I’m almost dropping the idea.

    Anyways, thanks Greenflow for the head start.

    Edit 2 : Found this thread on the Qtcentre. Damn, this thing is not going to be easy to solve, I guess...

  • avcodec/asvenc : Don't waste bits encoding non-visible part

    22 mai, par Andreas Rheinhardt
    avcodec/asvenc : Don't waste bits encoding non-visible part
    

    Up until now, the encoder replicated all the border pixels
    for incomplete 16x16 macroblocks. In case the available width
    or height is <= 8, some of the luma blocks of the MB
    do not correspond to actual input, so that we should encode
    them using the least amount of bits. Zeroing the block coefficients
    (as this commit does) achieves this, replicating the pixels
    and performing an FDCT does not.

    This commit also removes the frame copying code for insufficiently
    aligned dimensions.

    The vsynth3-asv[12] FATE tests use a 34x34 input file and are
    therefore affected by this. As the ref updates show, the size
    and checksum of the encoded changes, yet the decoded output
    stays the same.

    Signed-off-by : Andreas Rheinhardt <andreas.rheinhardt@outlook.com>

    • [DH] libavcodec/asvenc.c
    • [DH] tests/ref/vsynth/vsynth3-asv1
    • [DH] tests/ref/vsynth/vsynth3-asv2
  • Hit noise when playing part of wave file with ALSA PCM interface

    11 décembre 2024, par wangt13

    I am working a WAVE file playing with ALSA PCM interface in Linux, and I heard noise when I played the file quickly and partially.

    &#xA;

    Here is my playing function.

    &#xA;

    static int playback_function(uint8_t *pcm_buf, int pcm_frames)&#xA;{&#xA;    int  rc;&#xA;    uint8_t *buf;&#xA;    int frame_size, sent;&#xA;    int periodsize;&#xA;    int left;&#xA;&#xA;    frame_size = chan * av_get_bytes_per_sample(AV_SAMPLE_FMT_S16);&#xA;    periodsize = sys_periodsize; // 320 in my system&#xA;    buf = pcm_buf;&#xA;    left = pcm_frames;&#xA;    sent = 0;&#xA;&#xA;    while (left > 0) {&#xA;        sent = (left > periodsize) ? periodsize : left;&#xA;        rc = snd_pcm_writei(pcm_handle, buf, sent);&#xA;        printf("rc: %d, sent: %d\n", rc, sent);&#xA;        if (rc == -EAGAIN || (rc >= 0 &amp;&amp; (size_t)rc &lt; sent)) {&#xA;            snd_pcm_wait(pcm_handle, 10);&#xA;        } else if (rc == -EPIPE) {&#xA;            snd_pcm_recover(pcm_handle, rc, 0);&#xA;        } else if (rc &lt; 0) {&#xA;            break;&#xA;        }&#xA;        if (rc > 0) {&#xA;            left -= rc;&#xA;            buf &#x2B;= rc * frame_size;&#xA;        }&#xA;    }&#xA;    return rc;&#xA;}&#xA;

    &#xA;

    The pcm_buf and pcm_frames are got from swr_convert() in libswresample, in my case, the pcm_frames is 1187.

    &#xA;

    By adding printf("rc: %d, sent: %d\n", rc, sent);, I got following logs.

    &#xA;

    rc: 320, sent: 320&#xA;rc: 87, sent: 87&#xA;rc: 320, sent: 320&#xA;rc: 320, sent: 320&#xA;rc: 103, sent: 103&#xA;rc: 320, sent: 320&#xA;rc: 320, sent: 320&#xA;rc: 103, sent: 103&#xA;rc: 320, sent: 320&#xA;rc: 320, sent: 320&#xA;rc: 103, sent: 103&#xA;rc: 320, sent: 320&#xA;rc: 320, sent: 320&#xA;rc: 103, sent: 103&#xA;rc: 320, sent: 320&#xA;rc: 320, sent: 320&#xA;rc: 103, sent: 103&#xA;rc: 320, sent: 320&#xA;rc: 320, sent: 320&#xA;rc: 103, sent: 103&#xA;rc: 320, sent: 320&#xA;rc: 320, sent: 320&#xA;rc: 103, sent: 103&#xA;rc: 320, sent: 320&#xA;rc: 320, sent: 320&#xA;rc: 103, sent: 103&#xA;rc: 320, sent: 320&#xA;rc: 320, sent: 320&#xA;rc: 87, sent: 87&#xA;rc: 320, sent: 320&#xA;rc: 320, sent: 320&#xA;rc: 103, sent: 103&#xA;

    &#xA;

    With above function, sometimes I can hear noise when playing the WAVE file quickly and repeatly.
    &#xA;So, how can I improve the WAVE playing without the noise ??

    &#xA;

    I changed the above function by using filling 0 to the end of data buffer (to enforce silence).

    &#xA;

    static int playback_test(uint8_t *pcm_buf, int pcm_frames)&#xA;{&#xA;    uint8_t *buf;&#xA;    int trd;&#xA;    int rc;&#xA;    int left;&#xA;    int frame_size, sent;&#xA;    int periodsize;&#xA;    int aligned = 0;&#xA;&#xA;    frame_size = chan * av_get_bytes_per_sample(AV_SAMPLE_FMT_S16);&#xA;    periodsize = sys_periodsize; // 320 in my system&#xA;&#xA;    buf = pcm_buf;&#xA;    left = pcm_frames;&#xA;    aligned = (left/periodsize &#x2B; 1) * periodsize;&#xA;    memset(buf &#x2B; left * frame_size, 0, (aligned - left) * frame_size);&#xA;    sent = 0;&#xA;///left = periodsize; // &lt;== This causes more noise!!&#xA;&#xA;    while (left > 0) {&#xA;        sent = (left > periodsize) ? periodsize : left;&#xA;        rc = snd_pcm_writei(pcm_handle, buf, sent);&#xA;        printf("rc: %d, sent: %d\n", rc, sent);&#xA;        if (rc == -EAGAIN || (rc >= 0 &amp;&amp; (size_t)rc &lt; sent)) {&#xA;            snd_pcm_wait(pcm_handle, 10);&#xA;        } else if (rc == -EPIPE) {&#xA;            snd_pcm_recover(pcm_handle, rc, 0);&#xA;        } else if (rc &lt; 0) {&#xA;            break;&#xA;        }&#xA;        if (rc > 0) {&#xA;            left -= rc;&#xA;            buf &#x2B;= rc * frame_size;&#xA;        }&#xA;    }&#xA;    return rc;&#xA;}&#xA;

    &#xA;

    There is NO improvement as of the noise.

    &#xA;