diff --git a/CMake/GitExternal.cmake b/CMake/GitExternal.cmake index 801fb1c..8c8fdd5 100644 --- a/CMake/GitExternal.cmake +++ b/CMake/GitExternal.cmake @@ -10,9 +10,9 @@ # * Provides function # git_external( [VERBOSE,SHALLOW] # [RESET ]) -# which will check out directory in COMMON_SOURCE_DIR if relative, +# which will check out directory in CMAKE_SOURCE_DIR (if relative) # or in the given absolute path using the given repository and tag -# if commit-ish. +# (commit-ish). # # Options which can be supplied to the function: # VERBOSE, when present, this option tells the function to output @@ -43,9 +43,6 @@ # If set, a remote called 'user' is set up for github repositories, pointing # to git@github.com:/. Also, this remote is used by default # for 'git push'. -# COMMON_SOURCE_DIR -# Download location of the source code of subprojects and externals. -# Defaults to CMAKE_SOURCE_DIR. if(NOT GIT_FOUND) @@ -56,15 +53,8 @@ if(NOT GIT_EXECUTABLE) endif() include(CMakeParseArguments) - option(GIT_EXTERNAL_VERBOSE "Print git commands as they are executed" OFF) -set(COMMON_SOURCE_DIR "${CMAKE_SOURCE_DIR}" CACHE PATH - "Location of common directory of all sources") -set(__common_source_dir ${COMMON_SOURCE_DIR}) -get_filename_component(__common_source_dir ${__common_source_dir} ABSOLUTE) -file(MAKE_DIRECTORY ${__common_source_dir}) - if(NOT GITHUB_USER AND DEFINED ENV{GITHUB_USER}) set(GITHUB_USER $ENV{GITHUB_USER} CACHE STRING "Github user name used to setup remote for 'user' forks") @@ -105,7 +95,7 @@ function(GIT_EXTERNAL DIR REPO tag) endif() if(NOT IS_ABSOLUTE "${DIR}") - set(DIR "${COMMON_SOURCE_DIR}/${DIR}") + set(DIR "${CMAKE_SOURCE_DIR}/${DIR}") endif() get_filename_component(NAME "${DIR}" NAME) get_filename_component(GIT_EXTERNAL_DIR "${DIR}/.." ABSOLUTE) @@ -161,7 +151,11 @@ function(GIT_EXTERNAL DIR REPO tag) OUTPUT_QUIET ERROR_QUIET WORKING_DIRECTORY "${DIR}") endif() - file(RELATIVE_PATH __dir ${COMMON_SOURCE_DIR} ${DIR}) + if(COMMON_SOURCE_DIR) + file(RELATIVE_PATH __dir ${COMMON_SOURCE_DIR} ${DIR}) + else() + file(RELATIVE_PATH __dir ${CMAKE_SOURCE_DIR} ${DIR}) + endif() string(REGEX REPLACE "[:/\\.]" "-" __target "${__dir}") if(TARGET ${__target}-rebase) return() @@ -307,11 +301,11 @@ if(EXISTS ${GIT_EXTERNALS} AND NOT GIT_EXTERNAL_SCRIPT_MODE) file(WRITE "${GIT_EXTERNAL_SCRIPT}" " include(\"${CMAKE_CURRENT_LIST_DIR}/GitExternal.cmake\") execute_process(COMMAND \"${GIT_EXECUTABLE}\" fetch origin -q - WORKING_DIRECTORY \"${COMMON_SOURCE_DIR}/${DIR}\") + WORKING_DIRECTORY \"${CMAKE_SOURCE_DIR}/${DIR}\") execute_process( COMMAND \"${GIT_EXECUTABLE}\" show-ref --hash=7 refs/remotes/origin/master OUTPUT_VARIABLE newref OUTPUT_STRIP_TRAILING_WHITESPACE - WORKING_DIRECTORY \"${COMMON_SOURCE_DIR}/${DIR}\") + WORKING_DIRECTORY \"${CMAKE_SOURCE_DIR}/${DIR}\") if(newref) file(APPEND ${GIT_EXTERNALS} \"# ${DIR} ${REPO} \${newref}\\n\") git_external(${DIR} ${REPO} \${newref}) diff --git a/CMakeLists.txt b/CMakeLists.txt index 7507630..6ba4dad 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -11,7 +11,7 @@ list(APPEND CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/CMake include(GitExternal) set(VERSION_MAJOR "0") -set(VERSION_MINOR "8") +set(VERSION_MINOR "9") set(VERSION_PATCH "0") set(VERSION_ABI 2) diff --git a/apps/DesktopStreamer/CMakeLists.txt b/apps/DesktopStreamer/CMakeLists.txt index e93c5ed..828ebd8 100644 --- a/apps/DesktopStreamer/CMakeLists.txt +++ b/apps/DesktopStreamer/CMakeLists.txt @@ -3,19 +3,18 @@ # Raphael Dumusc set(DESKTOPSTREAMER_MOC_HEADERS - DesktopSelectionWindow.h - DesktopSelectionRectangle.h MainWindow.h ) set(DESKTOPSTREAMER_SOURCES - DesktopSelectionRectangle.cpp - DesktopSelectionWindow.cpp - DesktopSelectionView.cpp MainWindow.cpp main.cpp ) +set(DESKTOPSTREAMER_UI_FORMS + MainWindow.ui +) + set(DESKTOPSTREAMER_LINK_LIBRARIES Deflect Qt5::Core diff --git a/apps/DesktopStreamer/DesktopSelectionRectangle.cpp b/apps/DesktopStreamer/DesktopSelectionRectangle.cpp deleted file mode 100644 index 8e3251d..0000000 --- a/apps/DesktopStreamer/DesktopSelectionRectangle.cpp +++ /dev/null @@ -1,126 +0,0 @@ -/*********************************************************************/ -/* Copyright (c) 2011 - 2012, The University of Texas at Austin. */ -/* All rights reserved. */ -/* */ -/* Redistribution and use in source and binary forms, with or */ -/* without modification, are permitted provided that the following */ -/* conditions are met: */ -/* */ -/* 1. Redistributions of source code must retain the above */ -/* copyright notice, this list of conditions and the following */ -/* disclaimer. */ -/* */ -/* 2. Redistributions in binary form must reproduce the above */ -/* copyright notice, this list of conditions and the following */ -/* disclaimer in the documentation and/or other materials */ -/* provided with the distribution. */ -/* */ -/* THIS SOFTWARE IS PROVIDED BY THE UNIVERSITY OF TEXAS AT */ -/* AUSTIN ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, */ -/* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF */ -/* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE */ -/* DISCLAIMED. IN NO EVENT SHALL THE UNIVERSITY OF TEXAS AT */ -/* AUSTIN OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, */ -/* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES */ -/* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE */ -/* GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR */ -/* BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF */ -/* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT */ -/* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT */ -/* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE */ -/* POSSIBILITY OF SUCH DAMAGE. */ -/* */ -/* The views and conclusions contained in the software and */ -/* documentation are those of the authors and should not be */ -/* interpreted as representing official policies, either expressed */ -/* or implied, of The University of Texas at Austin. */ -/*********************************************************************/ - -#include "DesktopSelectionRectangle.h" - -#include - -#define PEN_WIDTH 10 // should be even -#define CORNER_RESIZE_THRESHOLD 50 -#define DEFAULT_SIZE 100 - -DesktopSelectionRectangle::DesktopSelectionRectangle() - : _resizing( false ) -{ - setFlag( QGraphicsItem::ItemIsMovable, true ); - setPen( QPen( QBrush( QColor( 255, 0, 0 )), PEN_WIDTH )); - setCoordinates( QRect( 0, 0, DEFAULT_SIZE, DEFAULT_SIZE )); -} - -void DesktopSelectionRectangle::paint( QPainter* painter, - const QStyleOptionGraphicsItem* option, - QWidget* widget ) -{ - QGraphicsRectItem::paint( painter, option, widget ); -} - -void DesktopSelectionRectangle::setCoordinates( const QRect& coordinates ) -{ - _coordinates = coordinates; - - setRect( mapRectFromScene( _coordinates.x() - PEN_WIDTH/2, - _coordinates.y() - PEN_WIDTH/2, - _coordinates.width() + PEN_WIDTH, - _coordinates.height() + PEN_WIDTH )); -} - -void DesktopSelectionRectangle::mouseMoveEvent( QGraphicsSceneMouseEvent* - mouseEvent ) -{ - if( mouseEvent->buttons().testFlag( Qt::LeftButton )) - { - if( _resizing ) - { - QRectF r = rect(); - r.setBottomRight( mouseEvent->pos( )); - setRect( r ); - } - else - { - QPointF delta = mouseEvent->pos() - mouseEvent->lastPos(); - moveBy( delta.x(), delta.y( )); - } - - _updateCoordinates(); - emit coordinatesChanged( _coordinates ); - } -} - -void DesktopSelectionRectangle::mousePressEvent( QGraphicsSceneMouseEvent* - mouseEvent ) -{ - // item rectangle and event position - const QPointF cornerPos = rect().bottomRight(); - const QPointF eventPos = mouseEvent->pos(); - - // check to see if user clicked on the resize button - if( std::abs( cornerPos.x() - eventPos.x( )) <= CORNER_RESIZE_THRESHOLD && - std::abs( cornerPos.y() - eventPos.y( )) <= CORNER_RESIZE_THRESHOLD ) - { - _resizing = true; - } - - QGraphicsItem::mousePressEvent( mouseEvent ); -} - -void DesktopSelectionRectangle::mouseReleaseEvent( QGraphicsSceneMouseEvent* - mouseEvent ) -{ - _resizing = false; - QGraphicsItem::mouseReleaseEvent( mouseEvent ); -} - -void DesktopSelectionRectangle::_updateCoordinates() -{ - const QRectF sceneRect = mapRectToScene( rect( )); - - _coordinates.setX( (int)sceneRect.x() + PEN_WIDTH/2 ); - _coordinates.setY( (int)sceneRect.y() + PEN_WIDTH/2 ); - _coordinates.setWidth( (int)sceneRect.width() - PEN_WIDTH ); - _coordinates.setHeight( (int)sceneRect.height() - PEN_WIDTH ); -} diff --git a/apps/DesktopStreamer/DesktopSelectionRectangle.h b/apps/DesktopStreamer/DesktopSelectionRectangle.h deleted file mode 100644 index 9968aef..0000000 --- a/apps/DesktopStreamer/DesktopSelectionRectangle.h +++ /dev/null @@ -1,72 +0,0 @@ -/*********************************************************************/ -/* Copyright (c) 2011 - 2012, The University of Texas at Austin. */ -/* All rights reserved. */ -/* */ -/* Redistribution and use in source and binary forms, with or */ -/* without modification, are permitted provided that the following */ -/* conditions are met: */ -/* */ -/* 1. Redistributions of source code must retain the above */ -/* copyright notice, this list of conditions and the following */ -/* disclaimer. */ -/* */ -/* 2. Redistributions in binary form must reproduce the above */ -/* copyright notice, this list of conditions and the following */ -/* disclaimer in the documentation and/or other materials */ -/* provided with the distribution. */ -/* */ -/* THIS SOFTWARE IS PROVIDED BY THE UNIVERSITY OF TEXAS AT */ -/* AUSTIN ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, */ -/* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF */ -/* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE */ -/* DISCLAIMED. IN NO EVENT SHALL THE UNIVERSITY OF TEXAS AT */ -/* AUSTIN OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, */ -/* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES */ -/* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE */ -/* GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR */ -/* BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF */ -/* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT */ -/* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT */ -/* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE */ -/* POSSIBILITY OF SUCH DAMAGE. */ -/* */ -/* The views and conclusions contained in the software and */ -/* documentation are those of the authors and should not be */ -/* interpreted as representing official policies, either expressed */ -/* or implied, of The University of Texas at Austin. */ -/*********************************************************************/ - -#ifndef DESKTOP_SELECTION_RECTANGLE_H -#define DESKTOP_SELECTION_RECTANGLE_H - -#include - -#include - -class DesktopSelectionRectangle : public QObject, public QGraphicsRectItem -{ - Q_OBJECT - -public: - DesktopSelectionRectangle(); - - void paint( QPainter* painter, const QStyleOptionGraphicsItem* option, - QWidget* widget = 0 ) final; - - void setCoordinates( const QRect& coordinates ); - -signals: - void coordinatesChanged( QRect coordinates ); - -private: - void mouseMoveEvent( QGraphicsSceneMouseEvent* event ) final; - void mousePressEvent( QGraphicsSceneMouseEvent* event ) final; - void mouseReleaseEvent( QGraphicsSceneMouseEvent* event ) final; - - void _updateCoordinates(); - - bool _resizing; - QRect _coordinates; -}; - -#endif diff --git a/apps/DesktopStreamer/DesktopSelectionView.cpp b/apps/DesktopStreamer/DesktopSelectionView.cpp deleted file mode 100644 index b5ba052..0000000 --- a/apps/DesktopStreamer/DesktopSelectionView.cpp +++ /dev/null @@ -1,74 +0,0 @@ -/*********************************************************************/ -/* Copyright (c) 2011 - 2012, The University of Texas at Austin. */ -/* All rights reserved. */ -/* */ -/* Redistribution and use in source and binary forms, with or */ -/* without modification, are permitted provided that the following */ -/* conditions are met: */ -/* */ -/* 1. Redistributions of source code must retain the above */ -/* copyright notice, this list of conditions and the following */ -/* disclaimer. */ -/* */ -/* 2. Redistributions in binary form must reproduce the above */ -/* copyright notice, this list of conditions and the following */ -/* disclaimer in the documentation and/or other materials */ -/* provided with the distribution. */ -/* */ -/* THIS SOFTWARE IS PROVIDED BY THE UNIVERSITY OF TEXAS AT */ -/* AUSTIN ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, */ -/* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF */ -/* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE */ -/* DISCLAIMED. IN NO EVENT SHALL THE UNIVERSITY OF TEXAS AT */ -/* AUSTIN OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, */ -/* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES */ -/* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE */ -/* GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR */ -/* BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF */ -/* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT */ -/* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT */ -/* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE */ -/* POSSIBILITY OF SUCH DAMAGE. */ -/* */ -/* The views and conclusions contained in the software and */ -/* documentation are those of the authors and should not be */ -/* interpreted as representing official policies, either expressed */ -/* or implied, of The University of Texas at Austin. */ -/*********************************************************************/ - -#include "DesktopSelectionView.h" - -#include "DesktopSelectionRectangle.h" - -DesktopSelectionView::DesktopSelectionView( QWidget* widget_ ) - : QGraphicsView( widget_ ) - , _desktopSelectionRectangle( 0 ) -{ - setScene( new QGraphicsScene( )); - - setAlignment( Qt::AlignLeft | Qt::AlignTop ); - setInteractive( true ); - - setHorizontalScrollBarPolicy( Qt::ScrollBarAlwaysOff ); - setVerticalScrollBarPolicy( Qt::ScrollBarAlwaysOff ); - - _desktopSelectionRectangle = new DesktopSelectionRectangle(); - scene()->addItem( _desktopSelectionRectangle ); -} - -DesktopSelectionView::~DesktopSelectionView() -{ - delete _desktopSelectionRectangle; -} - -DesktopSelectionRectangle* DesktopSelectionView::getSelectionRectangle() -{ - return _desktopSelectionRectangle; -} - -void DesktopSelectionView::resizeEvent( QResizeEvent* resizeEvt ) -{ - setSceneRect( rect( )); // scene rectangle matches viewport rectangle - - QGraphicsView::resizeEvent( resizeEvt ); -} diff --git a/apps/DesktopStreamer/DesktopSelectionView.h b/apps/DesktopStreamer/DesktopSelectionView.h deleted file mode 100644 index c0b83f7..0000000 --- a/apps/DesktopStreamer/DesktopSelectionView.h +++ /dev/null @@ -1,62 +0,0 @@ -/*********************************************************************/ -/* Copyright (c) 2011 - 2012, The University of Texas at Austin. */ -/* All rights reserved. */ -/* */ -/* Redistribution and use in source and binary forms, with or */ -/* without modification, are permitted provided that the following */ -/* conditions are met: */ -/* */ -/* 1. Redistributions of source code must retain the above */ -/* copyright notice, this list of conditions and the following */ -/* disclaimer. */ -/* */ -/* 2. Redistributions in binary form must reproduce the above */ -/* copyright notice, this list of conditions and the following */ -/* disclaimer in the documentation and/or other materials */ -/* provided with the distribution. */ -/* */ -/* THIS SOFTWARE IS PROVIDED BY THE UNIVERSITY OF TEXAS AT */ -/* AUSTIN ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, */ -/* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF */ -/* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE */ -/* DISCLAIMED. IN NO EVENT SHALL THE UNIVERSITY OF TEXAS AT */ -/* AUSTIN OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, */ -/* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES */ -/* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE */ -/* GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR */ -/* BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF */ -/* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT */ -/* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT */ -/* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE */ -/* POSSIBILITY OF SUCH DAMAGE. */ -/* */ -/* The views and conclusions contained in the software and */ -/* documentation are those of the authors and should not be */ -/* interpreted as representing official policies, either expressed */ -/* or implied, of The University of Texas at Austin. */ -/*********************************************************************/ - -#ifndef DESKTOP_SELECTION_VIEW_H -#define DESKTOP_SELECTION_VIEW_H - -#include - -#include - -class DesktopSelectionRectangle; - -class DesktopSelectionView : public QGraphicsView -{ -public: - explicit DesktopSelectionView( QWidget* parent ); - ~DesktopSelectionView(); - - DesktopSelectionRectangle* getSelectionRectangle(); - -private: - void resizeEvent( QResizeEvent* event ) final; - - DesktopSelectionRectangle* _desktopSelectionRectangle; -}; - -#endif diff --git a/apps/DesktopStreamer/DesktopSelectionWindow.cpp b/apps/DesktopStreamer/DesktopSelectionWindow.cpp deleted file mode 100644 index 2973407..0000000 --- a/apps/DesktopStreamer/DesktopSelectionWindow.cpp +++ /dev/null @@ -1,77 +0,0 @@ -/*********************************************************************/ -/* Copyright (c) 2011 - 2012, The University of Texas at Austin. */ -/* All rights reserved. */ -/* */ -/* Redistribution and use in source and binary forms, with or */ -/* without modification, are permitted provided that the following */ -/* conditions are met: */ -/* */ -/* 1. Redistributions of source code must retain the above */ -/* copyright notice, this list of conditions and the following */ -/* disclaimer. */ -/* */ -/* 2. Redistributions in binary form must reproduce the above */ -/* copyright notice, this list of conditions and the following */ -/* disclaimer in the documentation and/or other materials */ -/* provided with the distribution. */ -/* */ -/* THIS SOFTWARE IS PROVIDED BY THE UNIVERSITY OF TEXAS AT */ -/* AUSTIN ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, */ -/* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF */ -/* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE */ -/* DISCLAIMED. IN NO EVENT SHALL THE UNIVERSITY OF TEXAS AT */ -/* AUSTIN OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, */ -/* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES */ -/* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE */ -/* GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR */ -/* BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF */ -/* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT */ -/* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT */ -/* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE */ -/* POSSIBILITY OF SUCH DAMAGE. */ -/* */ -/* The views and conclusions contained in the software and */ -/* documentation are those of the authors and should not be */ -/* interpreted as representing official policies, either expressed */ -/* or implied, of The University of Texas at Austin. */ -/*********************************************************************/ - -#include "DesktopSelectionWindow.h" - -#include "DesktopSelectionView.h" - -DesktopSelectionWindow::DesktopSelectionWindow() - : _desktopSelectionView( new DesktopSelectionView( this )) -{ - // make window transparent - setStyleSheet( "background:transparent;" ); - setAttribute( Qt::WA_TranslucentBackground ); - setWindowFlags( Qt::FramelessWindowHint ); - - // window stays on top - Qt::WindowFlags flags = windowFlags(); - setWindowFlags( flags | Qt::CustomizeWindowHint | - Qt::WindowStaysOnTopHint ); - - // add the view after showing the window to avoid shadow artifacts on Mac - setCentralWidget( _desktopSelectionView ); - - QPushButton* hideWindowButton = new QPushButton( "Exit selection mode" ); - connect( hideWindowButton, SIGNAL( pressed( )), this, SLOT( hide( ))); - // makes the button square so the background doesn't look bad - hideWindowButton->setFlat( true ); - - _desktopSelectionView->scene()->addWidget( hideWindowButton ); -} - -DesktopSelectionRectangle* DesktopSelectionWindow::getSelectionRectangle() -{ - return _desktopSelectionView->getSelectionRectangle(); -} - -void DesktopSelectionWindow::hideEvent( QHideEvent* hideEvt ) -{ - QWidget::hideEvent( hideEvt ); - - emit windowVisible( false ); -} diff --git a/apps/DesktopStreamer/DesktopSelectionWindow.h b/apps/DesktopStreamer/DesktopSelectionWindow.h deleted file mode 100644 index 34ba9fd..0000000 --- a/apps/DesktopStreamer/DesktopSelectionWindow.h +++ /dev/null @@ -1,67 +0,0 @@ -/*********************************************************************/ -/* Copyright (c) 2011 - 2012, The University of Texas at Austin. */ -/* All rights reserved. */ -/* */ -/* Redistribution and use in source and binary forms, with or */ -/* without modification, are permitted provided that the following */ -/* conditions are met: */ -/* */ -/* 1. Redistributions of source code must retain the above */ -/* copyright notice, this list of conditions and the following */ -/* disclaimer. */ -/* */ -/* 2. Redistributions in binary form must reproduce the above */ -/* copyright notice, this list of conditions and the following */ -/* disclaimer in the documentation and/or other materials */ -/* provided with the distribution. */ -/* */ -/* THIS SOFTWARE IS PROVIDED BY THE UNIVERSITY OF TEXAS AT */ -/* AUSTIN ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, */ -/* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF */ -/* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE */ -/* DISCLAIMED. IN NO EVENT SHALL THE UNIVERSITY OF TEXAS AT */ -/* AUSTIN OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, */ -/* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES */ -/* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE */ -/* GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR */ -/* BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF */ -/* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT */ -/* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT */ -/* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE */ -/* POSSIBILITY OF SUCH DAMAGE. */ -/* */ -/* The views and conclusions contained in the software and */ -/* documentation are those of the authors and should not be */ -/* interpreted as representing official policies, either expressed */ -/* or implied, of The University of Texas at Austin. */ -/*********************************************************************/ - -#ifndef DESKTOP_SELECTION_WINDOW_H -#define DESKTOP_SELECTION_WINDOW_H - -#include - -#include - -class DesktopSelectionView; -class DesktopSelectionRectangle; - -class DesktopSelectionWindow : public QMainWindow -{ - Q_OBJECT - -public: - DesktopSelectionWindow(); - - DesktopSelectionRectangle* getSelectionRectangle(); - -signals: - void windowVisible( bool visible ); - -private: - void hideEvent( QHideEvent* event ) final; - - DesktopSelectionView* _desktopSelectionView; -}; - -#endif diff --git a/apps/DesktopStreamer/MainWindow.cpp b/apps/DesktopStreamer/MainWindow.cpp index 4344f4f..109230b 100644 --- a/apps/DesktopStreamer/MainWindow.cpp +++ b/apps/DesktopStreamer/MainWindow.cpp @@ -38,15 +38,16 @@ #include "MainWindow.h" -#include "DesktopSelectionWindow.h" -#include "DesktopSelectionRectangle.h" - #include #include #include #include +#include +#include +#include + #ifdef _WIN32 typedef __int32 int32_t; # include @@ -67,137 +68,48 @@ typedef __int32 int32_t; #define SHARE_DESKTOP_UPDATE_DELAY 1 #define SERVUS_BROWSE_DELAY 100 #define FRAME_RATE_AVERAGE_NUM_FRAMES 10 - -#define DEFAULT_HOST_ADDRESS "bbpav02.epfl.ch" #define CURSOR_IMAGE_FILE ":/cursor.png" +#define CURSOR_IMAGE_SIZE 20 + +const std::vector< std::pair< QString, QString > > defaultHosts = { + { "DisplayWall Ground floor", "bbpav02.epfl.ch" }, + { "DisplayWall 5th floor", "bbpav05.epfl.ch" }, + { "DisplayWall 6th floor", "bbpav06.epfl.ch" } +}; MainWindow::MainWindow() : _stream( 0 ) - , _desktopSelectionWindow( new DesktopSelectionWindow( )) - , _x( 0 ) - , _y( 0 ) - , _width( 0 ) - , _height( 0 ) + , _cursor( QImage( CURSOR_IMAGE_FILE ).scaled( + CURSOR_IMAGE_SIZE * devicePixelRatio(), + CURSOR_IMAGE_SIZE * devicePixelRatio(), Qt::KeepAspectRatio )) #ifdef DEFLECT_USE_SERVUS , _servus( deflect::Server::serviceName ) #endif { - _generateCursorImage(); - _setupUI(); - - // Receive changes from the selection rectangle - connect( _desktopSelectionWindow->getSelectionRectangle(), - SIGNAL( coordinatesChanged( QRect )), - this, SLOT( _setCoordinates( QRect ))); - - connect( _desktopSelectionWindow, SIGNAL( windowVisible( bool )), - _showDesktopSelectionWindowAction, SLOT( setChecked( bool ))); -} - -void MainWindow::_generateCursorImage() -{ - _cursor = QImage( CURSOR_IMAGE_FILE ).scaled( 20, 20, Qt::KeepAspectRatio ); -} - -void MainWindow::_setupUI() -{ - QWidget* widget = new QWidget(); - QFormLayout* formLayout = new QFormLayout(); - widget->setLayout( formLayout ); - - setCentralWidget( widget ); + setupUi( this ); - connect( &_xSpinBox, SIGNAL( editingFinished( )), - this, SLOT( _updateCoordinates( ))); - connect( &_ySpinBox, SIGNAL( editingFinished( )), - this, SLOT( _updateCoordinates( ))); - connect( &_widthSpinBox, SIGNAL( editingFinished( )), - this, SLOT( _updateCoordinates( ))); - connect( &_heightSpinBox, SIGNAL( editingFinished( )), - this, SLOT( _updateCoordinates( ))); + connect( _hostnameComboBox, &QComboBox::currentTextChanged, + [&]( const QString& text ) + { _streamButton->setEnabled( !text.isEmpty( )); }); - _hostnameLineEdit.setText( DEFAULT_HOST_ADDRESS ); + for( const auto& entry : defaultHosts ) + _hostnameComboBox->addItem( entry.first, entry.second ); char hostname[256] = { 0 }; gethostname( hostname, 256 ); - _uriLineEdit.setText( hostname ); + _streamnameLineEdit->setText( QString( "Desktop - %1" ).arg( hostname )); - const int screen = -1; - QRect desktopRect = QApplication::desktop()->screenGeometry( screen ); + connect( _desktopInteractionCheckBox, &QCheckBox::clicked, + this, &MainWindow::_onStreamEventsBoxClicked ); - _xSpinBox.setRange( 0, desktopRect.width( )); - _ySpinBox.setRange( 0, desktopRect.height( )); - _widthSpinBox.setRange( 1, desktopRect.width( )); - _heightSpinBox.setRange( 1, desktopRect.height( )); + connect( _streamButton, &QPushButton::clicked, + this, &MainWindow::_shareDesktop ); - // default to full screen - _xSpinBox.setValue( 0 ); - _ySpinBox.setValue( 0 ); - _widthSpinBox.setValue( desktopRect.width( )); - _heightSpinBox.setValue( desktopRect.height( )); - - // call updateCoordinates() to commit coordinates from the UI - _updateCoordinates(); - - // frame rate limiting - _frameRateSpinBox.setRange( 1, 60 ); - _frameRateSpinBox.setValue( 24 ); - - // add widgets to UI - formLayout->addRow( "Hostname", &_hostnameLineEdit ); - formLayout->addRow( "Stream name", &_uriLineEdit ); - formLayout->addRow( "X", &_xSpinBox ); - formLayout->addRow( "Y", &_ySpinBox ); - formLayout->addRow( "Width", &_widthSpinBox ); - formLayout->addRow( "Height", &_heightSpinBox ); -#ifdef STREAM_EVENTS_SUPPORTED - formLayout->addRow( "Allow desktop interaction", &_streamEventsBox ); - _streamEventsBox.setChecked( true ); - connect( &_streamEventsBox, SIGNAL( clicked( bool )), - this, SLOT( _onStreamEventsBoxClicked( bool ))); -#endif - formLayout->addRow( "Max frame rate", &_frameRateSpinBox ); - formLayout->addRow( "Actual frame rate", &_frameRateLabel ); - - // share desktop action - _shareDesktopAction = new QAction( "Share Desktop", this ); - _shareDesktopAction->setStatusTip( "Share desktop" ); - _shareDesktopAction->setCheckable( true ); - _shareDesktopAction->setChecked( false ); - connect( _shareDesktopAction, SIGNAL( triggered( bool )), this, - SLOT( _shareDesktop( bool ))); - connect( this, SIGNAL( streaming( bool )), _shareDesktopAction, - SLOT( setChecked( bool ))); - - // show desktop selection window action - _showDesktopSelectionWindowAction = new QAction( "Show Rectangle", this ); - _showDesktopSelectionWindowAction->setStatusTip( - "Show desktop selection rectangle" ); - _showDesktopSelectionWindowAction->setCheckable( true ); - _showDesktopSelectionWindowAction->setChecked( false ); - connect( _showDesktopSelectionWindowAction, SIGNAL( triggered( bool )), - this, SLOT( _showDesktopSelectionWindow( bool ))); - - QToolBar* toolbar = addToolBar( "toolbar" ); - toolbar->addAction( _shareDesktopAction ); - toolbar->addAction( _showDesktopSelectionWindowAction ); - - // add About dialog - QAction* showAboutDialog = new QAction( "About", this ); - showAboutDialog->setStatusTip( "About DesktopStreamer" ); - connect( showAboutDialog, &QAction::triggered, + connect( _actionAbout, &QAction::triggered, this, &MainWindow::_openAboutWidget ); - QMenu* helpMenu = menuBar()->addMenu( "&Help" ); - helpMenu->addAction( showAboutDialog ); // Update timer - connect( &_updateTimer, SIGNAL( timeout( )), this, SLOT( _update( ))); - -#ifdef DEFLECT_USE_SERVUS - _servus.beginBrowsing( servus::Servus::IF_ALL ); - connect( &_browseTimer, SIGNAL( timeout( )), this, SLOT( _updateServus( ))); - _browseTimer.start( SERVUS_BROWSE_DELAY ); -#endif + connect( &_updateTimer, &QTimer::timeout, this, &MainWindow::_update ); } void MainWindow::_startStreaming() @@ -205,15 +117,20 @@ void MainWindow::_startStreaming() if( _stream ) return; - _stream = new deflect::Stream( _uriLineEdit.text().toStdString(), - _hostnameLineEdit.text().toStdString( )); + QString streamHost = + _hostnameComboBox->currentData().toString(); + if( streamHost.isEmpty( )) + streamHost = _hostnameComboBox->currentData( Qt::DisplayRole ).toString(); + _stream = new deflect::Stream( _streamnameLineEdit->text().toStdString(), + streamHost.toStdString( )); if( !_stream->isConnected( )) { - _handleStreamingError( "Could not connect to host!" ); + _handleStreamingError( "Could not connect to host" ); return; } + #ifdef STREAM_EVENTS_SUPPORTED - if( _streamEventsBox.isChecked( )) + if( _desktopInteractionCheckBox->isChecked( )) _stream->registerForEvents(); #endif @@ -229,7 +146,7 @@ void MainWindow::_startStreaming() void MainWindow::_stopStreaming() { _updateTimer.stop(); - _frameRateLabel.setText( "" ); + _statusbar->clearMessage(); delete _stream; _stream = 0; @@ -237,7 +154,7 @@ void MainWindow::_stopStreaming() #ifdef __APPLE__ _napSuspender.resume(); #endif - emit streaming( false ); + _streamButton->setChecked( false ); } void MainWindow::_handleStreamingError( const QString& errorMessage ) @@ -251,28 +168,10 @@ void MainWindow::_handleStreamingError( const QString& errorMessage ) void MainWindow::closeEvent( QCloseEvent* closeEvt ) { - delete _desktopSelectionWindow; - _desktopSelectionWindow = 0; - _stopStreaming(); - QMainWindow::closeEvent( closeEvt ); } -void MainWindow::_setCoordinates( const QRect coordinates ) -{ - _xSpinBox.setValue( coordinates.x( )); - _ySpinBox.setValue( coordinates.y( )); - _widthSpinBox.setValue( coordinates.width( )); - _heightSpinBox.setValue( coordinates.height( )); - - // the spinboxes only update the UI; we must update the actual values too - _x = _xSpinBox.value(); - _y = _ySpinBox.value(); - _width = _widthSpinBox.value(); - _height = _heightSpinBox.value(); -} - void MainWindow::_shareDesktop( const bool set ) { if( set ) @@ -281,14 +180,6 @@ void MainWindow::_shareDesktop( const bool set ) _stopStreaming(); } -void MainWindow::_showDesktopSelectionWindow( const bool set ) -{ - if( set ) - _desktopSelectionWindow->showFullScreen(); - else - _desktopSelectionWindow->hide(); -} - void MainWindow::_update() { if( _stream->isRegisteredForEvents( )) @@ -303,7 +194,7 @@ void MainWindow::_processStreamEvents() const deflect::Event& wallEvent = _stream->getEvent(); // Once registered for events they must be consumed, otherwise they // queue up. Until unregister is implemented, just ignore them. - if( !_streamEventsBox.checkState( )) + if( !_desktopInteractionCheckBox->checkState( )) break; #ifndef NDEBUG std::cout << "----------" << std::endl; @@ -311,8 +202,7 @@ void MainWindow::_processStreamEvents() switch( wallEvent.type ) { case deflect::Event::EVT_CLOSE: - _stopStreaming(); - break; + return; case deflect::Event::EVT_PRESS: _sendMouseMoveEvent( wallEvent.mouseX, wallEvent.mouseY ); _sendMousePressEvent( wallEvent.mouseX, wallEvent.mouseY ); @@ -343,43 +233,28 @@ void MainWindow::_processStreamEvents() } } -#ifdef DEFLECT_USE_SERVUS -void MainWindow::_updateServus() +void MainWindow::_shareDesktopUpdate() { - if( _hostnameLineEdit.text() != DEFAULT_HOST_ADDRESS ) - { - _browseTimer.stop(); + if( !_stream ) return; - } - _servus.browse( 0 ); - const servus::Strings& hosts = _servus.getInstances(); - if( hosts.empty( )) - return; - - _browseTimer.stop(); - _hostnameLineEdit.setText( _servus.getHost( hosts.front( )).c_str( )); -} -#endif - -void MainWindow::_shareDesktopUpdate() -{ QTime frameTime; frameTime.start(); - const QPixmap desktopPixmap = - QApplication::primaryScreen()->grabWindow( 0, _x, _y, _width, _height ); + const QPixmap pixmap = QApplication::primaryScreen()->grabWindow( 0 ); + _windowRect = QRect( 0, 0, pixmap.width(), pixmap.height( )); - if( desktopPixmap.isNull( )) + if( pixmap.isNull( )) { _handleStreamingError( "Got NULL desktop pixmap" ); return; } - QImage image = desktopPixmap.toImage(); + QImage image = pixmap.toImage(); // render mouse cursor - QPoint mousePos = ( devicePixelRatio() * QCursor::pos() - QPoint( _x, _y )) - - QPoint( _cursor.width() / 2, _cursor.height() / 2 ); + const QPoint mousePos = + ( devicePixelRatio() * QCursor::pos() - _windowRect.topLeft()) - + QPoint( _cursor.width() / 2, _cursor.height() / 2 ); QPainter painter( &image ); painter.drawImage( mousePos, _cursor ); painter.end(); // Make sure to release the QImage before using it @@ -390,7 +265,8 @@ void MainWindow::_shareDesktopUpdate() deflect::BGRA ); deflectImage.compressionPolicy = deflect::COMPRESSION_ON; - bool success = _stream->send( deflectImage ) && _stream->finishFrame(); + const bool success = _stream->send( deflectImage ) && + _stream->finishFrame(); if( !success ) { _handleStreamingError( "Streaming failure, connection closed." ); @@ -403,7 +279,7 @@ void MainWindow::_shareDesktopUpdate() void MainWindow::_regulateFrameRate( const int elapsedFrameTime ) { // frame rate limiting - const int maxFrameRate = _frameRateSpinBox.value(); + const int maxFrameRate = _maxFrameRateSpinBox->value(); const int desiredFrameTime = (int)( 1000.f * 1.f / (float)maxFrameRate ); const int sleepTime = desiredFrameTime - elapsedFrameTime; @@ -429,23 +305,11 @@ void MainWindow::_regulateFrameRate( const int elapsedFrameTime ) const float fps = (float)_frameSentTimes.size() * 1000.f / (float)_frameSentTimes.front().msecsTo( _frameSentTimes.back( )); - _frameRateLabel.setText( QString::number( fps ) + QString( " fps" )); + _statusbar->showMessage( QString( "Streaming to %1@%2 fps" ) + .arg( _hostnameComboBox->currentText( )).arg( fps )); } } -void MainWindow::_updateCoordinates() -{ - _x = _xSpinBox.value(); - _y = _ySpinBox.value(); - _width = _widthSpinBox.value(); - _height = _heightSpinBox.value(); - - _generateCursorImage(); - - const QRect coord( _x, _y, _width, _height ); - _desktopSelectionWindow->getSelectionRectangle()->setCoordinates( coord ); -} - void MainWindow::_onStreamEventsBoxClicked( const bool checked ) { if( !checked ) @@ -481,8 +345,8 @@ void sendMouseEvent( const CGEventType type, const CGMouseButton button, void MainWindow::_sendMousePressEvent( const float x, const float y ) { CGPoint point; - point.x = _x + x * _width; - point.y = _y + y * _height; + point.x = _windowRect.topLeft().x() + x * _windowRect.width(); + point.y = _windowRect.topLeft().y() + y * _windowRect.height(); #ifndef NDEBUG std::cout << "Press " << point.x << ", " << point.y << " (" << x << ", " << y << ")"<< std::endl; @@ -493,8 +357,8 @@ void MainWindow::_sendMousePressEvent( const float x, const float y ) void MainWindow::_sendMouseMoveEvent( const float x, const float y ) { CGPoint point; - point.x = _x + x * _width; - point.y = _y + y * _height; + point.x = _windowRect.topLeft().x() + x * _windowRect.width(); + point.y = _windowRect.topLeft().y() + y * _windowRect.height(); #ifndef NDEBUG std::cout << "Move " << point.x << ", " << point.y << " (" << x << ", " << y << ")"<< std::endl; @@ -505,8 +369,8 @@ void MainWindow::_sendMouseMoveEvent( const float x, const float y ) void MainWindow::_sendMouseReleaseEvent( const float x, const float y ) { CGPoint point; - point.x = _x + x * _width; - point.y = _y + y * _height; + point.x = _windowRect.topLeft().x() + x * _windowRect.width(); + point.y = _windowRect.topLeft().y() + y * _windowRect.height(); #ifndef NDEBUG std::cout << "Release " << point.x << ", " << point.y << " (" << x << ", " << y << ")"<< std::endl; @@ -517,8 +381,8 @@ void MainWindow::_sendMouseReleaseEvent( const float x, const float y ) void MainWindow::_sendMouseDoubleClickEvent( const float x, const float y ) { CGPoint point; - point.x = _x + x * _width; - point.y = _y + y * _height; + point.x = _windowRect.topLeft().x() + x * _windowRect.width(); + point.y = _windowRect.topLeft().y() + y * _windowRect.height(); CGEventRef event = CGEventCreateMouseEvent( 0, kCGEventLeftMouseDown, point, kCGMouseButtonLeft ); #ifndef NDEBUG diff --git a/apps/DesktopStreamer/MainWindow.h b/apps/DesktopStreamer/MainWindow.h index d28b326..57f1370 100644 --- a/apps/DesktopStreamer/MainWindow.h +++ b/apps/DesktopStreamer/MainWindow.h @@ -40,6 +40,7 @@ #define MAIN_WINDOW_H #include +#include #ifdef __APPLE__ # include "AppNapSuspender.h" @@ -49,70 +50,32 @@ # include #endif -#include +#include +#include +#include -class DesktopSelectionWindow; - -class MainWindow : public QMainWindow +class MainWindow : public QMainWindow, public Ui::MainWindow { Q_OBJECT public: MainWindow(); -signals: - void streaming( bool enabled ); - protected: void closeEvent( QCloseEvent* event ) final; private slots: void _shareDesktop( bool set ); - void _showDesktopSelectionWindow( bool set ); - void _update(); -#ifdef DEFLECT_USE_SERVUS - void _updateServus(); -#endif - - void _setCoordinates( QRect coordinates ); - void _updateCoordinates(); - void _onStreamEventsBoxClicked( bool checked ); void _openAboutWidget(); private: deflect::Stream* _stream; - DesktopSelectionWindow* _desktopSelectionWindow; - - /** @name User Interface Elements */ - //@{ - QLineEdit _hostnameLineEdit; - QLineEdit _uriLineEdit; - QSpinBox _xSpinBox; - QSpinBox _ySpinBox; - QSpinBox _widthSpinBox; - QSpinBox _heightSpinBox; - QSpinBox _frameRateSpinBox; - QLabel _frameRateLabel; - QCheckBox _streamEventsBox; - - QAction* _shareDesktopAction; - QAction* _showDesktopSelectionWindowAction; - //@} - - /** @name Status */ - //@{ - int _x; - int _y; - int _width; - int _height; - //@} - QImage _cursor; - QTimer _updateTimer; + QRect _windowRect; // used for frame rate calculations std::vector _frameSentTimes; @@ -125,9 +88,6 @@ private slots: servus::Servus _servus; #endif - void _setupUI(); - void _generateCursorImage(); - void _startStreaming(); void _stopStreaming(); void _handleStreamingError( const QString& errorMessage ); diff --git a/apps/DesktopStreamer/MainWindow.ui b/apps/DesktopStreamer/MainWindow.ui new file mode 100644 index 0000000..affed20 --- /dev/null +++ b/apps/DesktopStreamer/MainWindow.ui @@ -0,0 +1,251 @@ + + + MainWindow + + + + 0 + 0 + 350 + 204 + + + + + 0 + 0 + + + + DesktopStreamer + + + + + 0 + 0 + + + + + QLayout::SetMinimumSize + + + + + QLayout::SetFixedSize + + + QFormLayout::ExpandingFieldsGrow + + + Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter + + + Qt::AlignHCenter|Qt::AlignTop + + + 6 + + + 6 + + + + + Hostname + + + + + + + + 0 + 0 + + + + true + + + true + + + true + + + + + + -1 + + + 5 + + + + + + + Streamname + + + + + + + + 0 + 0 + + + + false + + + + + + + Desktop interaction + + + + + + + true + + + + + + + Max frame rate + + + + + + + + 0 + 0 + + + + fps + + + 1 + + + 60 + + + 24 + + + + + + + + 268 + 40 + + + + false + + + false + + + Stream + + + true + + + false + + + false + + + false + + + false + + + false + + + + + + + + + + + 0 + 0 + 350 + 22 + + + + + Help + + + + + + + + + About + + + + + + + _streamButton + toggled(bool) + _streamnameLineEdit + setDisabled(bool) + + + 147 + 399 + + + 336 + 289 + + + + + _streamButton + toggled(bool) + _hostnameComboBox + setDisabled(bool) + + + 174 + 196 + + + 242 + 54 + + + + + diff --git a/deflect/CMakeLists.txt b/deflect/CMakeLists.txt index 56f1418..2896eb5 100644 --- a/deflect/CMakeLists.txt +++ b/deflect/CMakeLists.txt @@ -87,6 +87,6 @@ endif() common_library(Deflect) -if(Qt5Qml_FOUND AND Qt5Quick_FOUND AND Qt5Quick_VERSION VERSION_GREATER 5.3) +if(Qt5Qml_FOUND AND Qt5Quick_FOUND AND NOT Qt5Quick_VERSION VERSION_LESS 5.4) add_subdirectory(qt) endif() diff --git a/doc/Changelog.md b/doc/Changelog.md index 9fe143a..69a6877 100644 --- a/doc/Changelog.md +++ b/doc/Changelog.md @@ -1,6 +1,12 @@ Changelog {#Changelog} ============ +## Deflect 0.9 (git master) + +* [60](https://github.com/BlueBrain/Deflect/pull/60): + Improved DesktopStreamer: removed selection rectangle, editable list of stream + hostnames + ## Deflect 0.8 ### 0.8.0 (04-11-2015)