[vlc-commits] sout: deinline sout_stream_t calls

Rémi Denis-Courmont git at videolan.org
Mon Oct 12 17:03:05 CEST 2020


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sun Oct 11 17:12:58 2020 +0300| [319efddd438b934fe8a0198a6964a7ce41069a6f] | committer: Rémi Denis-Courmont

sout: deinline sout_stream_t calls

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=319efddd438b934fe8a0198a6964a7ce41069a6f
---

 include/vlc_sout.h                | 36 +++++-------------------------------
 src/libvlccore.sym                |  5 +++++
 src/stream_output/stream_output.c | 28 ++++++++++++++++++++++++++++
 3 files changed, 38 insertions(+), 31 deletions(-)

diff --git a/include/vlc_sout.h b/include/vlc_sout.h
index c76c8a6344..23a7b90d36 100644
--- a/include/vlc_sout.h
+++ b/include/vlc_sout.h
@@ -196,37 +196,11 @@ VLC_API void sout_StreamChainDelete(sout_stream_t *first, sout_stream_t *end);
 VLC_API sout_stream_t *sout_StreamChainNew(vlc_object_t *parent,
         const char *psz_chain, sout_stream_t *p_next) VLC_USED;
 
-static inline void *sout_StreamIdAdd( sout_stream_t *s,
-                                      const es_format_t *fmt )
-{
-    return s->ops->add(s, fmt);
-}
-
-static inline void sout_StreamIdDel( sout_stream_t *s,
-                                     void *id )
-{
-    s->ops->del(s, id);
-}
-
-static inline int sout_StreamIdSend( sout_stream_t *s,
-                                     void *id, block_t *b )
-{
-    return s->ops->send(s, id, b);
-}
-
-static inline void sout_StreamFlush( sout_stream_t *s,
-                                     void *id )
-{
-    if (s->ops->flush != NULL)
-        s->ops->flush(s, id);
-}
-
-static inline int sout_StreamControlVa( sout_stream_t *s, int i_query, va_list args )
-{
-    if (s->ops->control == NULL)
-        return VLC_EGENERIC;
-    return s->ops->control(s, i_query, args);
-}
+VLC_API void *sout_StreamIdAdd(sout_stream_t *s, const es_format_t *fmt);
+VLC_API void sout_StreamIdDel(sout_stream_t *s, void *id);
+VLC_API int sout_StreamIdSend( sout_stream_t *s, void *id, block_t *b);
+VLC_API void sout_StreamFlush(sout_stream_t *s, void *id);
+VLC_API int sout_StreamControlVa(sout_stream_t *s, int i_query, va_list args);
 
 static inline int sout_StreamControl( sout_stream_t *s, int i_query, ... )
 {
diff --git a/src/libvlccore.sym b/src/libvlccore.sym
index bd00a9b74a..cd47af0a2e 100644
--- a/src/libvlccore.sym
+++ b/src/libvlccore.sym
@@ -346,6 +346,11 @@ sout_MuxSendBuffer
 sout_MuxFlush
 sout_StreamChainDelete
 sout_StreamChainNew
+sout_StreamIdAdd
+sout_StreamIdDel
+sout_StreamIdSend
+sout_StreamFlush
+sout_StreamControlVa
 spu_Create
 spu_Destroy
 spu_PutSubpicture
diff --git a/src/stream_output/stream_output.c b/src/stream_output/stream_output.c
index 1e0d554202..e0769dc749 100644
--- a/src/stream_output/stream_output.c
+++ b/src/stream_output/stream_output.c
@@ -742,6 +742,34 @@ struct sout_stream_private {
 #define sout_stream_priv(s) \
         container_of(s, struct sout_stream_private, stream)
 
+void *sout_StreamIdAdd(sout_stream_t *s, const es_format_t *fmt)
+{
+    return s->ops->add(s, fmt);
+}
+
+void sout_StreamIdDel(sout_stream_t *s, void *id)
+{
+    s->ops->del(s, id);
+}
+
+int sout_StreamIdSend(sout_stream_t *s, void *id, block_t *b)
+{
+    return s->ops->send(s, id, b);
+}
+
+void sout_StreamFlush(sout_stream_t *s, void *id)
+{
+    if (s->ops->flush != NULL)
+        s->ops->flush(s, id);
+}
+
+int sout_StreamControlVa(sout_stream_t *s, int i_query, va_list args)
+{
+    if (s->ops->control == NULL)
+        return VLC_EGENERIC;
+    return s->ops->control(s, i_query, args);
+}
+
 /* Destroy a "stream_out" module */
 static void sout_StreamDelete( sout_stream_t *p_stream )
 {



More information about the vlc-commits mailing list