SlideShare a Scribd company logo
UDPSRC Gstreamer Plugin
Session VIII
UDPSRC - Overview
• Source element
– Receives the packet from UDP port & provide it
over gstreamer pipeline
– Contains Single PAD ( source PAD )
Properties
• PROP_PORT
• PROP_MULTICAST_GROUP
• PROP_MULTICAST_IFACE
• PROP_URI
• PROP_CAPS
• PROP_SOCKFD
• PROP_BUFFER_SIZE
• PROP_TIMEOUT
• PROP_SKIP_FIRST_BYTES
• PROP_CLOSEFD
• PROP_SOCK
• PROP_AUTO_MULTICAST
• PROP_REUSE
gst_udpsrc_base_init
• Does the base initialization of udpsrc source
element
• Adds / registers the static source PAD
gst_udpsrc_base_init
static void gst_udpsrc_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
gst_element_class_add_static_pad_template (element_class,
&src_template);
gst_element_class_set_details_simple (element_class, "UDP packet
receiver",
"Source/Network",
"Receive data over the network via UDP",
"Wim Taymans <wim@fluendo.com>, "
"Thijs Vermeir <thijs.vermeir@barco.com>");
}
gst_udpsrc_class_init
• Call back function initialization to
– Get property - gst_udpsrc_get_property
– Set property - gst_udpsrc_set_property
– Finalize - gst_udpsrc_finalize
– Start - gst_udpsrc_start
– Stop - gst_udpsrc_stop
– Unlock - gst_udpsrc_unlock
– Unlock_stop - gst_udpsrc_unlock_stop
– Getcaps - gst_udpsrc_getcaps
– Create - gst_udpsrc_create
gst_udpsrc_class_init
• Initialization / registeration of element properties
– Port – Port Number ( int )
– Multicast-group : Name of group ( String )
– Multicast-iface : Name of Interface ( String )
– Uri : string
– Sockfd – Socket handler ( int )
– Buffer-size – Buffer-Size (int )
– Timeout – (int)
– Skip First bytes – Number of byte to skip ( int )
– closeFd – Close sockfd if passed as property of state change ( int )
– Sock – Socket Handle ( int )
– Auto-multicast – Automatically joins / leaves multicast groups ( int )
– Reuse : Enables reuse of the port ( boolean )
Property registration
• Property registration is done by
– g_object_class_install_property
• Parameter specified by either
– g_param_spec_int
– g_param_spec_string
– g_param_spec_boolean
– g_param_spec_uint64
gst_udpsrc_init
• Initializes uri string
• Initializes all the property variables
gst_udpsrc_finalize
• This does the cleanup & frees the memory
• unref the capabilities
• frees memory of multicast_iface
• frees memory of uri & uristr
• Closes the socket, if closeFd option enabled
• Cleanup the object
• Finalize gstreamer base object
gst_udpsrc_getcaps
static GstCaps *
gst_udpsrc_getcaps (GstBaseSrc * src)
{
GstUDPSrc *udpsrc;
udpsrc = GST_UDPSRC (src);
if (udpsrc->caps)
return gst_caps_ref (udpsrc->caps);
else
return gst_caps_new_any ();
}
clear_error
• Reads a message from error queue
• Flushes ERROR from fd so next poll will not
return at once
• Local address handling without address
gst_udpsrc_start
• Gets URI information
• Creates a socket
• Enables port reuse option using setsockopt, if
reuse is enabled
• Set socket name if it is multicast
• Configure the kernel receiver buffer size, if buffer-
size parameter is given
• Add the socket into poll fd
• Add the socket into control fd read
gst_udpsrc_stop
static gboolean
gst_udpsrc_stop (GstBaseSrc * bsrc)
{
GstUDPSrc *src;
src = GST_UDPSRC (bsrc);
GST_DEBUG ("stopping, closing sockets");
if (src->sock.fd >= 0) {
if (src->auto_multicast && gst_udp_is_multicast (&src->myaddr)) {
GST_DEBUG_OBJECT (src, "leaving multicast group %s", src->uri.host);
gst_udp_leave_group (src->sock.fd, &src->myaddr);
}
CLOSE_IF_REQUESTED (src);
}
if (src->fdset) {
gst_poll_free (src->fdset);
src->fdset = NULL;
}
return TRUE;
}
gst_udpsrc_create
• Wait for the socket data using gst_poll_wait
• Recv the packet from socket using recvfrom
• Allocate memory for sending data to stream
• Skip first bytes if the option is enabled
• Buffer cast the data to flow into pipeline.
Get Type & Protocols
static GstURIType
gst_udpsrc_uri_get_type (void)
{
return GST_URI_SRC;
}
static gchar **
gst_udpsrc_uri_get_protocols (void)
{
static gchar *protocols[] = { (char *) "udp", NULL };
return protocols;
}
Get & Set URI
static const gchar * gst_udpsrc_uri_get_uri (GstURIHandler * handler)
{
GstUDPSrc *src = GST_UDPSRC (handler);
g_free (src->uristr);
src->uristr = gst_udp_uri_string (&src->uri);
return src->uristr;
}
static gboolean gst_udpsrc_uri_set_uri (GstURIHandler * handler, const gchar * uri)
{
gboolean ret;
GstUDPSrc *src = GST_UDPSRC (handler);
ret = gst_udpsrc_set_uri (src, uri);
return ret;
}
gst_udpsrc_uri_handler_init
static void
gst_udpsrc_uri_handler_init (gpointer g_iface, gpointer
iface_data)
{
GstURIHandlerInterface *iface = (GstURIHandlerInterface *)
g_iface;
iface->get_type = gst_udpsrc_uri_get_type;
iface->get_protocols = gst_udpsrc_uri_get_protocols;
iface->get_uri = gst_udpsrc_uri_get_uri;
iface->set_uri = gst_udpsrc_uri_set_uri;
}

