From 6f4969f4170866483d1a6d2c30bd269223306127 Mon Sep 17 00:00:00 2001 From: f4exb Date: Wed, 28 Nov 2018 10:57:03 +0100 Subject: [PATCH] Windows MSVC2017: include DATV Demod --- plugins/channelrx/demoddatv/demoddatv.pro | 18 ++++++++++-------- plugins/channelrx/demoddatv/leansdr/dvb.h | 14 +++++++------- plugins/channelrx/demoddatv/leansdr/math.h | 1 + sdrangel.windows.pro | 1 + windowsms.install.bat | 5 +++++ 5 files changed, 24 insertions(+), 15 deletions(-) diff --git a/plugins/channelrx/demoddatv/demoddatv.pro b/plugins/channelrx/demoddatv/demoddatv.pro index c02e89ad5..46c0404d9 100644 --- a/plugins/channelrx/demoddatv/demoddatv.pro +++ b/plugins/channelrx/demoddatv/demoddatv.pro @@ -7,7 +7,7 @@ TEMPLATE = lib CONFIG += plugin -QT += core gui multimedia multimediawidgets widgets opengl +QT += core gui multimedia multimediawidgets widgets opengl qml TARGET = demoddatv @@ -18,25 +18,26 @@ QMAKE_CXXFLAGS += -msse4.1 QMAKE_CXXFLAGS += -std=c++11 INCLUDEPATH += $$PWD +INCLUDEPATH += ../../../exports INCLUDEPATH += ../../../sdrbase INCLUDEPATH += ../../../sdrgui CONFIG(Release):build_subdir = release CONFIG(Debug):build_subdir = debug -CONFIG(MINGW32):INCLUDEPATH += "D:\boost_1_58_0" -CONFIG(MINGW64):INCLUDEPATH += "D:\boost_1_58_0" +CONFIG(MSVC):INCLUDEPATH += "C:\softs\boost_1_66_0" +CONFIG(MSVC):INCLUDEPATH += "C:\softs\ffmpeg-20181127-1035206-win64-dev\include" CONFIG(macx):INCLUDEPATH += "../../../../../boost_1_64_0" SOURCES += datvdemod.cpp\ - datvdemodgui.cpp\ - datvdemodplugin.cpp\ + datvdemodgui.cpp\ + datvdemodplugin.cpp\ datvideostream.cpp \ datvideorender.cpp HEADERS += datvdemod.h\ - datvdemodgui.h\ - datvdemodplugin.h\ + datvdemodgui.h\ + datvdemodplugin.h\ leansdr/convolutional.h \ leansdr/dsp.h \ leansdr/dvb.h \ @@ -58,6 +59,7 @@ FORMS += datvdemodgui.ui LIBS += -L../../../sdrbase/$${build_subdir} -lsdrbase LIBS += -L../../../sdrgui/$${build_subdir} -lsdrgui -LIBS += -lavutil -lswscale -lavdevice -lavformat -lavcodec -lswresample +#LIBS += -lavutil -lswscale -lavdevice -lavformat -lavcodec -lswresample +LIBS += -L"C:\softs\ffmpeg-20181127-1035206-win64-dev\lib" -lavutil -lswscale -lavdevice -lavformat -lavcodec -lswresample RESOURCES = ../../../sdrbase/resources/res.qrc diff --git a/plugins/channelrx/demoddatv/leansdr/dvb.h b/plugins/channelrx/demoddatv/leansdr/dvb.h index 474eab072..8cde82b79 100644 --- a/plugins/channelrx/demoddatv/leansdr/dvb.h +++ b/plugins/channelrx/demoddatv/leansdr/dvb.h @@ -671,13 +671,13 @@ static struct fec_spec } fec_specs[FEC_MAX] = { - [FEC12] = { 1, 2, polys_fec12 }, - [FEC23] = { 2, 3, polys_fec23 }, - [FEC46] = { 4, 6, polys_fec46 }, - [FEC34] = { 3, 4, polys_fec34 }, - [FEC56] = { 5, 6, polys_fec56 }, - [FEC78] = { 7, 8, polys_fec78 }, - [FEC45] = { 4, 5, polys_fec45 }, // Non-standard + { 1, 2, polys_fec12 }, + { 2, 3, polys_fec23 }, + { 4, 6, polys_fec46 }, + { 3, 4, polys_fec34 }, + { 5, 6, polys_fec56 }, + { 7, 8, polys_fec78 }, + { 4, 5, polys_fec45 }, // Non-standard }; struct dvb_convol: runnable diff --git a/plugins/channelrx/demoddatv/leansdr/math.h b/plugins/channelrx/demoddatv/leansdr/math.h index 26a94b250..ada707f17 100644 --- a/plugins/channelrx/demoddatv/leansdr/math.h +++ b/plugins/channelrx/demoddatv/leansdr/math.h @@ -1,6 +1,7 @@ #ifndef LEANSDR_MATH_H #define LEANSDR_MATH_H +#define _USE_MATH_DEFINES #include #include diff --git a/sdrangel.windows.pro b/sdrangel.windows.pro index 3b6221a55..0cec85c84 100644 --- a/sdrangel.windows.pro +++ b/sdrangel.windows.pro @@ -53,6 +53,7 @@ SUBDIRS += plugins/channelrx/chanalyzer SUBDIRS += plugins/channelrx/demodam SUBDIRS += plugins/channelrx/demodatv SUBDIRS += plugins/channelrx/demodbfm +CONFIG(!MSVC):SUBDIRS += plugins/channelrx/demoddatv CONFIG(!MSVC):SUBDIRS += plugins/channelrx/demoddsd CONFIG(!MSVC):SUBDIRS += plugins/channelrx/demodlora SUBDIRS += plugins/channelrx/demodnfm diff --git a/windowsms.install.bat b/windowsms.install.bat index ee5c32671..e7022b617 100644 --- a/windowsms.install.bat +++ b/windowsms.install.bat @@ -5,6 +5,8 @@ SET libiconvdir="C:\softs\iconv-1.9.2.win32" SET libzlib1dir="C:\softs\zlib-1.2.5" SET pothosdir="C:\Program Files\PothosSDR" SET pthreadsdir="C:\softs\pthreads-w32" +SET ffmpegdir="C:\softs\ffmpeg-20181127-1035206-win64-shared\bin" +SET qt5dir="C:\Qt\5.11.1\msvc2017_64\bin" copy app\%1\sdrangel.exe %2 copy sdrbase\%1\sdrbase.dll %2 @@ -39,6 +41,8 @@ REM copy %opencvdir%\opencv_ffmpeg2413.dll %2 REM copy %opencvdir%\libopencv_imgproc2413.dll %2 REM copy %opencvdir%\libopencv_highgui2413.dll %2 REM copy %opencvdir%\libopencv_core2413.dll %2 +copy %ffmpegdir%\*.dll %2 +copy %qt5dir%\Qt5Qml.dll %2 mkdir %2\plugins mkdir %2\plugins\channelrx @@ -50,6 +54,7 @@ copy plugins\channelrx\chanalyzer\%1\chanalyzer.dll %2\plugins\channelrx copy plugins\channelrx\demodam\%1\demodam.dll %2\plugins\channelrx copy plugins\channelrx\demodatv\%1\demodatv.dll %2\plugins\channelrx copy plugins\channelrx\demodbfm\%1\demodbfm.dll %2\plugins\channelrx +copy plugins\channelrx\demoddatv\%1\demoddatv.dll %2\plugins\channelrx REM copy plugins\channelrx\demoddsd\%1\demoddsd.dll %2\plugins\channelrx REM copy plugins\channelrx\demodlora\%1\demodlora.dll %2\plugins\channelrx copy plugins\channelrx\demodnfm\%1\demodnfm.dll %2\plugins\channelrx