Recherche avancée

Médias (91)

Autres articles (49)

  • (Dés)Activation de fonctionnalités (plugins)

    18 février 2011, par

    Pour gérer l’ajout et la suppression de fonctionnalités supplémentaires (ou plugins), MediaSPIP utilise à partir de la version 0.2 SVP.
    SVP permet l’activation facile de plugins depuis l’espace de configuration de MediaSPIP.
    Pour y accéder, il suffit de se rendre dans l’espace de configuration puis de se rendre sur la page "Gestion des plugins".
    MediaSPIP est fourni par défaut avec l’ensemble des plugins dits "compatibles", ils ont été testés et intégrés afin de fonctionner parfaitement avec chaque (...)

  • Activation de l’inscription des visiteurs

    12 avril 2011, par

    Il est également possible d’activer l’inscription des visiteurs ce qui permettra à tout un chacun d’ouvrir soit même un compte sur le canal en question dans le cadre de projets ouverts par exemple.
    Pour ce faire, il suffit d’aller dans l’espace de configuration du site en choisissant le sous menus "Gestion des utilisateurs". Le premier formulaire visible correspond à cette fonctionnalité.
    Par défaut, MediaSPIP a créé lors de son initialisation un élément de menu dans le menu du haut de la page menant (...)

  • 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 (10119)

  • FFMPEG SCREEN RECORDING : How to get H265 (libx265) recording using ffmpeg with xorg ?

    19 novembre 2020, par Ryan

    I really would appreciate all the help I can get here.

    


    I'm trying to use the libx265 codec for recording an xorg dummy screen. The command that currently works for H264 (libx264 codec) is :

    


    


    ffmpeg -y -v info -f x11grab -draw_mouse 0 -r 30 -s 1280x720
-thread_queue_size 4096 -i :0.0+0,0 -f alsa -acodec aac -strict -2 -ar 44100 -b:a 128k -af aresample=async=1 -c:v libx264 -preset fast
-profile:v main -level 3.1 -pix_fmt yuv420p -r 30 -crf 21 -g 60 -tune zerolatency -f mp4 capture.mp4

    


    


    In trying to get H265 instead, I first changed the codec to libx265 like below :

    


    


    ffmpeg -y -v info -f x11grab -draw_mouse 0 -r 30 -s 1280x720
-thread_queue_size 4096 -i :0.0+0,0 -f alsa -acodec aac -strict -2 -ar 44100 -b:a 128k -af aresample=async=1 -c:v libx265 -preset fast
-profile:v main -level 3.1 -pix_fmt yuv420p -r 30 -crf 21 -g 60 -tune zerolatency -f mp4 capture.mp4

    


    


    But that didn't do it. Although it didn't error, it was producing a file that was playing at twice the recorded speed (i.e. twice the speed of the clip that was recorded).

    


    Then I tried using -x265-params to specify the parameters like this :

    


    


    ffmpeg -y -v info -f x11grab -draw_mouse 0 -r 30 -s 1280x720
