Recherche avancée

Médias (91)

Autres articles (112)

  • Personnaliser en ajoutant son logo, sa bannière ou son image de fond

    5 septembre 2013, par

    Certains thèmes prennent en compte trois éléments de personnalisation : l’ajout d’un logo ; l’ajout d’une bannière l’ajout d’une image de fond ;

  • Ecrire une actualité

    21 juin 2013, par

    Présentez les changements dans votre MédiaSPIP ou les actualités de vos projets sur votre MédiaSPIP grâce à la rubrique actualités.
    Dans le thème par défaut spipeo de MédiaSPIP, les actualités sont affichées en bas de la page principale sous les éditoriaux.
    Vous pouvez personnaliser le formulaire de création d’une actualité.
    Formulaire de création d’une actualité Dans le cas d’un document de type actualité, les champs proposés par défaut sont : Date de publication ( personnaliser la date de publication ) (...)

  • Le profil des utilisateurs

    12 avril 2011, par

    Chaque utilisateur dispose d’une page de profil lui permettant de modifier ses informations personnelle. Dans le menu de haut de page par défaut, un élément de menu est automatiquement créé à l’initialisation de MediaSPIP, visible uniquement si le visiteur est identifié sur le site.
    L’utilisateur a accès à la modification de profil depuis sa page auteur, un lien dans la navigation "Modifier votre profil" est (...)

