
Recherche avancée
Médias (1)
-
The pirate bay depuis la Belgique
1er avril 2013, par
Mis à jour : Avril 2013
Langue : français
Type : Image
Autres articles (10)
-
Publier sur MédiaSpip
13 juin 2013Puis-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 -
XMP PHP
13 mai 2011, parDixit Wikipedia, XMP signifie :
Extensible Metadata Platform ou XMP est un format de métadonnées basé sur XML utilisé dans les applications PDF, de photographie et de graphisme. Il a été lancé par Adobe Systems en avril 2001 en étant intégré à la version 5.0 d’Adobe Acrobat.
Étant basé sur XML, il gère un ensemble de tags dynamiques pour l’utilisation dans le cadre du Web sémantique.
XMP permet d’enregistrer sous forme d’un document XML des informations relatives à un fichier : titre, auteur, historique (...) -
À propos des documents
21 juin 2013, parQue faire quand un document ne passe pas en traitement, dont le rendu ne correspond pas aux attentes ?
Document bloqué en file d’attente ?
Voici une liste d’actions ordonnée et empirique possible pour tenter de débloquer la situation : Relancer le traitement du document qui ne passe pas Retenter l’insertion du document sur le site MédiaSPIP Dans le cas d’un média de type video ou audio, retravailler le média produit à l’aide d’un éditeur ou un transcodeur. Convertir le document dans un format (...)
Sur d’autres sites (3587)
-
FFMPEG stereo track stops capturing at random times during a capture session
26 mai 2022, par mrwassenI am currently working on building a workflow to capture and archive a large stash of family and friends PAL and NTSC VHS tapes. The hardware setup is as follows :


- 

- JVC HR-7860S VCR
- s-video / RCA audio >
- ADVC-3000 converter
- SDI / BNC cable >
- Blackmagic Decklink Mini Recorder 4K PCIe card
- installed in a fairly hi-spec windows machine : AMD Ryzen 9 5900X 3.7 Ghz base 12 core, GEFORCE RTX 3060 12 gB, 32 gB ram














The plan is to capture to lossless AVI, then drop into an NLE (Vegas Pro v.16) to do a minimal amount of cleanup / trimming, then render to a more compressed video format (TBD) for upload to AWS S3 accessible through a family website.


The issue I am having is that when I run the capture using ffmpeg/directshow e.g. for a perfectly fine 90 min. PAL tape, at some random point of time during the capture one of the 2 stereo channels just stops capturing. This has happened with all of the tapes I have tested so far, and it happens at different times during the same video. I have examined the frames surrounding points in time when this happens, and it doesn't correlate to any transitions or jitter, but often just randomly in the middle of a perfectly smooth scene. Once the one channel stops capturing it never starts back up again during that capture session.


The ADVC-3000 and the VCR are both showing both stereo channels playing normally throughout the capture. The windows machine running the capture hardly breaks a sweat at any time, and the transfer easily keeps up constantly showing a speed = 1x which I assume means nothing lagging. Also there are no video/audio sync issues at any point in time even towards the end of long tapes e.g. 90 mins.


I am fairly new at ffmpeg, so I have spent extensive amounts of time reading up on forum posts and experimenting and have ended up with the following syntax :


ffmpeg -y -f dshow -rtbufsize 2000M -i video="Blackmagic WDM Capture":audio="Blackmagic WDM Capture" -codec:v v210 -pix_fmt yuv422p -codec:a pcm_s16le -b:a 128k -t 02:00:00 -r 25 -threads 4 -maxrate 2500k -filter:a "volume=1.5" output_v210_audio.avi



The capture runs without a single dropped frame, the only error I am getting when launching (and perhaps this is a smoking gun ?) is :




"Non-monotonous DTS in output stream 0:1 ; previous : 0, current : -30 ;
changing to 1. This may result in incorrect timestamps in the output
file."




I have tried to troubleshoot this in the hopes that it is tied to my issue but so far without luck.


Hoping somebody can help correct or modify my command line or perhaps other ideas to help resolve the issue.


-
AVFrame with NV12 format breaks using D3D11 HW acceleration
5 décembre 2024, par faith0058I have a
ffmpeg-autogen
video decoder, im trying to use aD3D11
as HW accelerator, but the frame i get in result(withNV12
format) is broken. If im doing the same withVulkan
as accelerator, everything works fine, butvulkan
uses more graphic card resources..

For rendering i use OpenTK, received frames i convert to RGB with textures and shaders.


Below my decoder initialization.


public VideoStreamDecoder(AVCodecParameters* parameters, AVCodec* codec)
{
 AVCodec* _codec = codec;
 
 _pCodecContext = ffmpeg.avcodec_alloc_context3(_codec);

 ffmpeg.av_hwdevice_ctx_create(&_pCodecContext->hw_device_ctx, AVHWDeviceType.AV_HWDEVICE_TYPE_D3D11VA, null, null, 0).ThrowExceptionIfError();

 ffmpeg.avcodec_parameters_to_context(_pCodecContext, parameters).ThrowExceptionIfError();
 ffmpeg.avcodec_open2(_pCodecContext, _codec, null).ThrowExceptionIfError();

 CodecName = ffmpeg.avcodec_get_name(_codec->id);
 FrameSize = new Size(_pCodecContext->width, _pCodecContext->height);
 PixelFormat = _pCodecContext->pix_fmt;

 _pFrame = ffmpeg.av_frame_alloc();
 _receivedFrame = ffmpeg.av_frame_alloc();
}



And frames reading function