More Related Content

What's hot

20160407_GTC2016_PgSQL_In_Place
20160407_GTC2016_PgSQL_In_Place20160407_GTC2016_PgSQL_In_Place
20160407_GTC2016_PgSQL_In_Place
Kohei KaiGai
 
Perl on embedded Linux with Buildroot‎
Perl on embedded Linux with Buildroot‎Perl on embedded Linux with Buildroot‎
Perl on embedded Linux with Buildroot‎
François Perrad
 
pgconfasia2016 plcuda en
pgconfasia2016 plcuda enpgconfasia2016 plcuda en
pgconfasia2016 plcuda en
Kohei KaiGai
 
Roll your own toy unix clone os
Roll your own toy unix clone osRoll your own toy unix clone os
Roll your own toy unix clone os
eramax
 
20170602_OSSummit_an_intelligent_storage
20170602_OSSummit_an_intelligent_storage20170602_OSSummit_an_intelligent_storage
20170602_OSSummit_an_intelligent_storage
Kohei KaiGai
 
Osol Pgsql
Osol PgsqlOsol Pgsql
Osol Pgsql
Emanuel Calvo
 
Bpf performance tools chapter 4 bcc
Bpf performance tools chapter 4   bccBpf performance tools chapter 4   bcc
Bpf performance tools chapter 4 bcc
Viller Hsiao
 
C++ amp on linux
C++ amp on linuxC++ amp on linux
C++ amp on linux
Miller Lee
 
How to make a large C++-code base manageable
How to make a large C++-code base manageableHow to make a large C++-code base manageable
How to make a large C++-code base manageable
corehard_by
 
Доклад Антона Поварова "Go in Badoo" с Golang Meetup
Доклад Антона Поварова "Go in Badoo" с Golang MeetupДоклад Антона Поварова "Go in Badoo" с Golang Meetup
Доклад Антона Поварова "Go in Badoo" с Golang Meetup
Badoo Development
 
Make the prompt great again
Make the prompt great againMake the prompt great again
Make the prompt great again
jtyr
 
Deploying Prometheus stacks with Juju
Deploying Prometheus stacks with JujuDeploying Prometheus stacks with Juju
Deploying Prometheus stacks with Juju
J.J. Ciarlante
 
Ganglia Overview-v2
Ganglia Overview-v2Ganglia Overview-v2
Ganglia Overview-v2
Chris Westin
 
Pusherアプリの作り方
Pusherアプリの作り方Pusherアプリの作り方
Pusherアプリの作り方
Jun OHWADA
 
Great Hiroshima with Python 170830
Great Hiroshima with Python 170830Great Hiroshima with Python 170830
Great Hiroshima with Python 170830
Takuya Nishimoto
 
Building Network Functions with eBPF & BCC
Building Network Functions with eBPF & BCCBuilding Network Functions with eBPF & BCC
Building Network Functions with eBPF & BCC
Kernel TLV
 
ExperiencesSharingOnEmbeddedSystemDevelopment_20160321
ExperiencesSharingOnEmbeddedSystemDevelopment_20160321ExperiencesSharingOnEmbeddedSystemDevelopment_20160321
ExperiencesSharingOnEmbeddedSystemDevelopment_20160321Teddy Hsiung
 
Understanding eBPF in a Hurry!
Understanding eBPF in a Hurry!Understanding eBPF in a Hurry!
Understanding eBPF in a Hurry!
Ray Jenkins
 
Introduction to cuda geek camp singapore 2011
Introduction to cuda   geek camp singapore 2011Introduction to cuda   geek camp singapore 2011
Introduction to cuda geek camp singapore 2011
Raymond Tay
 
Vpu technology &gpgpu computing
Vpu technology &gpgpu computingVpu technology &gpgpu computing
Vpu technology &gpgpu computingArka Ghosh
 

What's hot (20)

20160407_GTC2016_PgSQL_In_Place
20160407_GTC2016_PgSQL_In_Place20160407_GTC2016_PgSQL_In_Place
20160407_GTC2016_PgSQL_In_Place
 
Perl on embedded Linux with Buildroot‎
Perl on embedded Linux with Buildroot‎Perl on embedded Linux with Buildroot‎
Perl on embedded Linux with Buildroot‎
 
pgconfasia2016 plcuda en
pgconfasia2016 plcuda enpgconfasia2016 plcuda en
pgconfasia2016 plcuda en
 
Roll your own toy unix clone os
Roll your own toy unix clone osRoll your own toy unix clone os
Roll your own toy unix clone os
 
20170602_OSSummit_an_intelligent_storage
20170602_OSSummit_an_intelligent_storage20170602_OSSummit_an_intelligent_storage
20170602_OSSummit_an_intelligent_storage
 
Osol Pgsql
Osol PgsqlOsol Pgsql
Osol Pgsql
 
Bpf performance tools chapter 4 bcc
Bpf performance tools chapter 4   bccBpf performance tools chapter 4   bcc
Bpf performance tools chapter 4 bcc
 
C++ amp on linux
C++ amp on linuxC++ amp on linux
C++ amp on linux
 
How to make a large C++-code base manageable
How to make a large C++-code base manageableHow to make a large C++-code base manageable
How to make a large C++-code base manageable
 
Доклад Антона Поварова "Go in Badoo" с Golang Meetup
Доклад Антона Поварова "Go in Badoo" с Golang MeetupДоклад Антона Поварова "Go in Badoo" с Golang Meetup
Доклад Антона Поварова "Go in Badoo" с Golang Meetup
 
Make the prompt great again
Make the prompt great againMake the prompt great again
Make the prompt great again
 
Deploying Prometheus stacks with Juju
Deploying Prometheus stacks with JujuDeploying Prometheus stacks with Juju
Deploying Prometheus stacks with Juju
 
