
Recherche avancée
Médias (1)
-
Bug de détection d’ogg
22 mars 2013, par
Mis à jour : Avril 2013
Langue : français
Type : Video
Autres articles (35)
-
La file d’attente de SPIPmotion
28 novembre 2010, parUne file d’attente stockée dans la base de donnée
Lors de son installation, SPIPmotion crée une nouvelle table dans la base de donnée intitulée spip_spipmotion_attentes.
Cette nouvelle table est constituée des champs suivants : id_spipmotion_attente, l’identifiant numérique unique de la tâche à traiter ; id_document, l’identifiant numérique du document original à encoder ; id_objet l’identifiant unique de l’objet auquel le document encodé devra être attaché automatiquement ; objet, le type d’objet auquel (...) -
Utilisation et configuration du script
19 janvier 2011, parInformations spécifiques à la distribution Debian
Si vous utilisez cette distribution, vous devrez activer les dépôts "debian-multimedia" comme expliqué ici :
Depuis la version 0.3.1 du script, le dépôt peut être automatiquement activé à la suite d’une question.
Récupération du script
Le script d’installation peut être récupéré de deux manières différentes.
Via svn en utilisant la commande pour récupérer le code source à jour :
svn co (...) -
Contribute to documentation
13 avril 2011Documentation is vital to the development of improved technical capabilities.
MediaSPIP welcomes documentation by users as well as developers - including : critique of existing features and functions articles contributed by developers, administrators, content producers and editors screenshots to illustrate the above translations of existing documentation into other languages
To contribute, register to the project users’ mailing (...)
Sur d’autres sites (6167)
-
FFMPEG source compilation failed with Android NDK Clang compiler (r16b) with error "the clang compiler does not support '-mcpu=arm'"
10 juillet 2018, par Prasaathvikiwhile compiling FFMPEG source with Android NDK Clang compiler (r16b), I’m getting compiler error.
for the below config :
./configure \
--prefix=/home/prasaathviki/Desktop/ffmpeg/bin/android/26/arm64_26 \
--cross-
prefix=/home/prasaathviki/Desktop/ndk/mytoolchains/r16b/arm64_26/bin/aarch64-linux-android- \
--sysroot="/home/prasaathviki/Desktop/depends/android/ndk/mytoolchains/r16b/arm64_26/sysroot" \
--disable-static \
--disable-doc \
--disable-ffmpeg \
--disable-ffplay \
--disable-ffprobe \
--disable-symver \
--enable-shared \
--enable-protocol=concat \
--enable-protocol=file \
--enable-muxer=mp4 \
--enable-demuxer=mpegts \
--target-os=android \
--enable-decoder=h264 \
--enable-cross-compile \
--arch=arm \
--cpu=arm \
--toolchain=clang-usan \
--extra-cflags="-fPIE -fPIC -ffast-math -funroll-loops -mfloat-abi=softfp -mfpu=vfpv3-d16" \
--extra-ldflags="-pie" \
--cc=/home/prasaathviki/Desktop/ndk/mytoolchains/r16b/arm64_26/bin/aarch64-linux-android-clang \
--cxx=/home/prasaathviki/Desktop/ndk/mytoolchains/r16b/arm64_26/bin/aarch64-linux-android-clang++ \
--ld=/home/prasaathviki/Desktop/ndk/mytoolchains/r16b/arm64_26/bin/aarch64-linux-android-ld \
--as=/home/prasaathviki/Desktop/ndk/mytoolchains/r16b/arm64_26/bin/aarch64-linux-android-clang \
--ar=/home/prasaathviki/Desktop/ndk/mytoolchains/r16b/arm64_26/bin/aarch64-linux-android-ar \
--strip=/home/prasaathviki/Desktop/ndk/mytoolchains/r16b/arm64_26/bin/aarch64-linux-android-stripIn ffbuild/Config.log i’m getting this below error..
/home/prasaathviki/Desktop/ndk/mytoolchains/r16b/arm64_26/bin/aarch64-linux-android-clang --sysroot=/home/prasaathviki/Desktop/depends/android/ndk/mytoolchains/r16b/arm64_26/sysroot -fsanitize=undefined -fPIE -fPIC -ffast-math -funroll-loops -mfloat-abi=softfp -mfpu=vfpv3-d16 -mcpu=arm -c -o /tmp/ffconf.Hn6wyaNC/test.o /tmp/ffconf.Hn6wyaNC/test.c
clang50: error: the clang compiler does not support '-mcpu=arm'
C compiler test failed.Also i have tried without —cpu flag, but still it reported an error as below
/home/prasaathviki/Desktop/ndk/mytoolchains/r16b/arm64_26/bin/aarch64-linux-android-clang --sysroot=/home/prasaathviki/Desktop/depends/android/ndk/mytoolchains/r16b/arm64_26/sysroot -fsanitize=undefined -fPIE -fPIC -ffast-math -funroll-loops -mfloat-abi=softfp -mfpu=vfpv3-d16 -mcpu= -c -o /tmp/ffconf.gQNwoHgC/test.o /tmp/ffconf.gQNwoHgC/test.c
clang50: warning: joined argument expects additional value: '-mcpu=' [-Wunused-command-line-argument]
clang50: error: the clang compiler does not support '-mcpu='
C compiler test failed.Please help me to resolve this issue. Thanks.
-
Getting error "DLL load failed while importing rect : %1 is not a valid Win32 application" while importing package
17 août 2020, par Sagar DonadkarI am using cython package to call Cpp API and in my cpp code i am using ffmpeg library and able to build my code successfully using bellow command


