How to Insert I-frame or Key-frame in x264enc
Damiano Pinarello
damiano.pinarello at bticino.it
Tue Jan 15 00:11:14 PST 2013
Hi,
I'd need IDR frame for h264 dencoding on client side.
I'm using dm365 on server side.
To obtain IDR fram every X fps I used extended parameters in ti-dmai
in Venc1.c, and I added new PROP_IDR_FRAME_INTERVAL in gstreamer in gsttividenc1.c
With this modifcation I added at gst element TIVidenc1 a new parameter idrFrameInterval.
You can see dm365 manual for h264 (d)enconding.
bye
Damiano
On 23:56 Mon 14 Jan , arpita banerjee wrote:
> I have a server and a client application for video streaming. I have
> used x264enc at server side for encoding.
> I would like to insert a key-frame(IDR or I frame) when any packet
> lost occurs in my video streaming application.
> I know there is an event GstForceKeyUnit to handle dynamic
> key-frame/I-frame request. Could some one explain me what these
> portion of code does in gstx264enc.c in gst-plugins-ugly-0.10.18 ??
>
> if (gst_structure_has_name (s, "GstForceKeyUnit")) {
> /* Set I frame request */
> GST_OBJECT_LOCK (encoder);
> encoder->i_type = X264_TYPE_I;
> encoder->forcekeyunit_event = gst_event_copy (event);
> GST_EVENT_TYPE (encoder->forcekeyunit_event) =
> GST_EVENT_CUSTOM_DOWNSTREAM;
> GST_OBJECT_UNLOCK (encoder);
> forward = FALSE;
> gst_event_unref (event);
> }
>
> If I create a custom upstream event in my server when any packet lost
> occur and send this event to encoder the above code will work or not
> to insert key-frame??
> Please explain someone.
>
> Thanks in advance.
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
--
Damiano PINARELLO
Embedded Software Developer
Office Phone: +(39) 031 653679 Ext. 4679
FAX phone: +(39) 031 653283
Email: damiano.pinarello at bticino.it
Street address: Via L. Manara 4, 22036 Erba (CO), Italy
WebSite: www.bticino.it
------------------------------------------------------------------------------
Please consider your environmental responsibility before printing this Email
------------------------------------------------------------------------------
This message and any attachments are confidential and they also are legally
privileged in accordance with the NDA. If you have received this message in
error, please notify us and remove it from your system.
------------------------------------------------------------------------------
Ce message, ainsi que tous les fichiers joints à ce message,
peuvent contenir des informations sensibles et/ ou confidentielles
ne devant pas être divulguées. Si vous n'êtes pas le destinataire
de ce message (ou que vous recevez ce message par erreur), nous
vous remercions de le notifier immédiatement à son expéditeur, et
de détruire ce message. Toute copie, divulgation, modification,
utilisation ou diffusion, non autorisée, directe ou indirecte, de
tout ou partie de ce message, est strictement interdite.
This e-mail, and any document attached hereby, may contain
confidential and/or privileged information. If you are not the
intended recipient (or have received this e-mail in error) please
notify the sender immediately and destroy this e-mail. Any
unauthorized, direct or indirect, copying, disclosure, distribution
or other use of the material or parts thereof is strictly
forbidden.
More information about the gstreamer-devel
mailing list