Recherche avancée

Médias (0)

Mot : - Tags -/gis

Aucun média correspondant à vos critères n’est disponible sur le site.

Autres articles (96)

  • MediaSPIP 0.1 Beta version

    25 avril 2011, par

    MediaSPIP 0.1 beta is the first version of MediaSPIP proclaimed as "usable".
    The zip file provided here only contains the sources of MediaSPIP in its standalone version.
    To get a working installation, you must manually install all-software dependencies on the server.
    If you want to use this archive for an installation in "farm mode", you will also need to proceed to other manual (...)

  • Multilang : améliorer l’interface pour les blocs multilingues

    18 février 2011, par

    Multilang est un plugin supplémentaire qui n’est pas activé par défaut lors de l’initialisation de MediaSPIP.
    Après son activation, une préconfiguration est mise en place automatiquement par MediaSPIP init permettant à la nouvelle fonctionnalité d’être automatiquement opérationnelle. Il n’est donc pas obligatoire de passer par une étape de configuration pour cela.

  • HTML5 audio and video support

    13 avril 2011, par

    MediaSPIP 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 (...)

Sur d’autres sites (7523)

  • ffprobe File not fournd error due long path BUT windows long path enabled

    10 novembre 2020, par nonayme

    I have a python program which run ffprobe on some videos on my win10 computer, and its working fine for most of them. The buggy ones have pretty long path, which seems to be the issue despite a "No Such file or Directory" message from ffprobe, this because :

    


      

    • I checked the path and it exists
    • 


    • In cmd when I mannualy cd to the directory and start ffprobe -i autocompletion complete with the right name
    • 


    • Windows Sub-system Linux achieve to run ffprobe from my copy pasted path extracted from my program
    • 


    


    => the file exist

    


      

    • I made a copy of my file and renamed it with a longer name than the buggy one (ffprobe doesn't work), and also with a really short name (ffprobe works)
    • 


    


    => path size is the culprit
BUT I have enabled long path on both the registry AND the group policy... any ideas ?

    


  • skvideo + ffmpeg : Can't set path to binaries

    9 août 2021, par fukiburi

    For some reason, setting the path to the ffmpeg binaries doesn't work completely.

    


    While it seems like this works like it should :

    


    import skvideo.io
import skvideo.datasets

ffmpeg_path = "C:/Users/xyz/ffmpeg-4.3.1-win64-static/bin/"
skvideo.setFFmpegPath(ffmpeg_path)
print("FFmpeg path: {}".format(skvideo.getFFmpegPath()))
print("FFmpeg version: {}".format(skvideo.getFFmpegVersion()))

>>> FFmpeg path: C:/Users/xyz/ffmpeg-4.3.1-win64-static/bin/
>>> FFmpeg version: b'4'.b'3'.b'1'


    


    Running these lines directly after does not :

    


    videodata = skvideo.io.vread(skvideo.datasets.bigbuckbunny())
print(videodata.shape)

[...]
>>> File "C:\Users\xyz\Anaconda3\envs\cv_env\lib\site-packages\skvideo\io\io.py", line 133, in vread
  assert _HAS_FFMPEG, "Cannot find installation of real FFmpeg (which comes with ffprobe)."
>>> AssertionError: Cannot find installation of real FFmpeg (which comes with ffprobe).


    


    Can't figure out, why it's not set correctly...

    


  • Encoded Video's path gets changed in database after encoding with ffmpeg and celery and works as normal without celery

    16 novembre 2020, par Danny

    I have this code to transcode video and it works well without celery. With celery, the path of the file in the database shows a different path and the video cannot be played in the browser, but it saves the file in the correct location in the pc.

    


    If I don't use celery, then the file path in database is media/videos/videos/<filename>.mp4</filename> and file also gets saved here. This way the template is able to play the video. But if I use celery, the output gets saved in media/videos/videos/<filename>.mp4</filename> but the path in database will be media/<filename>.mp4</filename> somehow and thus template can't play the video.

    &#xA;

    Is it because my page gets updated before the task ? and not getting saved properly ?

    &#xA;

    views.py

    &#xA;

    def post(self, *args, **kwargs):&#xA;    form = VideoPostForm(self.request.POST or None, self.request.FILES or None)&#xA;    if form.is_valid():&#xA;        video = form.save(commit=False)&#xA;        video.user = self.request.user&#xA;        video.save()&#xA;        form.save_m2m()&#xA;        # task_video_encoding(video.id)&#xA;        task_video_encoding.delay(video.id)&#xA;        return redirect(&#x27;videos:my_video_home&#x27;)&#xA;    else:&#xA;        raise ValidationError(&#x27;Check all form fields.&#x27;)&#xA;

    &#xA;

    encoding.py

    &#xA;

    def encode_video(video_id):&#xA;    video = VideoPost.objects.get(id = video_id)&#xA;    input_file_path = video.temp_file.path&#xA;    # print(input_file_path)&#xA;    input_file_name = video.title&#xA;    #get the filename (without extension)&#xA;    filename = os.path.basename(input_file_path)&#xA;    # print(filename)&#xA;    # path to the new file, change it according to where you want to put it&#xA;    output_file_name = os.path.join(&#x27;{}.mp4&#x27;.format(filename))&#xA;    # print(output_file_name)&#xA;    # output_file_path = os.path.join(settings.MEDIA_ROOT, output_file_name)&#xA;    output_file_path = os.path.join(settings.MEDIA_ROOT, &#x27;videos&#x27;, &#x27;videos&#x27;, output_file_name)&#xA;    # print(output_file_path)&#xA;&#xA;    for i in range(1):&#xA;        subprocess.call([settings.VIDEO_ENCODING_FFMPEG_PATH, &#x27;-i&#x27;, input_file_path, &#x27;-codec:v&#x27;, &#x27;libx264&#x27;, &#x27;-crf&#x27;, &#x27;-preset&#x27;,&#xA;                    &#x27;-b:v&#x27;, &#x27;3000k&#x27;, &#x27;-maxrate&#x27;, &#x27;-bufsize&#x27;, &#x27;6000k&#x27;, &#x27;-vf&#x27;, &#x27;scale=-2:720&#x27;,&#xA;                    &#x27;-codec:a&#x27;, &#x27;aac&#x27;, &#x27;128k&#x27;, &#x27;-strict&#x27;, &#x27;-2&#x27;, output_file_path])&#xA;    # Save the new file in the database&#xA;    video.file = output_file_name&#xA;    video.save(update_fields=[&#x27;file&#x27;])&#xA;    print(video.file)&#xA;    video.temp_file.delete()&#xA;

    &#xA;

    models

    &#xA;

    class VideoPost(models.Model):&#xA;    user                = models.ForeignKey(settings.AUTH_USER_MODEL, on_delete=models.CASCADE, blank=True, null=True)&#xA;    title               = models.TextField(max_length=1000)&#xA;    temp_file           = models.FileField(upload_to=&#x27;videos/temp_videos/&#x27;, validators=[validate_file_extension], null=True)&#xA;    file                = models.FileField(upload_to=&#x27;videos/videos/&#x27;, validators=[validate_file_extension], blank=True, max_length=255)&#xA;    post_date           = models.DateTimeField(auto_now_add=True, verbose_name="Date Posted")&#xA;    updated             = models.DateTimeField(auto_now_add=True, verbose_name="Date Updated")&#xA;    slug                = models.SlugField(blank=True, unique=True, max_length=255)&#xA;

    &#xA;

    Can anyone help me how to change this code in a way to show the converted video properly in the template.

    &#xA;