Ganglia Overview-v2
Ganglia Overview-v2Ganglia Overview-v2
Ganglia Overview-v2
 
Pusherアプリの作り方
Pusherアプリの作り方Pusherアプリの作り方
Pusherアプリの作り方
 
Great Hiroshima with Python 170830
Great Hiroshima with Python 170830Great Hiroshima with Python 170830
Great Hiroshima with Python 170830
 
Building Network Functions with eBPF & BCC
Building Network Functions with eBPF & BCCBuilding Network Functions with eBPF & BCC
Building Network Functions with eBPF & BCC
 
ExperiencesSharingOnEmbeddedSystemDevelopment_20160321
ExperiencesSharingOnEmbeddedSystemDevelopment_20160321ExperiencesSharingOnEmbeddedSystemDevelopment_20160321
ExperiencesSharingOnEmbeddedSystemDevelopment_20160321
 
Understanding eBPF in a Hurry!
Understanding eBPF in a Hurry!Understanding eBPF in a Hurry!
Understanding eBPF in a Hurry!
 
Introduction to cuda geek camp singapore 2011
Introduction to cuda   geek camp singapore 2011Introduction to cuda   geek camp singapore 2011
Introduction to cuda geek camp singapore 2011
 
Vpu technology &gpgpu computing
Vpu technology &gpgpu computingVpu technology &gpgpu computing
Vpu technology &gpgpu computing
 

Viewers also liked

Introduction to Graphics - Session
Introduction to Graphics - SessionIntroduction to Graphics - Session
Introduction to Graphics - Session
NEEVEE Technologies
 
TMS20DM8148 Embedded Linux Session II
TMS20DM8148 Embedded Linux Session IITMS20DM8148 Embedded Linux Session II
TMS20DM8148 Embedded Linux Session II
NEEVEE Technologies
 
TMS320DM8148 Embedded Linux
TMS320DM8148 Embedded LinuxTMS320DM8148 Embedded Linux
TMS320DM8148 Embedded Linux
NEEVEE Technologies
 
Brain maturation
Brain maturationBrain maturation
Brain maturation
Ludmila Kalinichenko
 
Heap and Partners
Heap and PartnersHeap and Partners
Heap and Partners
Hardide Coatings
 
Tutorial para crear cuenta en slideshare
Tutorial para crear cuenta en slideshareTutorial para crear cuenta en slideshare
Tutorial para crear cuenta en slideshare
Annie Nitzschke Peña
 
Device driver
Device driverDevice driver
Device driver
Yongjae Choi
 
Isabelle: Not Only a Proof Assistant
Isabelle: Not Only a Proof AssistantIsabelle: Not Only a Proof Assistant
Isabelle: Not Only a Proof Assistant
Achim D. Brucker
 
Geog 5 fa 2012 schmidt fri
Geog 5 fa 2012 schmidt friGeog 5 fa 2012 schmidt fri
Geog 5 fa 2012 schmidt frilschmidt1170
 
오픈세미나 플러그인만들기(한번더)
오픈세미나 플러그인만들기(한번더)오픈세미나 플러그인만들기(한번더)
오픈세미나 플러그인만들기(한번더)
승훈 오
 
Pi3 Ef 7 Pe Revision Class
Pi3 Ef 7 Pe Revision ClassPi3 Ef 7 Pe Revision Class
Pi3 Ef 7 Pe Revision ClassAna Menezes
 
Tg discussion guide90
Tg discussion guide90Tg discussion guide90
Tg discussion guide90lschmidt1170
 
學生學習歷程簡報
學生學習歷程簡報學生學習歷程簡報
學生學習歷程簡報
Fang-fang
 
Grouping objects
Grouping objectsGrouping objects
Grouping objects
Ludmila Kalinichenko
 

Viewers also liked (19)

Introduction to Graphics - Session
Introduction to Graphics - SessionIntroduction to Graphics - Session
Introduction to Graphics - Session
 
EIA FINAL
EIA FINALEIA FINAL
EIA FINAL
 
TMS20DM8148 Embedded Linux Session II
TMS20DM8148 Embedded Linux Session IITMS20DM8148 Embedded Linux Session II
TMS20DM8148 Embedded Linux Session II
 
TMS320DM8148 Embedded Linux
TMS320DM8148 Embedded LinuxTMS320DM8148 Embedded Linux
TMS320DM8148 Embedded Linux
 
Brain maturation
Brain maturationBrain maturation
Brain maturation
 
Heap and Partners
Heap and PartnersHeap and Partners
Heap and Partners
 
Tutorial para crear cuenta en slideshare
Tutorial para crear cuenta en slideshareTutorial para crear cuenta en slideshare
Tutorial para crear cuenta en slideshare
 
Kpi publikovani 2
Kpi publikovani 2Kpi publikovani 2
Kpi publikovani 2
 
Device driver
Device driverDevice driver
Device driver
 
r3-4-2009f_xts5000_new
r3-4-2009f_xts5000_newr3-4-2009f_xts5000_new
r3-4-2009f_xts5000_new
 
Isabelle: Not Only a Proof Assistant
Isabelle: Not Only a Proof AssistantIsabelle: Not Only a Proof Assistant
Isabelle: Not Only a Proof Assistant
 
CV_SANJAY SOHIL
CV_SANJAY SOHILCV_SANJAY SOHIL
CV_SANJAY SOHIL
 
Geog 5 fa 2012 schmidt fri
Geog 5 fa 2012 schmidt friGeog 5 fa 2012 schmidt fri
Geog 5 fa 2012 schmidt fri
 
오픈세미나 플러그인만들기(한번더)
오픈세미나 플러그인만들기(한번더)오픈세미나 플러그인만들기(한번더)
오픈세미나 플러그인만들기(한번더)
 
CV_Jeeshan CPE
CV_Jeeshan CPECV_Jeeshan CPE
CV_Jeeshan CPE
 
