Compare commits
21
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9e8dfc2e3d | ||
|
|
0280200a82 | ||
|
|
d29f8ea215 | ||
|
|
2d8476e875 | ||
|
|
864c3253f1 | ||
|
|
32f803ada9 | ||
|
|
63eb742f64 | ||
|
|
72ef7deda6 | ||
|
|
a2d452fd64 | ||
|
|
3732810f9e | ||
|
|
56fc2e45bb | ||
|
|
fa23256955 | ||
|
|
ffe0c38427 | ||
|
|
12bd1a4c2c | ||
|
|
b830b700ca | ||
|
|
3109250471 | ||
|
|
c6b43ac7fa | ||
|
|
beed955e3f | ||
|
|
1f003ec2ac | ||
|
|
c718d01700 | ||
|
|
847f4f06b9 |
No files matched your search
+8
-7
@@ -5,16 +5,16 @@ platform:
|
|||||||
environment:
|
environment:
|
||||||
access_token:
|
access_token:
|
||||||
secure: SMxOWNKN0RkPvICWhIet2FJM5g/zx5mguM/XAPjM2OrC3U2/LAqcBZw0veS9peS4
|
secure: SMxOWNKN0RkPvICWhIet2FJM5g/zx5mguM/XAPjM2OrC3U2/LAqcBZw0veS9peS4
|
||||||
|
|
||||||
clone_folder: C:\Projects\calyp
|
clone_folder: C:\Projects\calyp
|
||||||
|
|
||||||
init:
|
init:
|
||||||
- ps: Add-Content "$HOME\.git-credentials" "https://$($env:access_token):x-oauth-basic@github.com`n"
|
- ps: Add-Content "$HOME\.git-credentials" "https://$($env:access_token):x-oauth-basic@github.com`n"
|
||||||
- git config --global credential.helper store
|
- git config --global credential.helper store
|
||||||
- git config --global user.email "jfmcarreira@gmail.com"
|
- git config --global user.email "jfmcarreira@gmail.com"
|
||||||
- git config --global user.name "AppVeyor"
|
- git config --global user.name "AppVeyor"
|
||||||
- ps: iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
|
- ps: iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
|
||||||
|
|
||||||
install:
|
install:
|
||||||
- '"C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvarsall.bat" x64'
|
- '"C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvarsall.bat" x64'
|
||||||
- choco install nsis
|
- choco install nsis
|
||||||
@@ -25,13 +25,14 @@ install:
|
|||||||
- 7z x ffmpeg.7z -y -offmpeg
|
- 7z x ffmpeg.7z -y -offmpeg
|
||||||
- git clone https://github.com/pixlra/calyp-deployment.git
|
- git clone https://github.com/pixlra/calyp-deployment.git
|
||||||
- CALL calyp-deployment/scripts/extract_ffmpeg.bat
|
- CALL calyp-deployment/scripts/extract_ffmpeg.bat
|
||||||
|
- ps: rm C:\Projects\ffmpeg_libraries\bin\*.exe
|
||||||
|
|
||||||
|
|
||||||
build_script:
|
build_script:
|
||||||
- mv C:\Projects\calyp C:\Projects\calyp-deployment\cmake-helper\
|
- mv C:\Projects\calyp C:\Projects\calyp-deployment\cmake-helper\
|
||||||
- mkdir C:\Projects\calyp-build
|
- mkdir C:\Projects\calyp-build
|
||||||
- cd C:\Projects\calyp-build
|
- cd C:\Projects\calyp-build
|
||||||
- cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=install -DUSE_DYNLOAD=OFF -DOpenCV_DIR="C:/Tools/opencv/build" -DOpenCV_DLL_DIR="C:/Tools/opencv/build/x64/vc15/bin" -DOpenCV_INSTALL_MODULES="world" -DQT_DIR="C:\Qt\latest\msvc2017_64" -DQt5_DIR="C:\Qt\latest\msvc2017_64\lib\cmake\Qt5" -DUSE_QTDBUS=OFF -DAVFORMAT_LIBRARIES=C:/Projects/ffmpeg_libraries/lib/avformat.lib -DAVFORMAT_INCLUDE_DIRS=C:/Projects/ffmpeg_libraries/include -DAVCODEC_LIBRARIES=C:/Projects/ffmpeg_libraries/lib/avcodec.lib -DAVCODEC_INCLUDE_DIRS=C:/Projects/ffmpeg_libraries/include -DAVUTIL_LIBRARIES=C:/Projects/ffmpeg_libraries/lib/avutil.lib -DAVUTIL_INCLUDE_DIRS=C:/Projects/ffmpeg_libraries/include -DSWSCALE_LIBRARIES=C:/Projects/ffmpeg_libraries/lib/swscale.lib -DSWSCALE_INCLUDE_DIRS=C:/Projects/ffmpeg_libraries/include -G "Visual Studio 15 2017 Win64" C:\Projects\calyp-deployment\cmake-helper
|
- cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=install -DUSE_DYNLOAD=OFF -DOpenCV_DIR="C:/Tools/opencv/build" -DOpenCV_DLL_DIR="C:/Tools/opencv/build/x64/vc15/bin" -DOpenCV_INSTALL_MODULES="world" -DQT_DIR="C:\Qt\latest\msvc2017_64" -DQt5_DIR="C:\Qt\latest\msvc2017_64\lib\cmake\Qt5" -DUSE_QTDBUS=OFF -DAVFORMAT_LIBRARIES=C:/Projects/ffmpeg_libraries/lib/avformat.lib -DAVFORMAT_INCLUDE_DIRS=C:/Projects/ffmpeg_libraries/include -DAVCODEC_LIBRARIES=C:/Projects/ffmpeg_libraries/lib/avcodec.lib -DAVCODEC_INCLUDE_DIRS=C:/Projects/ffmpeg_libraries/include -DAVUTIL_LIBRARIES=C:/Projects/ffmpeg_libraries/lib/avutil.lib -DAVUTIL_INCLUDE_DIRS=C:/Projects/ffmpeg_libraries/include -DSWSCALE_LIBRARIES=C:/Projects/ffmpeg_libraries/lib/swscale.lib -DSWSCALE_INCLUDE_DIRS=C:/Projects/ffmpeg_libraries/include -DAVDEVICE_LIBRARIES=C:/Projects/ffmpeg_libraries/lib/avdevice.lib -DAVDEVICE_INCLUDE_DIRS=C:/Projects/ffmpeg_libraries/include -DPOSTPROC_LIBRARIES=C:/Projects/ffmpeg_libraries/lib/postproc.lib -DPOSTPROC_INCLUDE_DIRS=C:/Projects/ffmpeg_libraries/include -DFFMPEG_DIR=C:\Projects\ffmpeg_libraries -DSWRESAMPLE_LIBRARIES=C:/Projects/ffmpeg_libraries/lib/swresample.lib -DSWRESAMPLE_INCLUDE_DIRS=C:/Projects/ffmpeg_libraries/include -G "Visual Studio 15 2017 Win64" C:\Projects\calyp-deployment\cmake-helper
|
||||||
- cmake --build . --target ALL_BUILD -- /p:Configuration=Release > log_build
|
- cmake --build . --target ALL_BUILD -- /p:Configuration=Release > log_build
|
||||||
- cmake --build . --target INSTALL -- /p:Configuration=Release > log_install
|
- cmake --build . --target INSTALL -- /p:Configuration=Release > log_install
|
||||||
- cmake --build . --target PACKAGE -- /p:Configuration=Release > log_pkg
|
- cmake --build . --target PACKAGE -- /p:Configuration=Release > log_pkg
|
||||||
@@ -39,7 +40,7 @@ build_script:
|
|||||||
after_build:
|
after_build:
|
||||||
- IF "%APPVEYOR_REPO_BRANCH%" == "master" (CALL ..\calyp-deployment\scripts\deploy-to-github.bat)
|
- IF "%APPVEYOR_REPO_BRANCH%" == "master" (CALL ..\calyp-deployment\scripts\deploy-to-github.bat)
|
||||||
|
|
||||||
|
|
||||||
on_failure:
|
on_failure:
|
||||||
- ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
|
- ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
|
||||||
|
|
||||||
@@ -0,0 +1,31 @@
|
|||||||
|
name: Build and Test
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- devel
|
||||||
|
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Install Dependencies
|
||||||
|
run: sudo apt-get install cmake qtbase5-dev libavcodec-dev libavformat-dev libavutil-dev libopencv-dev libopencv-video-dev libopencv-contrib-dev
|
||||||
|
|
||||||
|
- name: Build CMake
|
||||||
|
uses: ashutoshvarma/action-cmake-build@v1
|
||||||
|
with:
|
||||||
|
build-dir: ${{ runner.workspace }}/build
|
||||||
|
# will set the CC & CXX for cmake
|
||||||
|
cc: gcc
|
||||||
|
cxx: g++
|
||||||
|
build-type: Release
|
||||||
|
# Extra options pass to cmake while configuring project
|
||||||
|
configure-options: -DBUILD_TESTS=ON -DUSE_WERROR=ON
|
||||||
|
run-test: true
|
||||||
|
#ctest-options: -R mytest
|
||||||
|
# install the build using cmake --install
|
||||||
|
install-build: true
|
||||||
|
# run build using '-j [parallel]' to use multiple threads to build
|
||||||
|
parallel: 14
|
||||||
+2
-1
@@ -76,6 +76,7 @@
|
|||||||
# CMake
|
# CMake
|
||||||
bin/
|
bin/
|
||||||
build/
|
build/
|
||||||
|
build-*
|
||||||
cmake-build-*/
|
cmake-build-*/
|
||||||
|
|
||||||
# Mongo Explorer plugin
|
# Mongo Explorer plugin
|
||||||
@@ -142,4 +143,4 @@ fabric.properties
|
|||||||
doc/
|
doc/
|
||||||
|
|
||||||
# CLang
|
# CLang
|
||||||
compile_commands.json
|
compile_commands.json
|
||||||
+1
-1
@@ -4,4 +4,4 @@ before_install:
|
|||||||
- sudo apt-get -qq update
|
- sudo apt-get -qq update
|
||||||
- sudo apt-get install build-essential cmake qtbase5-dev libavcodec-dev libavformat-dev libavutil-dev libopencv-dev libopencv-video-dev libopencv-contrib-dev libgtest-dev
|
- sudo apt-get install build-essential cmake qtbase5-dev libavcodec-dev libavformat-dev libavutil-dev libopencv-dev libopencv-video-dev libopencv-contrib-dev libgtest-dev
|
||||||
script:
|
script:
|
||||||
- mkdir -p build && cd build && cmake -DBUILD_TESTS=ON .. && make && cd ..
|
- mkdir -p build && cd build && cmake .. && make && cd ..
|
||||||
+28
-15
@@ -2,15 +2,7 @@
|
|||||||
# CMakeLists for calyp
|
# CMakeLists for calyp
|
||||||
#
|
#
|
||||||
|
|
||||||
CMAKE_MINIMUM_REQUIRED(VERSION 3.2.0)
|
CMAKE_MINIMUM_REQUIRED(VERSION 3.5.0)
|
||||||
|
|
||||||
# ####################################################################################################################################################
|
|
||||||
# CMake functions
|
|
||||||
# ####################################################################################################################################################
|
|
||||||
SET(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake)
|
|
||||||
INCLUDE(cmake/ModulesFct.cmake)
|
|
||||||
INCLUDE(FeatureSummary)
|
|
||||||
INCLUDE(GNUInstallDirs)
|
|
||||||
|
|
||||||
# ####################################################################################################################################################
|
# ####################################################################################################################################################
|
||||||
# Project Definition
|
# Project Definition
|
||||||
@@ -25,15 +17,28 @@ SET(PROJECT_LIBRARY
|
|||||||
CACHE INTERNAL "" FORCE
|
CACHE INTERNAL "" FORCE
|
||||||
)
|
)
|
||||||
|
|
||||||
PROJECT(${PROJECT_NAME})
|
|
||||||
SET(CALYP_VERSION_MAJOR "1")
|
SET(CALYP_VERSION_MAJOR "1")
|
||||||
SET(CALYP_VERSION_MINOR "1")
|
SET(CALYP_VERSION_MINOR "2")
|
||||||
SET(CALYP_VERSION_PATCH "0")
|
SET(CALYP_VERSION_PATCH "0")
|
||||||
SET(CALYP_VERSION
|
SET(CALYP_VERSION
|
||||||
"${CALYP_VERSION_MAJOR}.${CALYP_VERSION_MINOR}.${CALYP_VERSION_PATCH}"
|
"${CALYP_VERSION_MAJOR}.${CALYP_VERSION_MINOR}.${CALYP_VERSION_PATCH}"
|
||||||
CACHE INTERNAL "" FORCE
|
CACHE INTERNAL "" FORCE
|
||||||
)
|
)
|
||||||
|
|
||||||
|
PROJECT(
|
||||||
|
${PROJECT_NAME}
|
||||||
|
VERSION ${CALYP_VERSION}
|
||||||
|
LANGUAGES "CXX"
|
||||||
|
)
|
||||||
|
|
||||||
|
# ####################################################################################################################################################
|
||||||
|
# CMake functions
|
||||||
|
# ####################################################################################################################################################
|
||||||
|
SET(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake)
|
||||||
|
INCLUDE(cmake/ModulesFct.cmake)
|
||||||
|
INCLUDE(FeatureSummary)
|
||||||
|
INCLUDE(GNUInstallDirs)
|
||||||
|
|
||||||
# ####################################################################################################################################################
|
# ####################################################################################################################################################
|
||||||
# Variables
|
# Variables
|
||||||
# ####################################################################################################################################################
|
# ####################################################################################################################################################
|
||||||
@@ -43,6 +48,7 @@ OPTION(BUILD_TOOLS "Build Command Line Application" ON)
|
|||||||
OPTION(BUILD_EXAMPLES "Build Examples" OFF)
|
OPTION(BUILD_EXAMPLES "Build Examples" OFF)
|
||||||
OPTION(BUILD_DOC "Build Documentation" OFF)
|
OPTION(BUILD_DOC "Build Documentation" OFF)
|
||||||
OPTION(BUILD_TESTS "Build Google Tests" OFF)
|
OPTION(BUILD_TESTS "Build Google Tests" OFF)
|
||||||
|
OPTION(BUILD_TESTS_CATCH2 "Build Catch2 Tests" OFF)
|
||||||
|
|
||||||
OPTION(USE_FERVOR "Add Fervor support" OFF)
|
OPTION(USE_FERVOR "Add Fervor support" OFF)
|
||||||
|
|
||||||
@@ -119,6 +125,17 @@ IF(BUILD_TESTS)
|
|||||||
)
|
)
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
|
IF(BUILD_TESTS_CATCH2)
|
||||||
|
FIND_PACKAGE(Catch2 REQUIRED)
|
||||||
|
ENABLE_TESTING()
|
||||||
|
SET_PACKAGE_PROPERTIES(
|
||||||
|
Catch2 PROPERTIES
|
||||||
|
URL "https://github.com/catchorg/Catch2"
|
||||||
|
DESCRIPTION "Catch2 unit tests"
|
||||||
|
TYPE OPTIONAL
|
||||||
|
)
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
OPTION(USE_OPENCV "Add OpenCV support" ON)
|
OPTION(USE_OPENCV "Add OpenCV support" ON)
|
||||||
IF(USE_OPENCV)
|
IF(USE_OPENCV)
|
||||||
|
|
||||||
@@ -147,10 +164,6 @@ SET_PACKAGE_PROPERTIES(
|
|||||||
OPTION(USE_FFMPEG "Add FFMPEG support" ON)
|
OPTION(USE_FFMPEG "Add FFMPEG support" ON)
|
||||||
IF(USE_FFMPEG)
|
IF(USE_FFMPEG)
|
||||||
FIND_PACKAGE(FFmpeg COMPONENTS AVCODEC AVFORMAT AVUTIL SWSCALE)
|
FIND_PACKAGE(FFmpeg COMPONENTS AVCODEC AVFORMAT AVUTIL SWSCALE)
|
||||||
IF("${AVCODEC_VERSION}" VERSION_LESS "56.0.0")
|
|
||||||
SET(FFMPEG_FOUND FALSE)
|
|
||||||
SET(FFmpeg_FOUND FALSE)
|
|
||||||
ENDIF()
|
|
||||||
SET(USE_FFMPEG ${FFMPEG_FOUND})
|
SET(USE_FFMPEG ${FFMPEG_FOUND})
|
||||||
ENDIF()
|
ENDIF()
|
||||||
SET_PACKAGE_PROPERTIES(
|
SET_PACKAGE_PROPERTIES(
|
||||||
|
|||||||
@@ -24,6 +24,10 @@
|
|||||||
|
|
||||||
#include "PlotSubWindow.h"
|
#include "PlotSubWindow.h"
|
||||||
|
|
||||||
|
#include <QGuiApplication>
|
||||||
|
#include <QScreen>
|
||||||
|
#include <QSize>
|
||||||
|
|
||||||
#include "qcustomplot.h"
|
#include "qcustomplot.h"
|
||||||
//#include "external/qcustomplot/qcustomplot.h"
|
//#include "external/qcustomplot/qcustomplot.h"
|
||||||
|
|
||||||
@@ -174,7 +178,7 @@ QSize PlotSubWindow::sizeHint() const
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
maxSize = QApplication::desktop()->availableGeometry().size();
|
maxSize = QGuiApplication::screens()[0]->availableGeometry().size();
|
||||||
}
|
}
|
||||||
return sizeHint( maxSize );
|
return sizeHint( maxSize );
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -29,10 +29,12 @@
|
|||||||
#include <QActionGroup>
|
#include <QActionGroup>
|
||||||
#include <QApplication>
|
#include <QApplication>
|
||||||
#include <QDesktopWidget>
|
#include <QDesktopWidget>
|
||||||
|
#include <QGuiApplication>
|
||||||
#include <QHBoxLayout>
|
#include <QHBoxLayout>
|
||||||
#include <QMdiArea>
|
#include <QMdiArea>
|
||||||
#include <QMenu>
|
#include <QMenu>
|
||||||
#include <QPainter>
|
#include <QPainter>
|
||||||
|
#include <QScreen>
|
||||||
#include <QSettings>
|
#include <QSettings>
|
||||||
#include <QSignalMapper>
|
#include <QSignalMapper>
|
||||||
#include <QStyle>
|
#include <QStyle>
|
||||||
@@ -154,7 +156,7 @@ void SubWindowHandle::setWindowMode( int iWindowMode )
|
|||||||
parentWidget()->update();
|
parentWidget()->update();
|
||||||
m_pcApp->showNormal();
|
m_pcApp->showNormal();
|
||||||
qApp->processEvents();
|
qApp->processEvents();
|
||||||
QSize screenSize = QApplication::desktop()->availableGeometry().size();
|
QSize screenSize = QGuiApplication::screens()[0]->availableGeometry().size();
|
||||||
m_pcApp->move( 0, 0 );
|
m_pcApp->move( 0, 0 );
|
||||||
m_pcApp->resize( screenSize.width(), 5 );
|
m_pcApp->resize( screenSize.width(), 5 );
|
||||||
m_pcApp->setWindowTitle( QApplication::applicationName() );
|
m_pcApp->setWindowTitle( QApplication::applicationName() );
|
||||||
@@ -230,12 +232,14 @@ void SubWindowHandle::addMdiSubWindow( SubWindowAbstract* window )
|
|||||||
SLOT( removeMdiSubWindow( MdiSubWindow* ) ) );
|
SLOT( removeMdiSubWindow( MdiSubWindow* ) ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
void SubWindowHandle::addSubWindow( SubWindowAbstract* window, Qt::WindowFlags flags )
|
void SubWindowHandle::addSubWindow( SubWindowAbstract* window )
|
||||||
{
|
{
|
||||||
if( window )
|
if( window )
|
||||||
{
|
{
|
||||||
connect( window, SIGNAL( updateStatusBar( const QString& ) ), m_pcApp, SLOT( printMessage( const QString& ) ) );
|
connect( window, SIGNAL( updateStatusBar( const QString& ) ), m_pcApp,
|
||||||
connect( window, SIGNAL( zoomFactorChanged( const double, const QPoint ) ), m_pcApp, SLOT( updateZoomFactorSBox() ) );
|
SLOT( printMessage( const QString& ) ) );
|
||||||
|
connect( window, SIGNAL( zoomFactorChanged( const double, const QPoint ) ), m_pcApp,
|
||||||
|
SLOT( updateZoomFactorSBox() ) );
|
||||||
if( m_iWindowMode == DETACHEDSUBWINDOWMODE )
|
if( m_iWindowMode == DETACHEDSUBWINDOWMODE )
|
||||||
{
|
{
|
||||||
connect( window, SIGNAL( aboutToActivate( SubWindowAbstract* ) ), this,
|
connect( window, SIGNAL( aboutToActivate( SubWindowAbstract* ) ), this,
|
||||||
@@ -378,7 +382,7 @@ void SubWindowHandle::tileSubWindows()
|
|||||||
|
|
||||||
if( m_iWindowMode == DETACHEDSUBWINDOWMODE )
|
if( m_iWindowMode == DETACHEDSUBWINDOWMODE )
|
||||||
{
|
{
|
||||||
QSize screenSize = QApplication::desktop()->availableGeometry().size();
|
QSize screenSize = QGuiApplication::screens()[0]->availableGeometry().size();
|
||||||
unsigned int minWindowsInRow = 1;
|
unsigned int minWindowsInRow = 1;
|
||||||
while( ( screenSize.width() / minWindowsInRow ) > 500 )
|
while( ( screenSize.width() / minWindowsInRow ) > 500 )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -51,7 +51,7 @@ public:
|
|||||||
|
|
||||||
void processLogMsg( const QString& msg );
|
void processLogMsg( const QString& msg );
|
||||||
|
|
||||||
void addSubWindow( SubWindowAbstract* widget, Qt::WindowFlags flags = 0 );
|
void addSubWindow( SubWindowAbstract* widget );
|
||||||
|
|
||||||
SubWindowAbstract* activeSubWindow() const;
|
SubWindowAbstract* activeSubWindow() const;
|
||||||
|
|
||||||
|
|||||||
@@ -259,7 +259,7 @@ QSize VideoSubWindow::sizeHint() const
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
maxSize = QApplication::desktop()->availableGeometry().size();
|
maxSize = QGuiApplication::screens()[0]->availableGeometry().size();
|
||||||
}
|
}
|
||||||
return sizeHint( maxSize );
|
return sizeHint( maxSize );
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -182,7 +182,6 @@ public:
|
|||||||
QSize sizeHint( const QSize& ) const;
|
QSize sizeHint( const QSize& ) const;
|
||||||
|
|
||||||
QString getCurrentFileName() { return m_cFilename; }
|
QString getCurrentFileName() { return m_cFilename; }
|
||||||
bool getIsModule() { return getCategory() | SubWindowAbstract::MODULE_SUBWINDOW; }
|
|
||||||
void clearWindowBusy() { m_bWindowBusy = false; }
|
void clearWindowBusy() { m_bWindowBusy = false; }
|
||||||
void setFillWindow( bool bFlag );
|
void setFillWindow( bool bFlag );
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -730,7 +730,7 @@ void ViewArea::wheelEvent( QWheelEvent* event )
|
|||||||
|
|
||||||
if( event->modifiers() & Qt::ControlModifier )
|
if( event->modifiers() & Qt::ControlModifier )
|
||||||
{
|
{
|
||||||
scale = 0.001 * event->delta();
|
scale = 0.001 * event->angleDelta().y();
|
||||||
if( scale > 0 )
|
if( scale > 0 )
|
||||||
scale = 1.25;
|
scale = 1.25;
|
||||||
else
|
else
|
||||||
|
|||||||
@@ -49,7 +49,7 @@ AboutDialog::AboutDialog( QWidget* parent )
|
|||||||
.arg( QApplication::applicationVersion() ) );
|
.arg( QApplication::applicationVersion() ) );
|
||||||
label->setWordWrap( false );
|
label->setWordWrap( false );
|
||||||
|
|
||||||
QString featuresList = QStringLiteral( "<p><h3><b>Features:</b></h3><ul>" );
|
QString featuresList = QStringLiteral( "<p><h4><b>Features:</b></h4><ul>" );
|
||||||
|
|
||||||
#ifdef USE_QTDBUS
|
#ifdef USE_QTDBUS
|
||||||
featuresList.append( QStringLiteral( "<li>Support for Qt DBus messages" ) );
|
featuresList.append( QStringLiteral( "<li>Support for Qt DBus messages" ) );
|
||||||
@@ -63,14 +63,21 @@ AboutDialog::AboutDialog( QWidget* parent )
|
|||||||
featuresList.append( QStringLiteral( "</ul></p>" ) );
|
featuresList.append( QStringLiteral( "</ul></p>" ) );
|
||||||
QLabel* labelFeatures = new QLabel( featuresList );
|
QLabel* labelFeatures = new QLabel( featuresList );
|
||||||
|
|
||||||
QLabel* labelCopyright = new QLabel( QStringLiteral( "Copyright © 2014–2018 Joao Carreira and Luis Lucas" ) );
|
QString thanksList = QStringLiteral( "<p><h4><b>Thanks to:</b></h4><ul>" );
|
||||||
|
thanksList.append( QStringLiteral( "<li>Joao Santos" ) );
|
||||||
|
thanksList.append( QStringLiteral( "<li>Jose Filipe" ) );
|
||||||
|
thanksList.append( QStringLiteral( "</ul></p>" ) );
|
||||||
|
QLabel* labelContributors = new QLabel( thanksList );
|
||||||
|
|
||||||
|
QLabel* labelCopyright = new QLabel( QStringLiteral( "Copyright 2014–2021 Joao Carreira and Luis Lucas" ) );
|
||||||
|
|
||||||
QWidget* topWidget = new QWidget;
|
QWidget* topWidget = new QWidget;
|
||||||
QVBoxLayout* topLayout = new QVBoxLayout;
|
QVBoxLayout* topLayout = new QVBoxLayout;
|
||||||
topLayout->addWidget( pixmapLabel, 0, Qt::AlignHCenter );
|
topLayout->addWidget( pixmapLabel, 0, Qt::AlignHCenter );
|
||||||
topLayout->addWidget( label );
|
topLayout->addWidget( label );
|
||||||
topLayout->addWidget( labelFeatures );
|
|
||||||
topLayout->addWidget( labelCopyright );
|
topLayout->addWidget( labelCopyright );
|
||||||
|
topLayout->addWidget( labelFeatures );
|
||||||
|
topLayout->addWidget( labelContributors );
|
||||||
topWidget->setLayout( topLayout );
|
topWidget->setLayout( topLayout );
|
||||||
|
|
||||||
// QTextEdit *textEdit = new QTextEdit(tr("<p>This program is free "
|
// QTextEdit *textEdit = new QTextEdit(tr("<p>This program is free "
|
||||||
|
|||||||
@@ -51,6 +51,10 @@ int main( int argc, char* argv[] )
|
|||||||
QApplication::setApplicationVersion( QStringLiteral( CALYP_VERSION_STRING ) );
|
QApplication::setApplicationVersion( QStringLiteral( CALYP_VERSION_STRING ) );
|
||||||
QApplication::setOrganizationName( QStringLiteral( "PixLRA" ) );
|
QApplication::setOrganizationName( QStringLiteral( "PixLRA" ) );
|
||||||
|
|
||||||
|
#if _WIN32
|
||||||
|
application.setStyle( QStyleFactory::create( "Fusion" ) );
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifdef USE_QTDBUS
|
#ifdef USE_QTDBUS
|
||||||
/**
|
/**
|
||||||
* use dbus, if available
|
* use dbus, if available
|
||||||
|
|||||||
@@ -86,6 +86,7 @@ IF(NOT FFMPEG_LIBRARIES)
|
|||||||
FIND_COMPONENT(AVDEVICE libavdevice avdevice libavdevice/avdevice.h)
|
FIND_COMPONENT(AVDEVICE libavdevice avdevice libavdevice/avdevice.h)
|
||||||
FIND_COMPONENT(AVUTIL libavutil avutil libavutil/avutil.h)
|
FIND_COMPONENT(AVUTIL libavutil avutil libavutil/avutil.h)
|
||||||
FIND_COMPONENT(SWSCALE libswscale swscale libswscale/swscale.h)
|
FIND_COMPONENT(SWSCALE libswscale swscale libswscale/swscale.h)
|
||||||
|
FIND_COMPONENT(SWRESAMPLE libswresample swresample libswresample/swresample.h)
|
||||||
FIND_COMPONENT(POSTPROC libpostproc postproc libpostproc/postprocess.h)
|
FIND_COMPONENT(POSTPROC libpostproc postproc libpostproc/postprocess.h)
|
||||||
|
|
||||||
# Check if the required components were found and add their stuff to the FFMPEG_* vars.
|
# Check if the required components were found and add their stuff to the FFMPEG_* vars.
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ MACRO(ADD_MODULE name file)
|
|||||||
OPTION(MODULE_${name} "Use module ${name}" ON)
|
OPTION(MODULE_${name} "Use module ${name}" ON)
|
||||||
ADD_FEATURE_INFO(${name} MODULE_${name} "Module ${name}")
|
ADD_FEATURE_INFO(${name} MODULE_${name} "Module ${name}")
|
||||||
IF(MODULE_${name})
|
IF(MODULE_${name})
|
||||||
LIST(APPEND Calyp_Mod_SRCS ${MODULE_LOCATION}${file})
|
LIST(APPEND Calyp_Mod_SRCS ${MODULE_LOCATION}${file}.cpp)
|
||||||
LIST(APPEND MODULES_LIST_NAME ${name})
|
LIST(APPEND MODULES_LIST_NAME ${name})
|
||||||
LIST(APPEND MODULES_LIST_FILES ${file})
|
LIST(APPEND MODULES_LIST_FILES ${file})
|
||||||
SET(Calyp_Mod_SRCS
|
SET(Calyp_Mod_SRCS
|
||||||
|
|||||||
+1
-5
@@ -77,9 +77,5 @@ IF(USE_FFMPEG)
|
|||||||
"FFmpeg-Dir"
|
"FFmpeg-Dir"
|
||||||
CACHE PATH "Where to find FFmpeg Lib on Windows"
|
CACHE PATH "Where to find FFmpeg Lib on Windows"
|
||||||
)
|
)
|
||||||
INSTALL(FILES ${FFMPEG_DIR}/bin/avcodec-${AVCODEC_VERSION}.dll DESTINATION bin)
|
INSTALL(DIRECTORY ${FFMPEG_DIR}/bin/ DESTINATION bin)
|
||||||
INSTALL(FILES ${FFMPEG_DIR}/bin/avformat-${AVFORMAT_VERSION}.dll DESTINATION bin)
|
|
||||||
INSTALL(FILES ${FFMPEG_DIR}/bin/avutil-${AVUTIL_VERSION}.dll DESTINATION bin)
|
|
||||||
INSTALL(FILES ${FFMPEG_DIR}/bin/swscale-${SWSCALE_VERSION}.dll DESTINATION bin)
|
|
||||||
INSTALL(FILES ${FFMPEG_DIR}/bin/swresample-${SWRESAMPLE_VERSION}.dll DESTINATION bin)
|
|
||||||
ENDIF()
|
ENDIF()
|
||||||
@@ -85,3 +85,7 @@ ENDIF()
|
|||||||
IF(BUILD_TESTS)
|
IF(BUILD_TESTS)
|
||||||
ADD_SUBDIRECTORY(tests)
|
ADD_SUBDIRECTORY(tests)
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
|
IF(BUILD_TESTS_CATCH2)
|
||||||
|
ADD_SUBDIRECTORY(catch2)
|
||||||
|
ENDIF()
|
||||||
@@ -91,7 +91,7 @@ bool StreamHandlerLibav::openHandler( ClpString strFilename, bool bInput )
|
|||||||
// }
|
// }
|
||||||
|
|
||||||
// Register all components of FFmpeg
|
// Register all components of FFmpeg
|
||||||
av_register_all();
|
//av_register_all();
|
||||||
|
|
||||||
/* open input file, and allocate format context */
|
/* open input file, and allocate format context */
|
||||||
if( avformat_open_input( &m_cFmtCtx, filename, NULL, NULL ) < 0 )
|
if( avformat_open_input( &m_cFmtCtx, filename, NULL, NULL ) < 0 )
|
||||||
|
|||||||
@@ -0,0 +1,12 @@
|
|||||||
|
#
|
||||||
|
# CMakeLists for Calyp lis tests using catch2
|
||||||
|
#
|
||||||
|
|
||||||
|
# ADD_DEFINITIONS(-DCALYP_TEST_DATA_DIR=\"${CALYP_TEST_DATA_DIR}\")
|
||||||
|
|
||||||
|
SET(Calyp_Lib_Catch2_Tests_SRCS CalypFrameTests.cpp)
|
||||||
|
|
||||||
|
ADD_EXECUTABLE(CalypLibCatch2Tests ${Calyp_Lib_Catch2_Tests_SRCS})
|
||||||
|
TARGET_LINK_LIBRARIES(CalypLibCatch2Tests ${PROJECT_LIBRARY} Catch2::Catch2)
|
||||||
|
|
||||||
|
INCLUDE(CTest)
|
||||||
@@ -0,0 +1,39 @@
|
|||||||
|
/* This file is a part of plaYUVer project
|
||||||
|
* Copyright (C) 2014-2021 by Joao Carreira (jfmcarreira@gmail.com)
|
||||||
|
* Luis Lucas (luisfrlucas@gmail.com)
|
||||||
|
*
|
||||||
|
* This program is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* This program is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License along
|
||||||
|
* with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* \file CalypFrameTests.cpp
|
||||||
|
* \brief CalypFrame general tests
|
||||||
|
*/
|
||||||
|
|
||||||
|
#define CATCH_CONFIG_MAIN
|
||||||
|
#include <catch2/catch.hpp>
|
||||||
|
|
||||||
|
#include "CalypFrame.h"
|
||||||
|
|
||||||
|
TEST_CASE( "create a 256x128 frame in YUV420 format", "CalypFrame" )
|
||||||
|
{
|
||||||
|
// Constructor: CalypFrame( unsigned int width, unsigned int height, int pelFormat, unsigned bitsPixel = 8 );
|
||||||
|
CalypFrame testFrame( 256, 128, CLP_YUV420P, 8 );
|
||||||
|
|
||||||
|
REQUIRE( testFrame.getWidth() == 256 );
|
||||||
|
REQUIRE( testFrame.getHeight() == 128 );
|
||||||
|
REQUIRE( testFrame.getPelFormat() == CLP_YUV420P );
|
||||||
|
REQUIRE( testFrame.getBitsPel() == 8 );
|
||||||
|
}
|
||||||
Reference in new issue
Block a user