python setup.py build_ext --inplace --compiler=msvc



but when i try to import generated pyd file then i get error


PS D:\SiVUE\Backend\Cython\demo> python
Python 3.8.3 (tags/v3.8.3:6f8c832, May 13 2020, 22:20:19) [MSC v.1925 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import rect
Traceback (most recent call last):
 File "<stdin>", line 1, in <module>
ImportError: DLL load failed while importing rect: %1 is not a valid Win32 application.
>>> 
</module></stdin>


My entire code is provided bellow


header file
#ifndef RECTANGLE_H
#define RECTANGLE_H
#include <iostream>

extern "C"
{
 #include "libavformat/avformat.h"
 #include "libavutil/dict.h"
}

using namespace std;

namespace shapes 
{
 class Rectangle {
 public:
 int x0, y0, x1, y1;
 Rectangle();
 Rectangle(int x0, int y0, int x1, int y1);
 ~Rectangle();
 int getArea();
 int ffmpegFile();
 void getSize(int* width, int* height);
 void move(int dx, int dy);
 };
}

#endif
</iostream>


Rectangle.Cpp file in ffmpegFile() i am calling mostly ffmpeg API



#include <iostream>
#include "Rectangle.hpp"

namespace shapes {
 

 // Default constructor
 Rectangle::Rectangle () {}

 // Overloaded constructor
 Rectangle::Rectangle (int x0, int y0, int x1, int y1) {
 this->x0 = x0;
 this->y0 = y0;
 this->x1 = x1;
 this->y1 = y1;
 }

 // Destructor
 Rectangle::~Rectangle () {}

 // Return the area of the rectangle
 int Rectangle::getArea () {
 return 10;
 }

 // Get the size of the rectangle.
 // Put the size in the pointer args
 void Rectangle::getSize (int *width, int *height) {
 (*width) = x1 - x0;
 (*height) = y1 - y0;
 }

 // Move the rectangle by dx dy
 void Rectangle::move (int dx, int dy) {
 this->x0 += dx;
 this->y0 += dy;
 this->x1 += dx;
 this->y1 += dy;
 }
 int Rectangle::ffmpegFile()
 {
 AVFormatContext *fmt_ctx = NULL;
 AVDictionaryEntry *tag = NULL;
 int ret = 0;
 char* filename = "D:\\Discovery.mp4";

 if ((ret = avformat_open_input(&fmt_ctx, filename, NULL, NULL)))
 return ret;

 if ((ret = avformat_find_stream_info(fmt_ctx, NULL)) < 0) {
 av_log(NULL, AV_LOG_ERROR, "Cannot find stream information\n");
 return ret;
 }

 while ((tag = av_dict_get(fmt_ctx->metadata, "", tag, AV_DICT_IGNORE_SUFFIX)))
 printf("%s=%s\n", tag->key, tag->value);

 avformat_close_input(&fmt_ctx);
 return ret;
 }
}
</iostream>


Rectangle.pxd file declaration for cpp file function and variable


cdef extern from "Rectangle.cpp":
 pass
cdef extern from "Rectangle.hpp" namespace "shapes":
 cdef cppclass Rectangle:
 Rectangle() except +
 Rectangle(int, int, int, int) except +
 int x0, y0, x1, y1
 int getArea()
 void getSize(int* width, int* height)
 void move(int, int)
 int ffmpegFile()



rect.pyx file i am calling cpp API


# distutils: language = c++

from Rectangle cimport Rectangle

cdef class PyRectangle:
 cdef Rectangle c_rect # Hold a C++ instance which we're wrapping

 def __cinit__(self, int x0, int y0, int x1, int y1):
 self.c_rect = Rectangle(x0, y0, x1, y1)

 def get_area(self):
 return self.c_rect.getArea()

 def get_size(self):
 cdef int width, height
 self.c_rect.getSize(&width, &height)
 return width, height

 def move(self):
 print(self.c_rect.ffmpegFile())



setup.py
I provided pyx file and ffmpeg library path as well as include path


from distutils.core import setup
from setuptools import Extension
from Cython.Build import cythonize 

sfc_module = [Extension('rect', sources = ['rect.pyx'],
 include_dirs = ['D:\\SiVUE\\Backend\\Cython\\demo\\ffmpeg\\include\\'],
 library_dirs = ['D:\\SiVUE\\Backend\\Cython\\demo\\ffmpeg\\lib\\'],
 libraries = ['avcodec','avdevice','avfilter','avformat','avutil','postproc','swresample','swscale'],
 language='c++')]

setup(name = 'superfastcode', version = '1.0',
 description = 'Python Package with superfastcode C++ extension',
 ext_modules = cythonize(sfc_module),
 include_dirs = ['D:\\SiVUE\\Backend\\Cython\\demo\\ffmpeg\\include\\']
 )



Thank You


-
Trying to convert an RTSP stream to a HSL file, but get a "Failed to Open Segment" error
1er juin 2021, par Alvydas JuodikisThese are the linux commands I ran on ubuntu 20.04 to convert an rtsp stream to a HLS file. I was trying to then display it onto my html webserver to run a live video but I'm stuck at an error.


ffmpeg -fflags nobuffer \
 -rtsp_transport tcp \
 -i <my rtsp="rtsp" url="url"> \
 -vsync 0 \
 -copyts \
 -vcodec copy \
 -movflags frag_keyframe+empty_moov \
 -an \
 -hls_flags delete_segments+append_list \
 -f segment \
 -segment_list_flags live \
 -segment_time 0.5 \
 -segment_list_size 1 \
 -segment_format mpegts \
 -segment_list Home/Desktop/fmpegsolution/index.m3u8 \
 -segment_list_type m3u8 \
 -segment_list_entry_prefix Home/Desktop/fmpegsolution/ \
 Home/Desktop/fmpegsolution/%3d.ts
</my>


I'm using an example from this link :
https://girishjoshi.io/post/ffmpeg-rtsp-to-hls/


I try to generate my file into a directory located in my desktop called fmpegsolution (hence the output path Home/Desktop/fmpegsolution)


The error :


When running this on terminal, the error comes out to :

[segment @ 0x558c82e11ec0] Opening 'Home/Desktop/fmpegsolution/000.ts' for writing [segment @ 0x558c82e11ec0] Failed to open segment 'Home/Desktop/fmpegsolution/000.ts' Could not write header for output file #0 (incorrect codec parameters ?): No such file or directory


My issue is related to the folder or directory but it definitely exists. I even tried creating a "%3d.ts" blank file (000.ts) but that had no effect. Could use some help. Thanks for your time.