Pi3 Ef 7 Pe Revision Class
Pi3 Ef 7 Pe Revision ClassPi3 Ef 7 Pe Revision Class
Pi3 Ef 7 Pe Revision Class
 
Tg discussion guide90
Tg discussion guide90Tg discussion guide90
Tg discussion guide90
 
學生學習歷程簡報
學生學習歷程簡報學生學習歷程簡報
學生學習歷程簡報
 
Grouping objects
Grouping objectsGrouping objects
Grouping objects
 

Similar to UDPSRC GStreamer Plugin Session VIII

Ganglia Monitoring Tool
Ganglia Monitoring ToolGanglia Monitoring Tool
Ganglia Monitoring Tool
sudhirpg
 
Facebook C++网络库Wangle调研
Facebook C++网络库Wangle调研Facebook C++网络库Wangle调研
Facebook C++网络库Wangle调研
vorfeed chen
 
Bruce Momjian - Inside PostgreSQL Shared Memory @ Postgres Open
Bruce Momjian - Inside PostgreSQL Shared Memory @ Postgres OpenBruce Momjian - Inside PostgreSQL Shared Memory @ Postgres Open
Bruce Momjian - Inside PostgreSQL Shared Memory @ Postgres OpenPostgresOpen
 
#2 (UDP)
#2 (UDP)#2 (UDP)
#2 (UDP)
Ghadeer AlHasan
 
Udp Programming
Udp ProgrammingUdp Programming
Udp Programmingphanleson
 
Writing an Ostinato Protocol Builder [FOSDEM 2021]
Writing an Ostinato Protocol Builder [FOSDEM 2021]Writing an Ostinato Protocol Builder [FOSDEM 2021]
Writing an Ostinato Protocol Builder [FOSDEM 2021]
pstavirs
 
What’s new in 9.6, by PostgreSQL contributor
What’s new in 9.6, by PostgreSQL contributorWhat’s new in 9.6, by PostgreSQL contributor
What’s new in 9.6, by PostgreSQL contributor
Masahiko Sawada
 
Around the world with extensions | PostgreSQL Conference Europe 2018 | Craig ...
Around the world with extensions | PostgreSQL Conference Europe 2018 | Craig ...Around the world with extensions | PostgreSQL Conference Europe 2018 | Craig ...
Around the world with extensions | PostgreSQL Conference Europe 2018 | Craig ...
Citus Data
 
CUDA Deep Dive
CUDA Deep DiveCUDA Deep Dive
CUDA Deep Dive
krasul
 
SF Big Analytics 20191112: How to performance-tune Spark applications in larg...
SF Big Analytics 20191112: How to performance-tune Spark applications in larg...SF Big Analytics 20191112: How to performance-tune Spark applications in larg...
SF Big Analytics 20191112: How to performance-tune Spark applications in larg...
Chester Chen
 
High Availability PostgreSQL with Zalando Patroni
High Availability PostgreSQL with Zalando PatroniHigh Availability PostgreSQL with Zalando Patroni
High Availability PostgreSQL with Zalando Patroni
Zalando Technology
 
HSA Kernel Code (KFD v0.6)
HSA Kernel Code (KFD v0.6)HSA Kernel Code (KFD v0.6)
HSA Kernel Code (KFD v0.6)
Hann Yu-Ju Huang
 
Need help implementing the skeleton code below, I have provided the .pdf
Need help implementing the skeleton code below, I have provided the .pdfNeed help implementing the skeleton code below, I have provided the .pdf
Need help implementing the skeleton code below, I have provided the .pdf
ezzi552
 
[232]TensorRT를 활용한 딥러닝 Inference 최적화
[232]TensorRT를 활용한 딥러닝 Inference 최적화[232]TensorRT를 활용한 딥러닝 Inference 최적화
[232]TensorRT를 활용한 딥러닝 Inference 최적화
NAVER D2
 
[232] TensorRT를 활용한 딥러닝 Inference 최적화
[232] TensorRT를 활용한 딥러닝 Inference 최적화[232] TensorRT를 활용한 딥러닝 Inference 최적화
[232] TensorRT를 활용한 딥러닝 Inference 최적화
NAVER D2
 
Qt Rest Server
Qt Rest ServerQt Rest Server
Qt Rest Server
Vasiliy Sorokin
 
Василий Сорокин, Простой REST сервер на Qt с рефлексией
Василий Сорокин, Простой REST сервер на Qt с рефлексиейВасилий Сорокин, Простой REST сервер на Qt с рефлексией
Василий Сорокин, Простой REST сервер на Qt с рефлексией
Sergey Platonov
 

Similar to UDPSRC GStreamer Plugin Session VIII (20)

Ganglia Monitoring Tool
Ganglia Monitoring ToolGanglia Monitoring Tool
Ganglia Monitoring Tool
 
Facebook C++网络库Wangle调研
Facebook C++网络库Wangle调研Facebook C++网络库Wangle调研
Facebook C++网络库Wangle调研
 
Bruce Momjian - Inside PostgreSQL Shared Memory @ Postgres Open
Bruce Momjian - Inside PostgreSQL Shared Memory @ Postgres OpenBruce Momjian - Inside PostgreSQL Shared Memory @ Postgres Open
Bruce Momjian - Inside PostgreSQL Shared Memory @ Postgres Open
 
#2 (UDP)
#2 (UDP)#2 (UDP)
#2 (UDP)
 
Udp Programming
Udp ProgrammingUdp Programming
Udp Programming
 
Udp Programming
Udp ProgrammingUdp Programming
Udp Programming
 
Writing an Ostinato Protocol Builder [FOSDEM 2021]
Writing an Ostinato Protocol Builder [FOSDEM 2021]Writing an Ostinato Protocol Builder [FOSDEM 2021]
Writing an Ostinato Protocol Builder [FOSDEM 2021]
 