Sur d’autres sites (14004)

  • rtmppkt : Repeat the full 32 bit timestamp for chunking continuation packets

    14 janvier 2015, par Martin Storsjö
    rtmppkt : Repeat the full 32 bit timestamp for chunking continuation packets
    

    This fixes sending chunked packets (packets larger than the output
    chunk size, which often can be e.g. 4096 bytes) with a timestamp delta
    (or absolute timstamp, if it’s a timestamp step backwards, or the
    first packet of the stream) larger than 0xffffffff.

    The RTMP spec explicitly says (in section 5.3.1.3.) that packets of
    type 3 (continuation packets) should include this field, if the
    previous non-continuation packet had it included.

    The receiving code handles these packets correctly.

    Pointed out by Cheolho Park.

    CC : libav-stable@libav.org
    Signed-off-by : Martin Storsjö <martin@martin.st>

    • [DBH] libavformat/rtmppkt.c
  • Copy ffmpeg d3dva texture resource to shared rendering texture

    10 juin 2020, par Teamol

    I'm using ffmpeg to decode video via d3dva based on this example https://github.com/FFmpeg/FFmpeg/blob/master/doc/examples/hw_decode.c. I'm able to succesfully decode video. What I need to do next is to render decoded NV12 frame. I have created directx rendering texture based on this example https://github.com/balapradeepswork/D3D11NV12Rendering and set it as shared.

    &#xA;&#xA;

        D3D11_TEXTURE2D_DESC texDesc;&#xA;    texDesc.Format = DXGI_FORMAT_NV12;              // Pixel format&#xA;    texDesc.Width = width;                          // Width of the video frames&#xA;    texDesc.Height = height;                        // Height of the video frames&#xA;    texDesc.ArraySize = 1;                          // Number of textures in the array&#xA;    texDesc.MipLevels = 1;                          // Number of miplevels in each texture&#xA;    texDesc.BindFlags = D3D11_BIND_SHADER_RESOURCE; // We read from this texture in the shader&#xA;    texDesc.Usage = D3D11_USAGE_DEFAULT;&#xA;    texDesc.MiscFlags = D3D11_RESOURCE_MISC_SHARED;&#xA;    texDesc.CPUAccessFlags = 0;&#xA;&#xA;    hr = device.CreateTexture2D(&amp;texDesc, null, &amp;nv12Texture);&#xA;    if (FAILED(hr))&#xA;    {&#xA;        error("Failed to create NV12 texture (hr: %s)", hr);&#xA;        return false;&#xA;    }&#xA;&#xA;    // QI IDXGIResource interface to synchronized shared surface.&#xA;    IDXGIResource dxgiResource;&#xA;    nv12Texture.QueryInterface(&amp;IID_IDXGIResource, cast(void**)&amp;dxgiResource);&#xA;&#xA;    // obtain handle to IDXGIResource object.&#xA;    hr = dxgiResource.GetSharedHandle(&amp;sharedHandle);&#xA;    dxgiResource.Release();&#xA;    dxgiResource = null;&#xA;&#xA;    if (FAILED(hr))&#xA;    {&#xA;        error("Failed to create NV12 texture shared handle (hr: %s)", hr);&#xA;        return false;&#xA;    }&#xA;

    &#xA;&#xA;

    I'm then trying to copy nv12 from ffmpeg texture to my rendering texture. exactly as ffmpeg does in function d3d11va_transfer_data.

    &#xA;&#xA;

        ID3D11Texture2D hwTexture = cast(ID3D11Texture2D)frame.data[0];&#xA;&#xA;    ID3D11Device hwDevice;&#xA;    hwTexture.GetDevice(&amp;hwDevice);&#xA;&#xA;    ID3D11DeviceContext hwDeviceCtx;&#xA;    hwDevice.GetImmediateContext(&amp;hwDeviceCtx);&#xA;&#xA;    ID3D11Texture2D sharedTexture;&#xA;&#xA;    HRESULT hr = device.OpenSharedResource(sharedHandle, &amp;IID_ID3D11Texture2D,cast(void**) &amp;sharedTexture);&#xA;    if(FAILED(hr))&#xA;    {&#xA;        error("Failed to obtaion open shared resource.");&#xA;        return;&#xA;    }&#xA;&#xA;    int index = cast(int)frame.data[1];&#xA;    hwDeviceCtx.CopySubresourceRegion(sharedTexture, 0, 0, 0, 0, hwTexture, index, null);&#xA;

    &#xA;&#xA;

    But the rendering window is just green no error no FAILED hr result nothing. I'm able render frames when I'm using sw decoder I just create texture with D3D11_USAGE_DYNAMIC and D3D11_CPU_ACCESS_WRITE.

    &#xA;&#xA;

    Here us desc of each texture.

    &#xA;&#xA;

    hwTexture desc D3D11_TEXTURE2D_DESC(1280, 720, 1, 20, 103, DXGI_SAMPLE_DESC(1, 0), 0, 512, 0, 0)&#xA;nv12Texture desc D3D11_TEXTURE2D_DESC(1280, 720, 1, 1, 103, DXGI_SAMPLE_DESC(1, 0), 0, 8, 0, 2)&#xA;sharedTexture desc D3D11_TEXTURE2D_DESC(1280, 720, 1, 1, 103, DXGI_SAMPLE_DESC(1, 0), 0, 8, 0, 2)&#xA;

    &#xA;&#xA;

    Any idea what I'm missing ?

    &#xA;

  • php ffmpeg exec & shell_exec process stops after few seconds

    6 octobre 2019, par Salem

    I’m using PHP script file with simple html interface to control FFMPEG process start and stop from the browser , the script goal is start live streaming on my server that usually runs for hours without stop (using ffmpeg and nginx-rtmp )
    my script were working perfectly until I notice recently This is strange behaviors
    here is my php script variables

    $cast =" /usr/sbin/ffmpeg -loglevel 0 -thread_queue_size 32768 -re -i '".$src."' -i /var/www/example/logo.png -r 23.976 -strict -2 480x360 -aspect 16:9 -filter_complex 'overlay=x=(main_w-overlay_w)/2:y=(main_h-overlay_h)-23' -vcodec libx264 -x264opts colormatrix=bt709 -profile:v high444 4 -b:v 290k -maxrate 290k -bufsize 250k  -af "aresample=async=1:min_hard_comp=0.100000:first_pts=0" -acodec libfdk_aac -profile:a aac_he_v2 -b:a 16k -map_metadata -1 -f flv  rtmp://localhost/hls/live 2>/dev/null >/dev/null  &amp; " ;
    $output =  shell_exec( $cast   )    ;

    It’s like FFMPEG process continue until original php process ( that call it ) die , at first I thought this issue with the sorce or ffmpeg command but I test the same command on the sell and it works perfectly .
    My suspicion are with on STDIO etc were not redirected right . even when I excute the same php script from the shell it’s do the same stops after few seconds .

    =Edit=

    Even when I tried to run ffmpeg from the command line and make it run on the background , I got same behavior the process stop after few seconds , ffmpeg continue running only if I wait for it output .

    Here my OS details :-

    DISTRIB_DESCRIPTION="Ubuntu 18.04.3 LTS"
    NAME="Ubuntu"
    VERSION="18.04.3 LTS (Bionic Beaver)"