renamed files to be conform with the rest of the project

This commit is contained in:
johan 2013-08-13 19:45:17 +02:00
parent 3f4f1eff74
commit 463e7626b9
7 changed files with 22 additions and 25 deletions

View File

@ -2,7 +2,7 @@
# define the minimum cmake version (as required by cmake)
cmake_minimum_required(VERSION 2.8)
set(CMAKE_TOOLCHAIN_FILE /opt/raspberrypi/Toolchain-RaspberryPi.cmake)
#set(CMAKE_TOOLCHAIN_FILE /opt/raspberrypi/Toolchain-RaspberryPi.cmake)
# Define the main-project name
project(Hyperion)

View File

@ -1,4 +1,5 @@
cmake_minimum_required(VERSION 2.8)
project(hyperion-remote)
find_package(Qt4 REQUIRED QtCore QtGui QtNetwork)
@ -11,21 +12,17 @@ LINK_DIRECTORIES(${LINK_DIRECTORIES} ${CMAKE_FIND_ROOT_PATH}/lib/arm-linux-gnuea
include_directories(${QT_INCLUDES})
set(hyperion-remote_HEADERS
specialoptions.h
connection.h
colortransform.h)
CustomParameter.h
Connection.h
ColorTransformValues.h)
set(hyperion-remote_SOURCES
hyperion-remote.cpp
connection.cpp)
qt4_wrap_cpp(HYPERION_REMOTE_MOC_SOURCES
${hyperion-remote_HEADERS})
Connection.cpp)
add_executable(hyperion-remote
${hyperion-remote_HEADERS}
${hyperion-remote_SOURCES}
${HYPERION_REMOTE_MOC_SOURCES})
${hyperion-remote_SOURCES})
qt4_use_modules(hyperion-remote
Core

View File

@ -1,6 +1,6 @@
#pragma once
struct ColorTransform
struct ColorTransformValues
{
double valueRed;
double valueGreen;

View File

@ -1,6 +1,6 @@
#include <stdexcept>
#include "connection.h"
#include "Connection.h"
Connection::Connection(const std::string & a, bool printJson) :
_printJson(printJson),
@ -63,7 +63,7 @@ bool Connection::clearAll()
return false;
}
bool Connection::setTransform(ColorTransform *threshold, ColorTransform *gamma, ColorTransform *blacklevel, ColorTransform *whitelevel)
bool Connection::setTransform(ColorTransformValues *threshold, ColorTransformValues *gamma, ColorTransformValues *blacklevel, ColorTransformValues *whitelevel)
{
std::cout << "Set color transforms" << std::endl;
return false;

View File

@ -8,7 +8,7 @@
#include <json/json.h>
#include "colortransform.h"
#include "ColorTransformValues.h"
class Connection
{
@ -21,7 +21,7 @@ public:
bool listPriorities();
bool clear(int priority);
bool clearAll();
bool setTransform(ColorTransform * threshold, ColorTransform * gamma, ColorTransform * blacklevel, ColorTransform * whitelevel);
bool setTransform(ColorTransformValues * threshold, ColorTransformValues * gamma, ColorTransformValues * blacklevel, ColorTransformValues * whitelevel);
private:
bool sendMessage(const Json::Value & message);

View File

@ -5,11 +5,11 @@
#include <getoptPlusPlus/getoptpp.h>
#include "colortransform.h"
#include "ColorTransformValues.h"
typedef vlofgren::PODParameter<QColor> ColorParameter;
typedef vlofgren::PODParameter<QImage> ImageParameter;
typedef vlofgren::PODParameter<ColorTransform> TransformParameter;
typedef vlofgren::PODParameter<ColorTransformValues> TransformParameter;
namespace vlofgren {
template<>
@ -67,9 +67,9 @@ namespace vlofgren {
}
template<>
ColorTransform TransformParameter::validate(const std::string& s) throw (Parameter::ParameterRejected)
ColorTransformValues TransformParameter::validate(const std::string& s) throw (Parameter::ParameterRejected)
{
ColorTransform transform;
ColorTransformValues transform;
// s should be split in 3 parts
// seperators are either a ',' or a space

View File

@ -4,8 +4,8 @@
#include <getoptPlusPlus/getoptpp.h>
#include "specialoptions.h"
#include "connection.h"
#include "CustomParameter.h"
#include "Connection.h"
using namespace vlofgren;
@ -115,10 +115,10 @@ int main(int argc, char * argv[])
}
else if (colorTransform)
{
ColorTransform threshold = argThreshold.getValue();
ColorTransform gamma = argGamma.getValue();
ColorTransform blacklevel = argBlacklevel.getValue();
ColorTransform whitelevel = argWhitelevel.getValue();
ColorTransformValues threshold = argThreshold.getValue();
ColorTransformValues gamma = argGamma.getValue();
ColorTransformValues blacklevel = argBlacklevel.getValue();
ColorTransformValues whitelevel = argWhitelevel.getValue();
connection.setTransform(
argThreshold.isSet() ? &threshold : nullptr,