What’s new in 9.6, by PostgreSQL contributor
What’s new in 9.6, by PostgreSQL contributorWhat’s new in 9.6, by PostgreSQL contributor
What’s new in 9.6, by PostgreSQL contributor
 
Around the world with extensions | PostgreSQL Conference Europe 2018 | Craig ...
Around the world with extensions | PostgreSQL Conference Europe 2018 | Craig ...Around the world with extensions | PostgreSQL Conference Europe 2018 | Craig ...
Around the world with extensions | PostgreSQL Conference Europe 2018 | Craig ...
 
CUDA Deep Dive
CUDA Deep DiveCUDA Deep Dive
CUDA Deep Dive
 
Npc14
Npc14Npc14
Npc14
 
SF Big Analytics 20191112: How to performance-tune Spark applications in larg...
SF Big Analytics 20191112: How to performance-tune Spark applications in larg...SF Big Analytics 20191112: How to performance-tune Spark applications in larg...
SF Big Analytics 20191112: How to performance-tune Spark applications in larg...
 
High Availability PostgreSQL with Zalando Patroni
High Availability PostgreSQL with Zalando PatroniHigh Availability PostgreSQL with Zalando Patroni
High Availability PostgreSQL with Zalando Patroni
 
HSA Kernel Code (KFD v0.6)
HSA Kernel Code (KFD v0.6)HSA Kernel Code (KFD v0.6)
HSA Kernel Code (KFD v0.6)
 
Need help implementing the skeleton code below, I have provided the .pdf
Need help implementing the skeleton code below, I have provided the .pdfNeed help implementing the skeleton code below, I have provided the .pdf
Need help implementing the skeleton code below, I have provided the .pdf
 
Sysprog 14
Sysprog 14Sysprog 14
Sysprog 14
 
[232]TensorRT를 활용한 딥러닝 Inference 최적화
[232]TensorRT를 활용한 딥러닝 Inference 최적화[232]TensorRT를 활용한 딥러닝 Inference 최적화
[232]TensorRT를 활용한 딥러닝 Inference 최적화
 
[232] TensorRT를 활용한 딥러닝 Inference 최적화
[232] TensorRT를 활용한 딥러닝 Inference 최적화[232] TensorRT를 활용한 딥러닝 Inference 최적화
[232] TensorRT를 활용한 딥러닝 Inference 최적화
 
Qt Rest Server
Qt Rest ServerQt Rest Server
Qt Rest Server
 
Василий Сорокин, Простой REST сервер на Qt с рефлексией
Василий Сорокин, Простой REST сервер на Qt с рефлексиейВасилий Сорокин, Простой REST сервер на Qt с рефлексией
Василий Сорокин, Простой REST сервер на Qt с рефлексией
 

More from NEEVEE Technologies

C Language Programming - Program Outline / Schedule
C Language Programming - Program Outline / ScheduleC Language Programming - Program Outline / Schedule
C Language Programming - Program Outline / Schedule
NEEVEE Technologies
 
Python programming for Beginners - II
Python programming for Beginners - IIPython programming for Beginners - II
Python programming for Beginners - II
NEEVEE Technologies
 
Python programming for Beginners - I
Python programming for Beginners - IPython programming for Beginners - I
Python programming for Beginners - I
NEEVEE Technologies
 
Engineering College - Internship proposal
Engineering College - Internship proposalEngineering College - Internship proposal
Engineering College - Internship proposal
NEEVEE Technologies
 
NVDK-ESP32 WiFi Station / Access Point
NVDK-ESP32 WiFi Station / Access PointNVDK-ESP32 WiFi Station / Access Point
NVDK-ESP32 WiFi Station / Access Point
NEEVEE Technologies
 
NVDK-ESP32 Quick Start Guide
NVDK-ESP32 Quick Start GuideNVDK-ESP32 Quick Start Guide
NVDK-ESP32 Quick Start Guide
NEEVEE Technologies
 
General Purpose Input Output - Brief Introduction
General Purpose Input Output - Brief IntroductionGeneral Purpose Input Output - Brief Introduction
General Purpose Input Output - Brief Introduction
NEEVEE Technologies
 
Yocto BSP Layer for UDOO NEO Board
Yocto BSP Layer for UDOO NEO BoardYocto BSP Layer for UDOO NEO Board
Yocto BSP Layer for UDOO NEO Board
NEEVEE Technologies
 
Building Embedded Linux UDOONEO
Building Embedded Linux UDOONEOBuilding Embedded Linux UDOONEO
Building Embedded Linux UDOONEO
NEEVEE Technologies
 
Open Computer Vision Based Image Processing
Open Computer Vision Based Image ProcessingOpen Computer Vision Based Image Processing
Open Computer Vision Based Image Processing
NEEVEE Technologies
 
Introduction to Machine learning
Introduction to Machine learningIntroduction to Machine learning
Introduction to Machine learning
NEEVEE Technologies
 
Introduction Linux Device Drivers
Introduction Linux Device DriversIntroduction Linux Device Drivers
Introduction Linux Device Drivers
NEEVEE Technologies
 
Introduction about Apache MYNEWT RTOS
Introduction about Apache MYNEWT RTOSIntroduction about Apache MYNEWT RTOS
Introduction about Apache MYNEWT RTOS
NEEVEE Technologies
 
Introduction to Bluetooth Low Energy
Introduction to Bluetooth Low EnergyIntroduction to Bluetooth Low Energy
Introduction to Bluetooth Low Energy
NEEVEE Technologies
 
NXP i.MX6 Multi Media Processor & Peripherals
NXP i.MX6 Multi Media Processor & PeripheralsNXP i.MX6 Multi Media Processor & Peripherals
NXP i.MX6 Multi Media Processor & Peripherals
NEEVEE Technologies
 
