
Recherche avancée
Médias (1)
-
Video d’abeille en portrait
14 mai 2011, par
Mis à jour : Février 2012
Langue : français
Type : Video
Autres articles (57)
-
Encodage et transformation en formats lisibles sur Internet
10 avril 2011MediaSPIP transforme et ré-encode les documents mis en ligne afin de les rendre lisibles sur Internet et automatiquement utilisables sans intervention du créateur de contenu.
Les vidéos sont automatiquement encodées dans les formats supportés par HTML5 : MP4, Ogv et WebM. La version "MP4" est également utilisée pour le lecteur flash de secours nécessaire aux anciens navigateurs.
Les documents audios sont également ré-encodés dans les deux formats utilisables par HTML5 :MP3 et Ogg. La version "MP3" (...) -
Les autorisations surchargées par les plugins
27 avril 2010, parMediaspip core
autoriser_auteur_modifier() afin que les visiteurs soient capables de modifier leurs informations sur la page d’auteurs -
Support audio et vidéo HTML5
10 avril 2011MediaSPIP utilise les balises HTML5 video et audio pour la lecture de documents multimedia en profitant des dernières innovations du W3C supportées par les navigateurs modernes.
Pour les navigateurs plus anciens, le lecteur flash Flowplayer est utilisé.
Le lecteur HTML5 utilisé a été spécifiquement créé pour MediaSPIP : il est complètement modifiable graphiquement pour correspondre à un thème choisi.
Ces technologies permettent de distribuer vidéo et son à la fois sur des ordinateurs conventionnels (...)
Sur d’autres sites (5823)
-
lavf/http: Add simple autodetection for client HTTP method, based on AVIO_FLAG_READ.
5 juin 2015, par Stephan Holljes -
Failed to start broadcast : kurento.MediaPipeline not found (Code:40101, Type:null, Data : {"type" :"MEDIA_OBJECT_NOT_FOUND"})
30 avril 2020, par Arslan MaqboolI am facing this issue when I opened any conference room or any meeting then the camera or microphone or sharedscreen is opened from just 1 or 2 seconds and then
 gone and error message popup in the image below which is attached and in text



I am using open-meeting version 5.0.0-M3 WebRTC



> Failed to start broadcast: Object
> '4f09d0d4-f52f-4731-9e54-124e2da0ca9a_kurento.MediaPipeline' not found
> (Code:40101, Type:null, Data: {"type":"MEDIA_OBJECT_NOT_FOUND"})






-
Hardware accelerated decoding with FFmpeg falls back to software decoding
9 février 2024, par iexavSo I have followed the FFmpeg example for hardware accelerated decoding exactly as it is (I am referring to this example).


https://github.com/FFmpeg/FFmpeg/blob/master/doc/examples/hw_decode.c#L76



But I still seem to be decoding with the software decoder. When I open the task manager on windows the GPU isn't getting used. Before I make a call to av_hwframe_transfer_data() I check whether the frame is in the relevant hw_pix_fmt format and it is. Everything works, no errors, nothing, except the GPU is doing nothing. Now as an example I tried decoding a video that uses vp9 as a codec. If I specify the hardware accelerated codec I want by name it actually does work.


vidCodec=avcodec_find_decoder_by_name("vp9_cuvid"); 



When I do this and look at the task manager I can see that the CPU does much less work and my GPU actually does Video Decode work. Having to specify the hardware accelerated decoder for every single video I am decoding is ridiculous though.


Edit : as per user4581301's answer, here are the pieces of relevant code. (It's actually in java because I am using the java FFmpeg wrapper but it's basically just making a bunch of calls to FFmpeg functions.)



 ArrayList<string> deviceTypes = new ArrayList<>();
 int type = AV_HWDEVICE_TYPE_NONE;
 while ((type = av_hwdevice_iterate_types(type)) != AV_HWDEVICE_TYPE_NONE) {
 BytePointer p = av_hwdevice_get_type_name(type);

 deviceTypes.add(CString(p));
 }
 boolean flag=false;

 for(int j=0;j* Allocate a codec context for the decoder */
 if ((video_c = avcodec_alloc_context3(vidCodec)) == null) {
 throw new Exception("avcodec_alloc_context3() error: Could not allocate video decoding context.");
 }


 /* copy the stream parameters from the muxer */

 if ((ret = avcodec_parameters_to_context(video_c, video_st.codecpar())) < 0) {
 releaseUnsafe();
 throw new Exception("avcodec_parameters_to_context() error " + ret + ": Could not copy the video stream parameters.");
 }
 

 video_c.get_format(AvFormatGetter.getInstance());
 AVBufferRef hardwareDeviceContext =av_hwdevice_ctx_alloc(type);

 if ((ret = av_hwdevice_ctx_create(hardwareDeviceContext, type,(String) null, null, 0)) < 0) {
 System.err.println("Failed to create specified HW device. error " + ret);

 }else{
 video_c.hw_device_ctx(av_buffer_ref(hardwareDeviceContext));

 }
 


 
//The function that gets called for get_format
@Override
 public int call(AVCodecContext context, IntPointer format) {
 int p;


 for (int i=0;;i++) {
 if ((p=format.get(i)) == hw_pix_fmt) {
 return p;
 }
 if(p==-1){
 break;
 }
 }

 System.out.println(hw_pix_fmt +" is not found in the codec context");
 // Error

 return AV_PIX_FMT_NONE;
 }
 
//The method that's used for decoding video frames
 public Optional<boolean> decodeVideoFrame(AVPacket pkt, boolean readPacket, boolean keyFrames) throws Exception {

 int ret;
 // Decode video frame
 if (readPacket) {
 ret = avcodec_send_packet(video_c, pkt);
 
 if (ret < 0) {
 System.out.println("error during decoding");
 return Optional.empty();
 }

 if (pkt.data() == null && pkt.size() == 0) {
 pkt.stream_index(-1);
 }
 
 }

 // Did we get a video frame?
 while (true) {
 ret = avcodec_receive_frame(video_c, picture_hw);

 if (ret == AVERROR_EAGAIN() || ret == AVERROR_EOF()) {
 if (pkt.data() == null && pkt.size() == 0) {
 return Optional.empty();
 } else {

 return Optional.of(true);

 }
 } else if (ret < 0) {

 // Ignore errors to emulate the behavior of the old API
 // throw new Exception("avcodec_receive_frame() error " + ret + ": Error during video decoding.");
 return Optional.of(true);

 }

 if (!keyFrames || picture.pict_type() == AV_PICTURE_TYPE_I) {
 
 if(picture_hw.format()==hw_pix_fmt){
 if (av_hwframe_transfer_data(
 picture, // The frame that will contain the usable data.
 picture_hw, // Frame returned by avcodec_receive_frame()
 0) < 0) {
 throw new Exception("Could not transfer data from gpu to cpu. ");

 }
 }
 //... The rest of the method here
 return Optional.of(false);

 }
 }
 }
</boolean></string>