- Timestamp:
- Oct 23, 2013, 10:32:21 AM (11 years ago)
- Location:
- trunk/src/PacpusLib
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/PacpusLib/CMakeLists.txt
r182 r185 11 11 create_export(EXPORT_HDR ${PROJECT_NAME} "${PACPUS_INCLUDE_DIR}/Pacpus/kernel") 12 12 13 # ======================================== 14 # Configure qt4 15 # ======================================== 16 #if(QT4_FOUND) 17 # set(QT_USE_QTXML true) 18 # include(${QT_USE_FILE}) 19 #else() 20 # message(ERROR "Qt4 needed") 21 #endif() 22 23 24 # ======================================== 25 # Compiler definitions 26 # ======================================== 13 ################################################################################ 27 14 add_definitions( 28 15 -DQT_NO_KEYWORDS … … 30 17 ) 31 18 32 # ======================================== 33 # Include directories 34 # ======================================== 19 ################################################################################ 20 # INCLUDES 35 21 include_directories( 36 22 ${QT_INCLUDE_DIR} 37 23 ) 38 24 39 # ======================================== 40 # Link directories 41 # ======================================== 25 ################################################################################ 26 # LINK 42 27 link_directories( 43 28 ${PROJECT_BINARY_DIR}/../RoadTime … … 45 30 ) 46 31 47 # ======================================== 48 # List of sources 49 # ======================================== 32 ################################################################################ 33 # FILES 50 34 set(PROJECT_HDRS 51 35 ${EXPORT_HDR} 36 52 37 ${PACPUS_INCLUDE_DIR}/Pacpus/kernel/cstdint.h 53 38 ${PACPUS_INCLUDE_DIR}/Pacpus/kernel/ComponentBase.h … … 89 74 ) 90 75 91 qt_wrap_cpp( 92 PROJECT_MOC_SRCS 93 ${FILES_TO_MOC} 94 ) 95 96 # ======================================== 97 # Build a library 98 # ======================================== 76 qt_wrap_cpp(PROJECT_MOC_SRCS 77 ${FILES_TO_MOC} 78 ) 79 80 ################################################################################ 81 # BUILD AND LINK 99 82 pacpus_add_library(${PROJECT_NAME} SHARED 100 83 ${PROJECT_HDRS} … … 109 92 endif() 110 93 111 # ======================================== 112 # Libraries 113 # ======================================== 94 ################################################################################ 95 # LIBS 114 96 target_link_libraries( 115 97 ${PROJECT_NAME} … … 119 101 ) 120 102 121 # ======================================== 122 # Install 123 # ======================================== 103 ################################################################################ 104 # INSTALL 124 105 pacpus_install(${PROJECT_NAME}) 125 106 126 # ======================================== 127 # Folder 128 # ======================================== 107 ################################################################################ 108 # FOLDER 129 109 pacpus_folder(${PROJECT_NAME} "libraries") -
trunk/src/PacpusLib/ComponentManager.cpp
r184 r185 18 18 19 19 DECLARE_STATIC_LOGGER("pacpus.core.ComponentManager"); 20 21 //////////////////////////////////////////////////////////////////////////////// 22 23 bool connectInterface(OutputInterfaceBase * out, InputInterfaceBase * in, int priority, InputInterfaceBase::ReadingMode mode = InputInterfaceBase::GetLast); 24 25 //////////////////////////////////////////////////////////////////////////////// 26 27 bool connectInterface(OutputInterfaceBase * out, InputInterfaceBase * in, int priority, InputInterfaceBase::ReadingMode mode) 28 { 29 if (out->getDataType() == in->getDataType() || out->getDataType() == QString(typeid(QByteArray).name()) || in->getDataType() == QString(typeid(QByteArray).name())) { 30 // Add connection 31 out->addConnection(ConnectionBase(in, priority)); // TODO make connect function 32 in->addConnection(ConnectionBase(out, priority)); 33 in->setReadingMode(mode); 34 //LOG_INFO("connection : Output " << out->getSignature() << " => Input " << in->getSignature()); 35 return true; 36 } else { 37 //LOG_WARN("connecting " << out->getSignature() << ":" << out->getDataType() << " to " << in->getSignature() << ":" << in->getDataType() << " failled : DataType incompatible " << QString(typeid(QByteArray).name())); 38 return false; 39 } 40 } 41 42 //////////////////////////////////////////////////////////////////////////////// 20 43 21 44 ComponentManager * ComponentManager::mInstance = NULL; -
trunk/src/PacpusLib/InputOutputBase.cpp
r182 r185 97 97 } 98 98 99 const InputInterfaceBase::ReadingMode & InputInterfaceBase:: readingMode() const99 const InputInterfaceBase::ReadingMode & InputInterfaceBase::getReadingMode() const 100 100 { 101 101 return m_readingMode;
Note:
See TracChangeset
for help on using the changeset viewer.