Introduction to Bluetooth low energy
Introduction to Bluetooth low energyIntroduction to Bluetooth low energy
Introduction to Bluetooth low energy
NEEVEE Technologies
 
Arduino Programming - Brief Introduction
Arduino Programming - Brief IntroductionArduino Programming - Brief Introduction
Arduino Programming - Brief Introduction
NEEVEE Technologies
 
MarsBoard - NXP IMX6 Processor
MarsBoard - NXP IMX6 ProcessorMarsBoard - NXP IMX6 Processor
MarsBoard - NXP IMX6 Processor
NEEVEE Technologies
 
NXP IMX6 Processor - Embedded Linux
NXP IMX6 Processor - Embedded LinuxNXP IMX6 Processor - Embedded Linux
NXP IMX6 Processor - Embedded Linux
NEEVEE Technologies
 
Introduction to Hardware Design Using KiCAD
Introduction to Hardware Design Using KiCADIntroduction to Hardware Design Using KiCAD
Introduction to Hardware Design Using KiCAD
NEEVEE Technologies
 

More from NEEVEE Technologies (20)

C Language Programming - Program Outline / Schedule
C Language Programming - Program Outline / ScheduleC Language Programming - Program Outline / Schedule
C Language Programming - Program Outline / Schedule
 
Python programming for Beginners - II
Python programming for Beginners - IIPython programming for Beginners - II
Python programming for Beginners - II
 
Python programming for Beginners - I
Python programming for Beginners - IPython programming for Beginners - I
Python programming for Beginners - I
 
Engineering College - Internship proposal
Engineering College - Internship proposalEngineering College - Internship proposal
Engineering College - Internship proposal
 
NVDK-ESP32 WiFi Station / Access Point
NVDK-ESP32 WiFi Station / Access PointNVDK-ESP32 WiFi Station / Access Point
NVDK-ESP32 WiFi Station / Access Point
 
NVDK-ESP32 Quick Start Guide
NVDK-ESP32 Quick Start GuideNVDK-ESP32 Quick Start Guide
NVDK-ESP32 Quick Start Guide
 
General Purpose Input Output - Brief Introduction
General Purpose Input Output - Brief IntroductionGeneral Purpose Input Output - Brief Introduction
General Purpose Input Output - Brief Introduction
 
Yocto BSP Layer for UDOO NEO Board
Yocto BSP Layer for UDOO NEO BoardYocto BSP Layer for UDOO NEO Board
Yocto BSP Layer for UDOO NEO Board
 
Building Embedded Linux UDOONEO
Building Embedded Linux UDOONEOBuilding Embedded Linux UDOONEO
Building Embedded Linux UDOONEO
 
Open Computer Vision Based Image Processing
Open Computer Vision Based Image ProcessingOpen Computer Vision Based Image Processing
Open Computer Vision Based Image Processing
 
Introduction to Machine learning
Introduction to Machine learningIntroduction to Machine learning
Introduction to Machine learning
 
Introduction Linux Device Drivers
Introduction Linux Device DriversIntroduction Linux Device Drivers
Introduction Linux Device Drivers
 
Introduction about Apache MYNEWT RTOS
Introduction about Apache MYNEWT RTOSIntroduction about Apache MYNEWT RTOS
Introduction about Apache MYNEWT RTOS
 
Introduction to Bluetooth Low Energy
Introduction to Bluetooth Low EnergyIntroduction to Bluetooth Low Energy
Introduction to Bluetooth Low Energy
 
NXP i.MX6 Multi Media Processor & Peripherals
NXP i.MX6 Multi Media Processor & PeripheralsNXP i.MX6 Multi Media Processor & Peripherals
NXP i.MX6 Multi Media Processor & Peripherals
 
Introduction to Bluetooth low energy
Introduction to Bluetooth low energyIntroduction to Bluetooth low energy
Introduction to Bluetooth low energy
 
Arduino Programming - Brief Introduction
Arduino Programming - Brief IntroductionArduino Programming - Brief Introduction
Arduino Programming - Brief Introduction
 
MarsBoard - NXP IMX6 Processor
MarsBoard - NXP IMX6 ProcessorMarsBoard - NXP IMX6 Processor
MarsBoard - NXP IMX6 Processor
 
NXP IMX6 Processor - Embedded Linux
NXP IMX6 Processor - Embedded LinuxNXP IMX6 Processor - Embedded Linux
NXP IMX6 Processor - Embedded Linux
 
Introduction to Hardware Design Using KiCAD
Introduction to Hardware Design Using KiCADIntroduction to Hardware Design Using KiCAD
Introduction to Hardware Design Using KiCAD
 

Recently uploaded

Building Electrical System Design & Installation
Building Electrical System Design & InstallationBuilding Electrical System Design & Installation
Building Electrical System Design & Installation
symbo111
 
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...
Amil Baba Dawood bangali
 
一比一原版(UofT毕业证)多伦多大学毕业证成绩单如何办理
一比一原版(UofT毕业证)多伦多大学毕业证成绩单如何办理一比一原版(UofT毕业证)多伦多大学毕业证成绩单如何办理
一比一原版(UofT毕业证)多伦多大学毕业证成绩单如何办理
ydteq
 
NUMERICAL SIMULATIONS OF HEAT AND MASS TRANSFER IN CONDENSING HEAT EXCHANGERS...
NUMERICAL SIMULATIONS OF HEAT AND MASS TRANSFER IN CONDENSING HEAT EXCHANGERS...NUMERICAL SIMULATIONS OF HEAT AND MASS TRANSFER IN CONDENSING HEAT EXCHANGERS...
NUMERICAL SIMULATIONS OF HEAT AND MASS TRANSFER IN CONDENSING HEAT EXCHANGERS...
ssuser7dcef0
 
Hierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power SystemHierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power System
Kerry Sado
 