public bool TryReadNextFrame(out AVFrame frame, AVPacket packet)
{
 int error;

 do
 {
 ffmpeg.avcodec_send_packet(_pCodecContext, &packet).ThrowExceptionIfError();

 error = ffmpeg.avcodec_receive_frame(_pCodecContext, _pFrame);

 } while (error == ffmpeg.AVERROR(ffmpeg.EAGAIN));

 error.ThrowExceptionIfError();

 ffmpeg.av_hwframe_transfer_data(_receivedFrame, _pFrame, 0);
 //here i get NV12 frame

 var clonedFrame = ffmpeg.av_frame_clone(_receivedFrame);

 frame = *clonedFrame;

 return true;
}



And here is result i get with both accelerators :


Vulkan

normally working

The same camera, but
D3D11

broken

One more intresting moment, is that cameras, that dont work have
yuv420p
format, the only one working withD3D11
hasyuvj420
.

I tried changing format using
sws_scale
from NV12 to NV12, and it worked, but it uses too much CPU.
Also tried changin format to rgb beforeav_hwframe_transfer_data
function and rendering it using Vulkan rendering, it sort of works withVulkan
, but withD3D11
it doesnt.

UPDATE


I noticed, that frame linesize was bigger, than width and tried


_receivedFrame->linesize[0] = _receivedFrame->width;



And it helped, now image looks better, but still not perfect.


UPDATE 2


I triead also

_receivedFrame->linesize[1] = _receivedFrame->width;
and now everything works just as it should, took me whole day to write two lines of code :)

-
Pass embedded closed captions with FFmpeg
4 décembre 2020, par AndrewI am taking an HLS stream and outputting it through a DeckLink card to convert it to SDI. I need to pass the CEA-708 closed captions that are embedded in the stream, and it has to happen live. This is the command I'm currently using :



ffmpeg.exe -loglevel info -re -i https://my-url.m3u8 -c:v wrapped_avframe -pix_fmt uyvy422 -vf scale=1280x720 -c:a pcm_s16le -ar 48000 -ac 2 -f decklink -s 1280x720 -r 60000/1001 -b:v 4M "DeckLink SDI (2)"



I have tried adding the
-teletext all
command to no avail.


Here is the output of FFprobe :



Input #0, hls, from 'https://my-url.m3u8':
 Duration: N/A, start: 83023.890600, bitrate: N/A
 Program 0
 Metadata:
 variant_bitrate : 998000
 Stream #0:0: Video: h264 (High) ([27][0][0][0] / 0x001B), yuv420p(progressive), 640x360, Closed Captions, 29.97 fps, 29.97 tbr, 90k tbn, 59.94 tbc
 Metadata:
 variant_bitrate : 998000
 Stream #0:1(eng): Audio: aac (LC) ([15][0][0][0] / 0x000F), 44100 Hz, stereo, fltp, 158 kb/s (default)
 Metadata:
 variant_bitrate : 998000
 comment : Master Audio
 Stream #0:2: Data: timed_id3 (ID3 / 0x20334449)
 Metadata:
 variant_bitrate : 998000
 Program 1
 Metadata:
 variant_bitrate : 658000
 Stream #0:3: Video: h264 (High) ([27][0][0][0] / 0x001B), yuv420p(progressive), 480x270, Closed Captions, 29.97 fps, 29.97 tbr, 90k tbn, 59.94 tbc
 Metadata:
 variant_bitrate : 658000
 Stream #0:4(eng): Audio: aac (LC) ([15][0][0][0] / 0x000F), 44100 Hz, stereo, fltp, 158 kb/s (default)
 Metadata:
 variant_bitrate : 658000
 comment : Master Audio
 Stream #0:5: Data: timed_id3 (ID3 / 0x20334449)
 Metadata:
 variant_bitrate : 658000
 Program 2
 Metadata:
 variant_bitrate : 1958000
 Stream #0:6: Video: h264 (High) ([27][0][0][0] / 0x001B), yuv420p(progressive), 960x540, Closed Captions, 29.97 fps, 29.97 tbr, 90k tbn, 59.94 tbc
 Metadata:
 variant_bitrate : 1958000
 Stream #0:7(eng): Audio: aac (LC) ([15][0][0][0] / 0x000F), 44100 Hz, stereo, fltp, 158 kb/s (default)
 Metadata:
 variant_bitrate : 1958000
 comment : Master Audio
 Stream #0:8: Data: timed_id3 (ID3 / 0x20334449)
 Metadata:
 variant_bitrate : 1958000
 Program 3
 Metadata:
 variant_bitrate : 2658000
 Stream #0:9: Video: h264 (High) ([27][0][0][0] / 0x001B), yuv420p(progressive), 1280x720, Closed Captions, 29.97 fps, 29.97 tbr, 90k tbn, 59.94 tbc
 Metadata:
 variant_bitrate : 2658000
 Stream #0:10(eng): Audio: aac (LC) ([15][0][0][0] / 0x000F), 44100 Hz, stereo, fltp, 158 kb/s (default)
 Metadata:
 variant_bitrate : 2658000
 comment : Master Audio
 Stream #0:11: Data: timed_id3 (ID3 / 0x20334449)
 Metadata:
 variant_bitrate : 2658000
Unsupported codec with id 100358 for input stream 2
Unsupported codec with id 100358 for input stream 5
Unsupported codec with id 100358 for input stream 8
Unsupported codec with id 100358 for input stream 11




As you can see, closed captions are embedded in each of the VBR streams, but are getting stripped during the transcode to SDI. How can I pass these to view them ?