-thread_queue_size 4096 -i :0.0+0,0 -f alsa -acodec aac -strict -2 -ar 44100 -b:a 128k -af aresample=async=1 -c:v libx264 -preset fast
-x265-params profile=main:level=3.1:crf=21 -pix_fmt yuv420p -r 30 -g 60 -tune zerolatency -f mp4 capture.mp4

    


    


    And this gave me an error with the following message :

    


    "output file #0 does not contain any stream ffmpeg"

    


    I've tried all sorts of combinations, searched extensively online (for both how to set 265 parameters and on the output file error), but I'm not making a headway. I'm really new to all this. Can anyone please help (with the most simple terms and directions) ?

    


  • Evolution #3091 (Nouveau) : Eviter le timout d’un article qui contient trop de ou

    13 novembre 2013, par - Equipement

    Bonjour,

    Un rédacteur a mis plusieurs centaines de DANS LE TEXTE d’un article, ce qui s’est traduit par un timeout lors de l’affichage de l’article.
    Si les documents ne sont pas dans le texte de l’article, cela ne pose pas de problème.

    Le rédacteur ne peut pas deviner que, lors du calcul de la page, SPIP va calculer autant de fois le squelette doc.html qu’il y a de dans le texte de l’article, ce qui augmente le temps de traitement.

    Aussi, une idée consisterait à ce que SPIP informe le rédacteur, au moment de l’enregistrement de son article, si ce dernier dépasse la limite du nombre maximal de ou p>

    if (defined(’_MAX_INCLURE_MODELES’) AND intval(_MAX_INCLURE_MODELES)>0) 
        $texte = _request(’texte’) ;
        if (strpos($texte,"<") !==false)
            if (preg_match_all(’/<[a-z_-]3,\s*[0-9|]+/iS’, $texte, $matches, PREG_SET_ORDER)>intval(_MAX_INCLURE_MODELES)) 
                $erreurs[’texte’] = _T(’info_trop_de_modeles’) ;
        
    

    Comme cette fonction formulaires_editer_article_verifier_dist restera sans effet pour les articles déjà existants et que l’on ne modifie pas, il est intéressant d’intervenir également sur la fonction inclure_modele. Il s’agit de faire en sorte que la page s’affiche avec tout le texte de l’article, mais celui-ci contiendrait uniquement les _MAX_INCLURE_MODELES premiers documents (ou images ou ...).

    Le début de la fonction de SPIP « inclure_modele » se verrait ainsi ajouter les 2 lignes ci-dessous qui portent sur $compteur_total (à noter que $compteur existe déjà actuellement pour les modèles inconnus, et est décrémenté plus loin dans la fonction si le modèle est connu) :

    function inclure_modele($type, $id, $params, $lien, $connect=’’) 
    

    static $compteur ;
    static $compteur_total ;
    if (++$compteur>10) return ’’ ; # ne pas boucler indefiniment
    if (defined(’_MAX_INCLURE_MODELES’) AND intval(_MAX_INCLURE_MODELES)>0 AND ++$compteur_total>intval(_MAX_INCLURE_MODELES)) return ’’ ;

    Cordialement
    Equipement

  • how to allow a worker to run a ffmpeg command on heroku for my python/django app ?

    10 mars 2013, par GetItDone

    I've been stuck trying to figure this out for weeks. I previously asked a similar question found here but I never got any replies. I really cannot find any good documentation anywhere. All I need to do is use a worker (don't care what worker have django-celery and rq installed) to convert a file to flv when it is uploaded from a form. I was able to get this done easily locally, but after over a week I haven't been able to get it to work no matter what I have tried. I tried adding a tasks.py file for celery, or a worker.py file for rq, and I have no idea what else (if anything) needs to be done, such as in my settings.py or Procfile. My procfile looks like :

    web: gunicorn lftv.wsgi -b 0.0.0.0:$PORT
    celeryd: celery -A tasks worker --loglevel=info
    worker: python worker.py

    My requirements.txt showing what I have installed looks like this :

    Django==1.4.3
    Logbook==0.4.1
    amqp==1.0.6
    anyjson==0.3.3
    billiard==2.7.3.19
    boto==2.6.0
    celery==3.0.13
    celery-with-redis==3.0
    distribute==0.6.31
    dj-database-url==0.2.1
    django-celery==3.0.11
    django-s3-folder-storage==0.1
    django-storages==1.1.6
    gunicorn==0.16.1
    kombu==2.5.4
    pil==1.1.7
    psycopg2==2.4.5
    python-dateutil==1.5
    pytz==2012j
    redis==2.7.2
    requests==1.1.0
    rq==0.3.2
    six==1.2.0
    times==0.6

    The only thing relevant in my settings.py are as follows :

    BROKER_BACKEND = &#39;django&#39;
    BROKER_URL = #For this I copy/pasted the code from my redistogo add-on from heroku. Not sure if correct
    BROKER_TRANSPORT_OPTIONS = {&#39;visibility_timeout&#39;: 1800}

    Without trying to take up too much more space, my tasks.py looks like this :

    import subprocess

    @task
    def ffmpeg_conversion(input_file):
       converted_file = subprocess.call(input_file)
       return converted_file

    I use S3 to store my static and media files, and the upload works (adding uploads to my bucket), however no matter what I try the conversion never will. Is there a good tutorial for absolute beginners ? I followed the heroku redis tutorial, celery docs, rq docs, and whatever else I can find, and got the examples to work, but the worker will not execute the command from my view. For example one of the many things I tried :

    ...
    ffmpeg = "ffmpeg -i %s -acodec mp3 -ar 22050 -f flv -s 320x240 %s" % (sourcefile, targetfile)
    ffmpegresult = ffmpeg_conversion.delay(ffmpeg)
    ...

    or using rq

    ...
    q = Queue(connection=conn)
    result = q.enqueue(ffmpeg_conversion, ffmpeg)
    ...

    I seems like it should be simple, however I am completely self-taught and have never deployed a project whatsoever, and there just doesn't seem to be any good documentation or tutorial available for what I am trying to do. I can't judge whether I am completely off and completely missing something significant or relatively close to getting this to work. I really do appreciate any input whatsoever, this is driving me nuts. Thanks in advance.