weather web application report.pdf
weather web application report.pdfweather web application report.pdf
weather web application report.pdf
Pratik Pawar
 
road safety engineering r s e unit 3.pdf
road safety engineering  r s e unit 3.pdfroad safety engineering  r s e unit 3.pdf
road safety engineering r s e unit 3.pdf
VENKATESHvenky89705
 
Hybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdf
Hybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdfHybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdf
Hybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdf
fxintegritypublishin
 
Water billing management system project report.pdf
Water billing management system project report.pdfWater billing management system project report.pdf
Water billing management system project report.pdf
Kamal Acharya
 
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
thanhdowork
 
Final project report on grocery store management system..pdf
Final project report on grocery store management system..pdfFinal project report on grocery store management system..pdf
Final project report on grocery store management system..pdf
Kamal Acharya
 
Cosmetic shop management system project report.pdf
Cosmetic shop management system project report.pdfCosmetic shop management system project report.pdf
Cosmetic shop management system project report.pdf
Kamal Acharya
 
Unbalanced Three Phase Systems and circuits.pptx
Unbalanced Three Phase Systems and circuits.pptxUnbalanced Three Phase Systems and circuits.pptx
Unbalanced Three Phase Systems and circuits.pptx
ChristineTorrepenida1
 
Steel & Timber Design according to British Standard
Steel & Timber Design according to British StandardSteel & Timber Design according to British Standard
Steel & Timber Design according to British Standard
AkolbilaEmmanuel1
 
Fundamentals of Induction Motor Drives.pptx
Fundamentals of Induction Motor Drives.pptxFundamentals of Induction Motor Drives.pptx
Fundamentals of Induction Motor Drives.pptx
manasideore6
 
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
MdTanvirMahtab2
 
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdfTop 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Teleport Manpower Consultant
 
Harnessing WebAssembly for Real-time Stateless Streaming Pipelines
Harnessing WebAssembly for Real-time Stateless Streaming PipelinesHarnessing WebAssembly for Real-time Stateless Streaming Pipelines
Harnessing WebAssembly for Real-time Stateless Streaming Pipelines
Christina Lin
 
Recycled Concrete Aggregate in Construction Part III
Recycled Concrete Aggregate in Construction Part IIIRecycled Concrete Aggregate in Construction Part III
Recycled Concrete Aggregate in Construction Part III
Aditya Rajan Patra
 
Nuclear Power Economics and Structuring 2024
Nuclear Power Economics and Structuring 2024Nuclear Power Economics and Structuring 2024
Nuclear Power Economics and Structuring 2024
Massimo Talia
 

Recently uploaded (20)

Building Electrical System Design & Installation
Building Electrical System Design & InstallationBuilding Electrical System Design & Installation
Building Electrical System Design & Installation
 
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...
 
一比一原版(UofT毕业证)多伦多大学毕业证成绩单如何办理
一比一原版(UofT毕业证)多伦多大学毕业证成绩单如何办理一比一原版(UofT毕业证)多伦多大学毕业证成绩单如何办理
一比一原版(UofT毕业证)多伦多大学毕业证成绩单如何办理
 
NUMERICAL SIMULATIONS OF HEAT AND MASS TRANSFER IN CONDENSING HEAT EXCHANGERS...
NUMERICAL SIMULATIONS OF HEAT AND MASS TRANSFER IN CONDENSING HEAT EXCHANGERS...NUMERICAL SIMULATIONS OF HEAT AND MASS TRANSFER IN CONDENSING HEAT EXCHANGERS...
NUMERICAL SIMULATIONS OF HEAT AND MASS TRANSFER IN CONDENSING HEAT EXCHANGERS...
 
Hierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power SystemHierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power System
 
weather web application report.pdf
weather web application report.pdfweather web application report.pdf
weather web application report.pdf
 
road safety engineering r s e unit 3.pdf
road safety engineering  r s e unit 3.pdfroad safety engineering  r s e unit 3.pdf
road safety engineering r s e unit 3.pdf
 
Hybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdf
Hybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdfHybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdf
Hybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdf
 
Water billing management system project report.pdf
Water billing management system project report.pdfWater billing management system project report.pdf
Water billing management system project report.pdf
 
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
 
Final project report on grocery store management system..pdf
Final project report on grocery store management system..pdfFinal project report on grocery store management system..pdf
Final project report on grocery store management system..pdf
 
Cosmetic shop management system project report.pdf
Cosmetic shop management system project report.pdfCosmetic shop management system project report.pdf
Cosmetic shop management system project report.pdf
 
Unbalanced Three Phase Systems and circuits.pptx
Unbalanced Three Phase Systems and circuits.pptxUnbalanced Three Phase Systems and circuits.pptx
Unbalanced Three Phase Systems and circuits.pptx
 
Steel & Timber Design according to British Standard
Steel & Timber Design according to British StandardSteel & Timber Design according to British Standard
Steel & Timber Design according to British Standard
 
Fundamentals of Induction Motor Drives.pptx
Fundamentals of Induction Motor Drives.pptxFundamentals of Induction Motor Drives.pptx
Fundamentals of Induction Motor Drives.pptx
 
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
 
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdfTop 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
 
Harnessing WebAssembly for Real-time Stateless Streaming Pipelines
Harnessing WebAssembly for Real-time Stateless Streaming PipelinesHarnessing WebAssembly for Real-time Stateless Streaming Pipelines
Harnessing WebAssembly for Real-time Stateless Streaming Pipelines
 
Recycled Concrete Aggregate in Construction Part III
Recycled Concrete Aggregate in Construction Part IIIRecycled Concrete Aggregate in Construction Part III
Recycled Concrete Aggregate in Construction Part III
 
Nuclear Power Economics and Structuring 2024
Nuclear Power Economics and Structuring 2024Nuclear Power Economics and Structuring 2024
Nuclear Power Economics and Structuring 2024
 

