Jacek Caban : winegstreamer: Use nameless unions.

Alexandre Julliard julliard at winehq.org
Wed Mar 24 16:20:42 CDT 2021


Module: wine
Branch: master
Commit: ab044d1b9f19b3abc4adc941e6fee8174728ce02
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=ab044d1b9f19b3abc4adc941e6fee8174728ce02

Author: Jacek Caban <jacek at codeweavers.com>
Date:   Wed Mar 24 19:34:13 2021 +0100

winegstreamer: Use nameless unions.

Signed-off-by: Jacek Caban <jacek at codeweavers.com>
Signed-off-by: Zebediah Figura <z.figura12 at gmail.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/winegstreamer/Makefile.in     | 1 -
 dlls/winegstreamer/main.c          | 2 ++
 dlls/winegstreamer/media_source.c  | 6 +++---
 dlls/winegstreamer/quartz_parser.c | 8 ++++----
 4 files changed, 9 insertions(+), 8 deletions(-)

diff --git a/dlls/winegstreamer/Makefile.in b/dlls/winegstreamer/Makefile.in
index bd95a38316f..4d5dece64b3 100644
--- a/dlls/winegstreamer/Makefile.in
+++ b/dlls/winegstreamer/Makefile.in
@@ -3,7 +3,6 @@ IMPORTS   = strmbase strmiids uuid ole32 mfuuid
 DELAYIMPORTS = mfplat
 EXTRAINCL = $(GSTREAMER_CFLAGS)
 EXTRALIBS = $(GSTREAMER_LIBS) $(PTHREAD_LIBS)
-EXTRADEFS = -DWINE_NO_NAMELESS_EXTENSION
 
 EXTRADLLFLAGS = -mno-cygwin
 
diff --git a/dlls/winegstreamer/main.c b/dlls/winegstreamer/main.c
index d5c06bf3279..4772c958f8e 100644
--- a/dlls/winegstreamer/main.c
+++ b/dlls/winegstreamer/main.c
@@ -18,6 +18,8 @@
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
  */
 
+#define WINE_NO_NAMELESS_EXTENSION
+
 #include "gst_private.h"
 #include "winternl.h"
 #include "rpcproxy.h"
diff --git a/dlls/winegstreamer/media_source.c b/dlls/winegstreamer/media_source.c
index 3260175f45a..589e894db2e 100644
--- a/dlls/winegstreamer/media_source.c
+++ b/dlls/winegstreamer/media_source.c
@@ -249,9 +249,9 @@ static void start_pipeline(struct media_source *source, struct source_async_comm
     if (source->state == SOURCE_STOPPED && position->vt == VT_EMPTY)
     {
         position->vt = VT_I8;
-        position->u.hVal.QuadPart = 0;
+        position->hVal.QuadPart = 0;
     }
-    source->start_time = position->u.hVal.QuadPart;
+    source->start_time = position->hVal.QuadPart;
 
     for (i = 0; i < source->stream_count; i++)
     {
@@ -310,7 +310,7 @@ static void start_pipeline(struct media_source *source, struct source_async_comm
     source->state = SOURCE_RUNNING;
 
     unix_funcs->wg_parser_stream_seek(source->streams[0]->wg_stream, 1.0,
-            position->u.hVal.QuadPart, 0, AM_SEEKING_AbsolutePositioning, AM_SEEKING_NoPositioning);
+            position->hVal.QuadPart, 0, AM_SEEKING_AbsolutePositioning, AM_SEEKING_NoPositioning);
     unix_funcs->wg_parser_end_flush(source->wg_parser);
 }
 
diff --git a/dlls/winegstreamer/quartz_parser.c b/dlls/winegstreamer/quartz_parser.c
index e9e7c3a0f9f..243dc9f80ba 100644
--- a/dlls/winegstreamer/quartz_parser.c
+++ b/dlls/winegstreamer/quartz_parser.c
@@ -336,10 +336,10 @@ static bool amt_from_wg_format_video(AM_MEDIA_TYPE *mt, const struct wg_format *
 
     if (format->u.video.format == WG_VIDEO_FORMAT_RGB16)
     {
-        mt->cbFormat = offsetof(VIDEOINFO, u.dwBitMasks[3]);
-        video_format->u.dwBitMasks[iRED]   = 0xf800;
-        video_format->u.dwBitMasks[iGREEN] = 0x07e0;
-        video_format->u.dwBitMasks[iBLUE]  = 0x001f;
+        mt->cbFormat = offsetof(VIDEOINFO, dwBitMasks[3]);
+        video_format->dwBitMasks[iRED]   = 0xf800;
+        video_format->dwBitMasks[iGREEN] = 0x07e0;
+        video_format->dwBitMasks[iBLUE]  = 0x001f;
     }
 
     return true;




More information about the wine-cvs mailing list