UDPSRC GStreamer Plugin Session VIII

  • 2. UDPSRC - Overview • Source element – Receives the packet from UDP port & provide it over gstreamer pipeline – Contains Single PAD ( source PAD )
  • 3. Properties • PROP_PORT • PROP_MULTICAST_GROUP • PROP_MULTICAST_IFACE • PROP_URI • PROP_CAPS • PROP_SOCKFD • PROP_BUFFER_SIZE • PROP_TIMEOUT • PROP_SKIP_FIRST_BYTES • PROP_CLOSEFD • PROP_SOCK • PROP_AUTO_MULTICAST • PROP_REUSE
  • 4. gst_udpsrc_base_init • Does the base initialization of udpsrc source element • Adds / registers the static source PAD
  • 5. gst_udpsrc_base_init static void gst_udpsrc_base_init (gpointer g_class) { GstElementClass *element_class = GST_ELEMENT_CLASS (g_class); gst_element_class_add_static_pad_template (element_class, &src_template); gst_element_class_set_details_simple (element_class, "UDP packet receiver", "Source/Network", "Receive data over the network via UDP", "Wim Taymans <wim@fluendo.com>, " "Thijs Vermeir <thijs.vermeir@barco.com>"); }
  • 6. gst_udpsrc_class_init • Call back function initialization to – Get property - gst_udpsrc_get_property – Set property - gst_udpsrc_set_property – Finalize - gst_udpsrc_finalize – Start - gst_udpsrc_start – Stop - gst_udpsrc_stop – Unlock - gst_udpsrc_unlock – Unlock_stop - gst_udpsrc_unlock_stop – Getcaps - gst_udpsrc_getcaps – Create - gst_udpsrc_create
  • 7. gst_udpsrc_class_init • Initialization / registeration of element properties – Port – Port Number ( int ) – Multicast-group : Name of group ( String ) – Multicast-iface : Name of Interface ( String ) – Uri : string – Sockfd – Socket handler ( int ) – Buffer-size – Buffer-Size (int ) – Timeout – (int) – Skip First bytes – Number of byte to skip ( int ) – closeFd – Close sockfd if passed as property of state change ( int ) – Sock – Socket Handle ( int ) – Auto-multicast – Automatically joins / leaves multicast groups ( int ) – Reuse : Enables reuse of the port ( boolean )
  • 8. Property registration • Property registration is done by – g_object_class_install_property • Parameter specified by either – g_param_spec_int – g_param_spec_string – g_param_spec_boolean – g_param_spec_uint64
  • 9. gst_udpsrc_init • Initializes uri string • Initializes all the property variables
  • 10. gst_udpsrc_finalize • This does the cleanup & frees the memory • unref the capabilities • frees memory of multicast_iface • frees memory of uri & uristr • Closes the socket, if closeFd option enabled • Cleanup the object • Finalize gstreamer base object
  • 11. gst_udpsrc_getcaps static GstCaps * gst_udpsrc_getcaps (GstBaseSrc * src) { GstUDPSrc *udpsrc; udpsrc = GST_UDPSRC (src); if (udpsrc->caps) return gst_caps_ref (udpsrc->caps); else return gst_caps_new_any (); }
  • 12. clear_error • Reads a message from error queue • Flushes ERROR from fd so next poll will not return at once • Local address handling without address
  • 13. gst_udpsrc_start • Gets URI information • Creates a socket • Enables port reuse option using setsockopt, if reuse is enabled • Set socket name if it is multicast • Configure the kernel receiver buffer size, if buffer- size parameter is given • Add the socket into poll fd • Add the socket into control fd read
  • 14. gst_udpsrc_stop static gboolean gst_udpsrc_stop (GstBaseSrc * bsrc) { GstUDPSrc *src; src = GST_UDPSRC (bsrc); GST_DEBUG ("stopping, closing sockets"); if (src->sock.fd >= 0) { if (src->auto_multicast && gst_udp_is_multicast (&src->myaddr)) { GST_DEBUG_OBJECT (src, "leaving multicast group %s", src->uri.host); gst_udp_leave_group (src->sock.fd, &src->myaddr); } CLOSE_IF_REQUESTED (src); } if (src->fdset) { gst_poll_free (src->fdset); src->fdset = NULL; } return TRUE; }
  • 15. gst_udpsrc_create • Wait for the socket data using gst_poll_wait • Recv the packet from socket using recvfrom • Allocate memory for sending data to stream • Skip first bytes if the option is enabled • Buffer cast the data to flow into pipeline.
  • 16. Get Type & Protocols static GstURIType gst_udpsrc_uri_get_type (void) { return GST_URI_SRC; } static gchar ** gst_udpsrc_uri_get_protocols (void) { static gchar *protocols[] = { (char *) "udp", NULL }; return protocols; }
  • 17. Get & Set URI static const gchar * gst_udpsrc_uri_get_uri (GstURIHandler * handler) { GstUDPSrc *src = GST_UDPSRC (handler); g_free (src->uristr); src->uristr = gst_udp_uri_string (&src->uri); return src->uristr; } static gboolean gst_udpsrc_uri_set_uri (GstURIHandler * handler, const gchar * uri) { gboolean ret; GstUDPSrc *src = GST_UDPSRC (handler); ret = gst_udpsrc_set_uri (src, uri); return ret; }
  • 18. gst_udpsrc_uri_handler_init static void gst_udpsrc_uri_handler_init (gpointer g_iface, gpointer iface_data) { GstURIHandlerInterface *iface = (GstURIHandlerInterface *) g_iface; iface->get_type = gst_udpsrc_uri_get_type; iface->get_protocols = gst_udpsrc_uri_get_protocols; iface->get_uri = gst_udpsrc_uri_get_uri; iface->set_uri = gst_udpsrc_uri_set_uri; }