37 changed files with 2474 additions and 29 deletions
-
3.gitignore
-
77Projects/CudaWare_64_DNN_Learning/CudaWare_64_DNN_Learning.cpp
-
3Projects/CudaWare_64_DNN_Learning/CudaWare_64_DNN_Learning.h
-
BINProjects/CudaWare_64_DNN_Learning/CudaWare_64_DNN_Learning.ico
-
151Projects/CudaWare_64_DNN_Learning/CudaWare_64_DNN_Learning.rc
-
232Projects/CudaWare_64_DNN_Learning/CudaWare_64_DNN_Learning.vcxproj
-
363Projects/CudaWare_64_DNN_Learning/CudaWare_64_DNN_Learning.vcxproj.filters
-
4Projects/CudaWare_64_DNN_Learning/CudaWare_64_DNN_Learning.vcxproj.user
-
30Projects/CudaWare_64_DNN_Learning/Resource.h
-
4Projects/CudaWare_64_DNN_Learning/default.conf
-
25Projects/CudaWare_64_DNN_Learning/framework.h
-
BINProjects/CudaWare_64_DNN_Learning/resources.rcc
-
BINProjects/CudaWare_64_DNN_Learning/small.ico
-
6Projects/CudaWare_64_DNN_Learning/targetver.h
-
6Projects/QT-Gui-App/Win32-QT-gui-application_2019.vcxproj.filters
-
8Windows_Workspace_2019 - Home.sln
-
275lib/App/CudaWare_64_DNN_Learning/main_window.cpp
-
88lib/App/CudaWare_64_DNN_Learning/main_window.h
-
262lib/App/CudaWare_64_DNN_Learning/main_window.ui
-
10lib/components/base/basicFunctionality.cpp
-
6lib/components/base/basicLIBAV.h
-
16lib/data/cortex/base/basicCortex.cpp
-
26lib/data/cortex/base/basicLayer.cpp
-
8lib/data/cortex/base/basicLayer.h
-
2lib/data/cortex/base/basicProcessingUnit.h
-
13lib/data/cortex/layers/layersFactory.cpp
-
2lib/data/cortex/layers/layersFactory.h
-
5lib/data/media/video/videoAVLIBSource.cpp
-
2lib/data/storage/storageProvider.h
-
179lib/gui/controls/CortexLayerWidget.cpp
-
56lib/gui/controls/CortexLayerWidget.h
-
323lib/gui/controls/MediaDestWidget.cpp
-
73lib/gui/controls/MediaDestWidget.h
-
2lib/gui/controls/VideoWidget.h
-
11lib/gui/gui.h
-
231lib/resources/cudawork_resources.qrc
-
1lib/resources/make_resource.bat
@ -0,0 +1,77 @@ |
|||||
|
// CudaWare_64_DNN_Learning.cpp : Defines the entry point for the application.
|
||||
|
//
|
||||
|
#include "framework.h"
|
||||
|
#include "CudaWare_64_DNN_Learning.h"
|
||||
|
#include "../../lib/components/object/objectFileLoggingService.h"
|
||||
|
|
||||
|
#define MAX_LOADSTRING 100
|
||||
|
|
||||
|
#define LOG(X) mpLog->Log( "Main", NULL, X )
|
||||
|
#define LOG_DEBUG( X ) mpLog->Log( "Main", NULL, _LOG_DEBUG, X )
|
||||
|
#define LOG_ERROR( X ) mpLog->Log( "Main", NULL, _LOG_ERROR, X )
|
||||
|
|
||||
|
int APIENTRY _tWinMain(_In_ HINSTANCE hInstance, |
||||
|
_In_opt_ HINSTANCE hPrevInstance, |
||||
|
_In_ LPTSTR lpCmdLine, |
||||
|
_In_ int nCmdShow) |
||||
|
{ |
||||
|
UNREFERENCED_PARAMETER(hPrevInstance); |
||||
|
UNREFERENCED_PARAMETER(lpCmdLine); |
||||
|
|
||||
|
// TODO: Place code here.
|
||||
|
guiClass* GUI; |
||||
|
GUI = guiClass::getInstance(); |
||||
|
GUI->init(0, NULL); |
||||
|
|
||||
|
basicLogCollection * mpLog = basicLogCollection::getInstance(); |
||||
|
objectFileLoggingService * fLog; |
||||
|
char tPath[1024]; |
||||
|
char* ttPtz = NULL; |
||||
|
//ttPtz = (char *)GUI->getApp()->applicationDirPath().toStdString().c_str();
|
||||
|
if (ttPtz != NULL) { |
||||
|
sprintf(tPath, "%s/my.log", ttPtz); |
||||
|
} else { |
||||
|
sprintf(tPath, "my.log"); |
||||
|
}; |
||||
|
fLog = new objectFileLoggingService(tPath); |
||||
|
mpLog->addHandler((basicLoggingService*)fLog); |
||||
|
printf("From now - refer to log file\n"); |
||||
|
LOG_DEBUG("ENTER APPLICATION"); |
||||
|
basicSettingsProvider * mpSettingsProvider = basicSettingsProvider::getInstance(); |
||||
|
config_setting_t * mpSettings; |
||||
|
mpSettings = mpSettingsProvider->getSubNode(NULL,(CSTR)"APPLICATION_GUI"); |
||||
|
|
||||
|
mainWinow* window; |
||||
|
window = mainWinow::getInstance(); |
||||
|
|
||||
|
//Check Startup Mode
|
||||
|
int gAppStartupMode; |
||||
|
config_setting_t * pSetting; |
||||
|
|
||||
|
if (!config_setting_lookup_int(mpSettings, "STARTUP_WINDOW_MODE", &gAppStartupMode)) { |
||||
|
gAppStartupMode = 0; |
||||
|
pSetting = config_setting_add(mpSettings, "STARTUP_WINDOW_MODE", CONFIG_TYPE_INT); |
||||
|
config_setting_set_int(pSetting, gAppStartupMode); |
||||
|
mpSettingsProvider->compromise(); |
||||
|
}; |
||||
|
|
||||
|
switch (gAppStartupMode) { |
||||
|
case 0: window->show(); break; |
||||
|
case 1: window->showMaximized(); break; |
||||
|
case 2: window->showFullScreen(); break; |
||||
|
default: |
||||
|
gAppStartupMode = 0; |
||||
|
pSetting = config_setting_lookup(mpSettings, "STARTUP_WINDOW_MODE"); |
||||
|
config_setting_set_int(pSetting, gAppStartupMode); |
||||
|
mpSettingsProvider->compromise(); |
||||
|
window->showMaximized(); |
||||
|
}; |
||||
|
|
||||
|
delete GUI; |
||||
|
delete window; |
||||
|
delete mpSettingsProvider; |
||||
|
|
||||
|
LOG_DEBUG("EXIT APPLICATION"); |
||||
|
delete mpLog; |
||||
|
return 0; |
||||
|
} |
||||
@ -0,0 +1,3 @@ |
|||||
|
#pragma once |
||||
|
|
||||
|
#include "resource.h" |
||||
Binary file not shown.
@ -0,0 +1,151 @@ |
|||||
|
//Microsoft Visual C++ generated resource script. |
||||
|
// |
||||
|
#pragma code_page(65001) |
||||
|
|
||||
|
#include "resource.h" |
||||
|
|
||||
|
#define APSTUDIO_READONLY_SYMBOLS |
||||
|
///////////////////////////////////////////////////////////////////////////// |
||||
|
// |
||||
|
// Generated from the TEXTINCLUDE resource. |
||||
|
// |
||||
|
#ifndef APSTUDIO_INVOKED |
||||
|
#include "targetver.h" |
||||
|
#endif |
||||
|
#define APSTUDIO_HIDDEN_SYMBOLS |
||||
|
#include "windows.h" |
||||
|
#undef APSTUDIO_HIDDEN_SYMBOLS |
||||
|
///////////////////////////////////////////////////////////////////////////// |
||||
|
#undef APSTUDIO_READONLY_SYMBOLS |
||||
|
|
||||
|
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU) |
||||
|
LANGUAGE 9, 1 |
||||
|
|
||||
|
///////////////////////////////////////////////////////////////////////////// |
||||
|
// |
||||
|
// Icon |
||||
|
// |
||||
|
|
||||
|
// Icon with lowest ID value placed first to ensure application icon |
||||
|
// remains consistent on all systems. |
||||
|
|
||||
|
IDI_CUDAWARE64DNNLEARNING ICON "CudaWare_64_DNN_Learning.ico" |
||||
|
IDI_SMALL ICON "small.ico" |
||||
|
|
||||
|
///////////////////////////////////////////////////////////////////////////// |
||||
|
// |
||||
|
// Menu |
||||
|
// |
||||
|
|
||||
|
IDC_CUDAWARE64DNNLEARNING MENU |
||||
|
BEGIN |
||||
|
POPUP "&File" |
||||
|
BEGIN |
||||
|
MENUITEM "E&xit", IDM_EXIT |
||||
|
END |
||||
|
POPUP "&Help" |
||||
|
BEGIN |
||||
|
MENUITEM "&About ...", IDM_ABOUT |
||||
|
END |
||||
|
END |
||||
|
|
||||
|
|
||||
|
///////////////////////////////////////////////////////////////////////////// |
||||
|
// |
||||
|
// Accelerator |
||||
|
// |
||||
|
|
||||
|
IDC_CUDAWARE64DNNLEARNING ACCELERATORS |
||||
|
BEGIN |
||||
|
"?", IDM_ABOUT, ASCII, ALT |
||||
|
"/", IDM_ABOUT, ASCII, ALT |
||||
|
END |
||||
|
|
||||
|
|
||||
|
///////////////////////////////////////////////////////////////////////////// |
||||
|
// |
||||
|
// Dialog |
||||
|
// |
||||
|
|
||||
|
IDD_ABOUTBOX DIALOGEX 0, 0, 170, 62 |
||||
|
STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | WS_SYSMENU |
||||
|
CAPTION "About CudaWare_64_DNN_Learning" |
||||
|
FONT 8, "MS Shell Dlg" |
||||
|
BEGIN |
||||
|
ICON IDR_MAINFRAME,IDC_STATIC,14,14,21,20 |
||||
|
LTEXT "CudaWare_64_DNN_Learning, Version 1.0",IDC_STATIC,42,14,114,8,SS_NOPREFIX |
||||
|
LTEXT "Copyright (c) 2020",IDC_STATIC,42,26,114,8 |
||||
|
DEFPUSHBUTTON "OK",IDOK,113,41,50,14,WS_GROUP |
||||
|
END |
||||
|
|
||||
|
///////////////////////////////////////////////////////////////////////////// |
||||
|
// |
||||
|
// DESIGNINFO |
||||
|
// |
||||
|
|
||||
|
#ifdef APSTUDIO_INVOKED |
||||
|
GUIDELINES DESIGNINFO |
||||
|
BEGIN |
||||
|
IDD_ABOUTBOX, DIALOG |
||||
|
BEGIN |
||||
|
LEFTMARGIN, 7 |
||||
|
RIGHTMARGIN, 163 |
||||
|
TOPMARGIN, 7 |
||||
|
BOTTOMMARGIN, 55 |
||||
|
END |
||||
|
END |
||||
|
#endif // APSTUDIO_INVOKED |
||||
|
|
||||
|
#ifdef APSTUDIO_INVOKED |
||||
|
///////////////////////////////////////////////////////////////////////////// |
||||
|
// |
||||
|
// TEXTINCLUDE |
||||
|
// |
||||
|
1 TEXTINCLUDE |
||||
|
BEGIN |
||||
|
"resource.h\0" |
||||
|
END |
||||
|
|
||||
|
2 TEXTINCLUDE |
||||
|
BEGIN |
||||
|
"#ifndef APSTUDIO_INVOKED\r\n" |
||||
|
"#include ""targetver.h""\r\n" |
||||
|
"#endif\r\n" |
||||
|
"#define APSTUDIO_HIDDEN_SYMBOLS\r\n" |
||||
|
"#include ""windows.h""\r\n" |
||||
|
"#undef APSTUDIO_HIDDEN_SYMBOLS\r\n" |
||||
|
"\0" |
||||
|
END |
||||
|
|
||||
|
3 TEXTINCLUDE |
||||
|
BEGIN |
||||
|
"\r\n" |
||||
|
"\0" |
||||
|
END |
||||
|
|
||||
|
#endif // APSTUDIO_INVOKED |
||||
|
|
||||
|
///////////////////////////////////////////////////////////////////////////// |
||||
|
// |
||||
|
// String Table |
||||
|
// |
||||
|
|
||||
|
STRINGTABLE |
||||
|
BEGIN |
||||
|
IDC_CUDAWARE64DNNLEARNING "CUDAWARE64DNNLEARNING" |
||||
|
IDS_APP_TITLE "CudaWare_64_DNN_Learning" |
||||
|
END |
||||
|
|
||||
|
#endif |
||||
|
///////////////////////////////////////////////////////////////////////////// |
||||
|
|
||||
|
|
||||
|
|
||||
|
#ifndef APSTUDIO_INVOKED |
||||
|
///////////////////////////////////////////////////////////////////////////// |
||||
|
// |
||||
|
// Generated from the TEXTINCLUDE resource. |
||||
|
// |
||||
|
|
||||
|
///////////////////////////////////////////////////////////////////////////// |
||||
|
#endif // not APSTUDIO_INVOKED |
||||
@ -0,0 +1,232 @@ |
|||||
|
<?xml version="1.0" encoding="utf-8"?> |
||||
|
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> |
||||
|
<ItemGroup Label="ProjectConfigurations"> |
||||
|
<ProjectConfiguration Include="Debug|x64"> |
||||
|
<Configuration>Debug</Configuration> |
||||
|
<Platform>x64</Platform> |
||||
|
</ProjectConfiguration> |
||||
|
<ProjectConfiguration Include="Release|x64"> |
||||
|
<Configuration>Release</Configuration> |
||||
|
<Platform>x64</Platform> |
||||
|
</ProjectConfiguration> |
||||
|
</ItemGroup> |
||||
|
<PropertyGroup Label="Globals"> |
||||
|
<VCProjectVersion>16.0</VCProjectVersion> |
||||
|
<ProjectGuid>{C03D51D2-8661-4D85-B159-E0C9E480ED82}</ProjectGuid> |
||||
|
<Keyword>Win32Proj</Keyword> |
||||
|
<RootNamespace>CudaWare64DNNLearning</RootNamespace> |
||||
|
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion> |
||||
|
</PropertyGroup> |
||||
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> |
||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration"> |
||||
|
<ConfigurationType>Application</ConfigurationType> |
||||
|
<UseDebugLibraries>true</UseDebugLibraries> |
||||
|
<PlatformToolset>v142</PlatformToolset> |
||||
|
<CharacterSet> |
||||
|
</CharacterSet> |
||||
|
</PropertyGroup> |
||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration"> |
||||
|
<ConfigurationType>Application</ConfigurationType> |
||||
|
<UseDebugLibraries>false</UseDebugLibraries> |
||||
|
<PlatformToolset>v142</PlatformToolset> |
||||
|
<WholeProgramOptimization>true</WholeProgramOptimization> |
||||
|
<CharacterSet>Unicode</CharacterSet> |
||||
|
</PropertyGroup> |
||||
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" /> |
||||
|
<ImportGroup Label="ExtensionSettings"> |
||||
|
<Import Project="$(VCTargetsPath)\BuildCustomizations\CUDA 10.1.props" /> |
||||
|
</ImportGroup> |
||||
|
<ImportGroup Label="Shared"> |
||||
|
</ImportGroup> |
||||
|
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> |
||||
|
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> |
||||
|
</ImportGroup> |
||||
|
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> |
||||
|
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> |
||||
|
</ImportGroup> |
||||
|
<PropertyGroup Label="UserMacros" /> |
||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> |
||||
|
<LinkIncremental>true</LinkIncremental> |
||||
|
<IncludePath>..\..\lib\App\CudaWare_64_DNN_Learning;C:\LIBS\libconfig-1.5\include;C:\LIBS\Qt\5.12.2\msvc2015_64\include;C:\LIBS\pthreads\include;C:\MS_LIBS\cv3\include;C:\LIBS\ffmpeg\include;C:\LIBS\openssl\include;C:\LIBS\boost_1_72;C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.1\include;$(IncludePath)</IncludePath> |
||||
|
<LibraryPath>C:\LIBS\Qt\5.12.2\msvc2015_64\lib;C:\LIBS\openssl\x64;C:\LIBS\libconfig-1.5\lib\x64;C:\LIBS\ffmpeg\static_lib\debug\x64;C:\LIBS\pthreads\lib\x64;C:\MS_LIBS\cv3\x64\vc12\lib;C:\LIBS\boost_1_72\lib64-msvc-14.2;C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.1\lib\x64;$(LibraryPath)</LibraryPath> |
||||
|
</PropertyGroup> |
||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> |
||||
|
<LinkIncremental>false</LinkIncremental> |
||||
|
<IncludePath>C:\LIBS\libconfig-1.5\include;C:\LIBS\Qt\5.12.2\msvc2015_64\include;C:\LIBS\pthreads\include;$(IncludePath)</IncludePath> |
||||
|
</PropertyGroup> |
||||
|
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> |
||||
|
<ClCompile> |
||||
|
<PrecompiledHeader> |
||||
|
</PrecompiledHeader> |
||||
|
<WarningLevel>Level3</WarningLevel> |
||||
|
<Optimization>Disabled</Optimization> |
||||
|
<PreprocessorDefinitions>_OPENCV_;_CLIENT_APPLICATION_;__GUI__;WITH_OPENSSL;WIN_XP;WIN32;PTW32_STATIC_LIB;_TIMESPEC_DEFINED;GPU;VC_EXTRALEAN;WIN32_LEAN_AND_MEAN;__STDC_FORMAT_MACROS;DEBUG;HAVE_STRUCT_TIMESPEC;__STDC_LIMIT_MACROS;__STDC_CONSTANT_MACROS;_CRT_SECURE_NO_WARNINGS;CURL_STATICLIB;OPENCV;__SSE2__;VL_DISABLE_AVX;VL_EMBED_INCODE;WITH_PURE_VIRTUAL;_DEBUG;_WINDOWS;%(PreprocessorDefinitions)</PreprocessorDefinitions> |
||||
|
<ConformanceMode>true</ConformanceMode> |
||||
|
<MultiProcessorCompilation>true</MultiProcessorCompilation> |
||||
|
<BufferSecurityCheck>false</BufferSecurityCheck> |
||||
|
<EnableParallelCodeGeneration>true</EnableParallelCodeGeneration> |
||||
|
<OpenMPSupport>true</OpenMPSupport> |
||||
|
<AdditionalOptions>/bigobj /Zc:twoPhase- /Zc:strictStrings- %(AdditionalOptions)</AdditionalOptions> |
||||
|
<SDLCheck>false</SDLCheck> |
||||
|
</ClCompile> |
||||
|
<Link> |
||||
|
<SubSystem>Windows</SubSystem> |
||||
|
<GenerateDebugInformation>true</GenerateDebugInformation> |
||||
|
<EntryPointSymbol>WinMainCRTStartup</EntryPointSymbol> |
||||
|
<AdditionalDependencies>cublas.lib;cublasLt.lib;cuda.lib;cudadevrt.lib;cudart.lib;cudart_static.lib;cudnn.lib;cufft.lib;cufftw.lib;curand.lib;cusolver.lib;cusolverMg.lib;cusparse.lib;nppc.lib;nppial.lib;nppicc.lib;nppicom.lib;nppidei.lib;nppif.lib;nppig.lib;nppim.lib;nppist.lib;nppisu.lib;nppitc.lib;npps.lib;nvblas.lib;nvcuvid.lib;nvencodeapi.lib;nvgraph.lib;nvjpeg.lib;nvml.lib;nvrtc.lib;OpenCL.lib;opencv_ts300d.lib;opencv_world300d.lib;pthreadVC2.lib;libconfigd.lib;%(AdditionalDependencies)</AdditionalDependencies> |
||||
|
</Link> |
||||
|
</ItemDefinitionGroup> |
||||
|
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> |
||||
|
<ClCompile> |
||||
|
<PrecompiledHeader> |
||||
|
</PrecompiledHeader> |
||||
|
<WarningLevel>Level3</WarningLevel> |
||||
|
<Optimization>MaxSpeed</Optimization> |
||||
|
<FunctionLevelLinking>true</FunctionLevelLinking> |
||||
|
<IntrinsicFunctions>true</IntrinsicFunctions> |
||||
|
<SDLCheck>true</SDLCheck> |
||||
|
<PreprocessorDefinitions>NDEBUG;_WINDOWS;%(PreprocessorDefinitions)</PreprocessorDefinitions> |
||||
|
<ConformanceMode>true</ConformanceMode> |
||||
|
</ClCompile> |
||||
|
<Link> |
||||
|
<SubSystem>Windows</SubSystem> |
||||
|
<EnableCOMDATFolding>true</EnableCOMDATFolding> |
||||
|
<OptimizeReferences>true</OptimizeReferences> |
||||
|
<GenerateDebugInformation>true</GenerateDebugInformation> |
||||
|
</Link> |
||||
|
</ItemDefinitionGroup> |
||||
|
<ItemGroup> |
||||
|
<ClInclude Include="..\..\lib\App\CudaWare_64_DNN_Learning\main_window.h" /> |
||||
|
<ClInclude Include="..\..\lib\gui\controls\CortexLayerWidget.h" /> |
||||
|
<ClInclude Include="..\..\lib\gui\controls\MediaDestWidget.h" /> |
||||
|
<ClInclude Include="CudaWare_64_DNN_Learning.h" /> |
||||
|
<ClInclude Include="framework.h" /> |
||||
|
<ClInclude Include="Resource.h" /> |
||||
|
<ClInclude Include="targetver.h" /> |
||||
|
</ItemGroup> |
||||
|
<ItemGroup> |
||||
|
<ClCompile Include="..\..\lib\alg\generic\md5.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\App\CudaWare_64_DNN_Learning\main_window.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicDualThread.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicEvent.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicEventHeap.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicFunctionality.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicLIBAV.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicLogCollection.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicLoggingService.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicMutex.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicRing.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicSettings.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicSettingsProvider.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicThread.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\components\object\objectFileLoggingService.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicActivations.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicBox.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicCortex.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicData.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicDataAux.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicImage.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicImageAux.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicList.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicMatrix.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicProcessingUnit.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicTree.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicUtils.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpu.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuActivationLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuAvgpoolLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuBatchnormLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuCalcs.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuConnectedLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuConvolutionalLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuCrnnLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuLocalLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuMakers.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuMaxpoolLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuNormalizationLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuReorgLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuRouteLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuShortcutLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cuda.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaActivationLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaAvgpoolLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaBatchnormLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaConnectedLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaConvolutionalLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaCrnnLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaLocalLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaMaxpoolLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaNormalizationLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaRegionLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaReorgLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaRouteLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaShortcutLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\media\video\videoAVLIBDestination.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\media\video\videoAVLIBSource.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\gui\controls\CortexLayerWidget.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\gui\controls\MediaDestWidget.cpp" /> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\cudaDeconvolutionalLayer.cpp"> |
||||
|
<FileType>Document</FileType> |
||||
|
</CudaCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\activationLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\avgpoolLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\batchnormLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\connectedLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\convolutionalLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\costLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\crnnLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\cropLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\deconvolutionalLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\detectionLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\dropoutLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\gruLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\layersFactory.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\localLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\maxpoolLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\normalizationLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\regionLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\reorgLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\rnnLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\routeLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\shortcutLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\softmaxLayer.cpp" /> |
||||
|
<ClCompile Include="..\..\lib\gui\guiClass.cpp" /> |
||||
|
<ClCompile Include="CudaWare_64_DNN_Learning.cpp" /> |
||||
|
</ItemGroup> |
||||
|
<ItemGroup> |
||||
|
<ResourceCompile Include="CudaWare_64_DNN_Learning.rc" /> |
||||
|
</ItemGroup> |
||||
|
<ItemGroup> |
||||
|
<Image Include="CudaWare_64_DNN_Learning.ico" /> |
||||
|
<Image Include="small.ico" /> |
||||
|
</ItemGroup> |
||||
|
<ItemGroup> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\col2im_kernels.cu"> |
||||
|
<FileType>Document</FileType> |
||||
|
</CudaCompile> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\cuda.cu" /> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\cudaAvgpoolLayer.cu" /> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\cudaCalcs.cu" /> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\cudaCropLayer.cu"> |
||||
|
<FileType>Document</FileType> |
||||
|
</CudaCompile> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\cudaDropoutLayer.cu"> |
||||
|
<FileType>Document</FileType> |
||||
|
</CudaCompile> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\cudaMakers.cu" /> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\cudaMaxpoolLayer.cu"> |
||||
|
<FileType>Document</FileType> |
||||
|
</CudaCompile> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\im2col_kernels.cu"> |
||||
|
<FileType>Document</FileType> |
||||
|
</CudaCompile> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\network_kernels.cu"> |
||||
|
<FileType>Document</FileType> |
||||
|
</CudaCompile> |
||||
|
</ItemGroup> |
||||
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" /> |
||||
|
<ImportGroup Label="ExtensionTargets"> |
||||
|
<Import Project="$(VCTargetsPath)\BuildCustomizations\CUDA 10.1.targets" /> |
||||
|
</ImportGroup> |
||||
|
</Project> |
||||
@ -0,0 +1,363 @@ |
|||||
|
<?xml version="1.0" encoding="utf-8"?> |
||||
|
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> |
||||
|
<ItemGroup> |
||||
|
<Filter Include="Source Files"> |
||||
|
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier> |
||||
|
<Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions> |
||||
|
</Filter> |
||||
|
<Filter Include="Header Files"> |
||||
|
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier> |
||||
|
<Extensions>h;hh;hpp;hxx;hm;inl;inc;ipp;xsd</Extensions> |
||||
|
</Filter> |
||||
|
<Filter Include="Resource Files"> |
||||
|
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier> |
||||
|
<Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions> |
||||
|
</Filter> |
||||
|
<Filter Include="Source Files\CUDA modules"> |
||||
|
<UniqueIdentifier>{24d0217f-3689-464e-9b44-6bb23a1f3a6a}</UniqueIdentifier> |
||||
|
</Filter> |
||||
|
<Filter Include="Source Files\Cortex"> |
||||
|
<UniqueIdentifier>{5f874326-7b83-483f-abc4-95c938074cde}</UniqueIdentifier> |
||||
|
</Filter> |
||||
|
<Filter Include="Source Files\Cortex\Base"> |
||||
|
<UniqueIdentifier>{c5a4982c-a450-4900-9204-215d21b20b16}</UniqueIdentifier> |
||||
|
</Filter> |
||||
|
<Filter Include="Source Files\Cortex\Layers"> |
||||
|
<UniqueIdentifier>{3851e2ef-c28b-4501-bd54-fd46b65be0f3}</UniqueIdentifier> |
||||
|
</Filter> |
||||
|
<Filter Include="Source Files\Cortex\Cuda"> |
||||
|
<UniqueIdentifier>{bfa94e82-d339-4f7f-a68c-86c899fa1841}</UniqueIdentifier> |
||||
|
</Filter> |
||||
|
<Filter Include="Source Files\Cortex\CPU"> |
||||
|
<UniqueIdentifier>{df5e3d18-734d-4e8e-89ee-a54b5b092550}</UniqueIdentifier> |
||||
|
</Filter> |
||||
|
</ItemGroup> |
||||
|
<ItemGroup> |
||||
|
<ClInclude Include="framework.h"> |
||||
|
<Filter>Header Files</Filter> |
||||
|
</ClInclude> |
||||
|
<ClInclude Include="targetver.h"> |
||||
|
<Filter>Header Files</Filter> |
||||
|
</ClInclude> |
||||
|
<ClInclude Include="Resource.h"> |
||||
|
<Filter>Header Files</Filter> |
||||
|
</ClInclude> |
||||
|
<ClInclude Include="CudaWare_64_DNN_Learning.h"> |
||||
|
<Filter>Header Files</Filter> |
||||
|
</ClInclude> |
||||
|
<ClInclude Include="..\..\lib\App\CudaWare_64_DNN_Learning\main_window.h"> |
||||
|
<Filter>Header Files</Filter> |
||||
|
</ClInclude> |
||||
|
<ClInclude Include="..\..\lib\gui\controls\MediaDestWidget.h"> |
||||
|
<Filter>Header Files</Filter> |
||||
|
</ClInclude> |
||||
|
<ClInclude Include="..\..\lib\gui\controls\CortexLayerWidget.h"> |
||||
|
<Filter>Header Files</Filter> |
||||
|
</ClInclude> |
||||
|
</ItemGroup> |
||||
|
<ItemGroup> |
||||
|
<ClCompile Include="CudaWare_64_DNN_Learning.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\App\CudaWare_64_DNN_Learning\main_window.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicFunctionality.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicSettings.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicSettingsProvider.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicLogCollection.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicRing.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicEventHeap.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicEvent.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicLIBAV.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicLoggingService.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicMutex.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicThread.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\components\base\basicDualThread.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\components\object\objectFileLoggingService.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\gui\guiClass.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicActivations.cpp"> |
||||
|
<Filter>Source Files\Cortex\Base</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicBox.cpp"> |
||||
|
<Filter>Source Files\Cortex\Base</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicCortex.cpp"> |
||||
|
<Filter>Source Files\Cortex\Base</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicData.cpp"> |
||||
|
<Filter>Source Files\Cortex\Base</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicDataAux.cpp"> |
||||
|
<Filter>Source Files\Cortex\Base</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicImage.cpp"> |
||||
|
<Filter>Source Files\Cortex\Base</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicImageAux.cpp"> |
||||
|
<Filter>Source Files\Cortex\Base</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Base</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicList.cpp"> |
||||
|
<Filter>Source Files\Cortex\Base</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicMatrix.cpp"> |
||||
|
<Filter>Source Files\Cortex\Base</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicProcessingUnit.cpp"> |
||||
|
<Filter>Source Files\Cortex\Base</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicTree.cpp"> |
||||
|
<Filter>Source Files\Cortex\Base</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\base\basicUtils.cpp"> |
||||
|
<Filter>Source Files\Cortex\Base</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\activationLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\avgpoolLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\batchnormLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\connectedLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\convolutionalLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\costLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\crnnLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\cropLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\deconvolutionalLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\detectionLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\dropoutLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\gruLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\layersFactory.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\localLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\maxpoolLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\normalizationLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\regionLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\reorgLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\rnnLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\routeLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\shortcutLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\layers\softmaxLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Layers</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cuda.cpp"> |
||||
|
<Filter>Source Files\Cortex\Cuda</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaActivationLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Cuda</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaAvgpoolLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Cuda</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaBatchnormLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Cuda</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaConnectedLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Cuda</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaConvolutionalLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Cuda</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaCrnnLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Cuda</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaLocalLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Cuda</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaMaxpoolLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Cuda</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaNormalizationLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Cuda</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaRegionLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Cuda</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaReorgLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Cuda</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaRouteLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Cuda</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cuda\cudaShortcutLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Cuda</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpu.cpp"> |
||||
|
<Filter>Source Files\Cortex\CPU</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuActivationLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\CPU</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuAvgpoolLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\CPU</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuBatchnormLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\CPU</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuCalcs.cpp"> |
||||
|
<Filter>Source Files\Cortex\CPU</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuConnectedLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\CPU</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuConvolutionalLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\CPU</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuCrnnLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\CPU</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuLocalLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\CPU</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuMakers.cpp"> |
||||
|
<Filter>Source Files\Cortex\CPU</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuMaxpoolLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\CPU</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuNormalizationLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\CPU</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuReorgLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\CPU</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuRouteLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\CPU</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\cortex\cpu\cpuShortcutLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\CPU</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\gui\controls\MediaDestWidget.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\media\video\videoAVLIBSource.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\data\media\video\videoAVLIBDestination.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\alg\generic\md5.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
<ClCompile Include="..\..\lib\gui\controls\CortexLayerWidget.cpp"> |
||||
|
<Filter>Source Files</Filter> |
||||
|
</ClCompile> |
||||
|
</ItemGroup> |
||||
|
<ItemGroup> |
||||
|
<ResourceCompile Include="CudaWare_64_DNN_Learning.rc"> |
||||
|
<Filter>Resource Files</Filter> |
||||
|
</ResourceCompile> |
||||
|
</ItemGroup> |
||||
|
<ItemGroup> |
||||
|
<Image Include="small.ico"> |
||||
|
<Filter>Resource Files</Filter> |
||||
|
</Image> |
||||
|
<Image Include="CudaWare_64_DNN_Learning.ico"> |
||||
|
<Filter>Resource Files</Filter> |
||||
|
</Image> |
||||
|
</ItemGroup> |
||||
|
<ItemGroup> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\col2im_kernels.cu"> |
||||
|
<Filter>Source Files\CUDA modules</Filter> |
||||
|
</CudaCompile> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\cudaCropLayer.cu"> |
||||
|
<Filter>Source Files\CUDA modules</Filter> |
||||
|
</CudaCompile> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\cuda.cu"> |
||||
|
<Filter>Source Files\CUDA modules</Filter> |
||||
|
</CudaCompile> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\cudaAvgpoolLayer.cu"> |
||||
|
<Filter>Source Files\CUDA modules</Filter> |
||||
|
</CudaCompile> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\cudaCalcs.cu"> |
||||
|
<Filter>Source Files\CUDA modules</Filter> |
||||
|
</CudaCompile> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\cudaMakers.cu"> |
||||
|
<Filter>Source Files\CUDA modules</Filter> |
||||
|
</CudaCompile> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\cudaDropoutLayer.cu"> |
||||
|
<Filter>Source Files\CUDA modules</Filter> |
||||
|
</CudaCompile> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\im2col_kernels.cu"> |
||||
|
<Filter>Source Files\CUDA modules</Filter> |
||||
|
</CudaCompile> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\cudaMaxpoolLayer.cu"> |
||||
|
<Filter>Source Files\CUDA modules</Filter> |
||||
|
</CudaCompile> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\network_kernels.cu"> |
||||
|
<Filter>Source Files\CUDA modules</Filter> |
||||
|
</CudaCompile> |
||||
|
<CudaCompile Include="..\..\lib\data\cortex\cuda\cudaDeconvolutionalLayer.cpp"> |
||||
|
<Filter>Source Files\Cortex\Cuda</Filter> |
||||
|
</CudaCompile> |
||||
|
</ItemGroup> |
||||
|
</Project> |
||||
@ -0,0 +1,4 @@ |
|||||
|
<?xml version="1.0" encoding="utf-8"?> |
||||
|
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> |
||||
|
<PropertyGroup /> |
||||
|
</Project> |
||||
@ -0,0 +1,30 @@ |
|||||
|
//{{NO_DEPENDENCIES}} |
||||
|
// Microsoft Visual C++ generated include file. |
||||
|
// Used by CudaWare_64_DNN_Learning.rc |
||||
|
|
||||
|
#define IDS_APP_TITLE 103 |
||||
|
|
||||
|
#define IDR_MAINFRAME 128 |
||||
|
#define IDD_CUDAWARE64DNNLEARNING_DIALOG 102 |
||||
|
#define IDD_ABOUTBOX 103 |
||||
|
#define IDM_ABOUT 104 |
||||
|
#define IDM_EXIT 105 |
||||
|
#define IDI_CUDAWARE64DNNLEARNING 107 |
||||
|
#define IDI_SMALL 108 |
||||
|
#define IDC_CUDAWARE64DNNLEARNING 109 |
||||
|
#define IDC_MYICON 2 |
||||
|
#ifndef IDC_STATIC |
||||
|
#define IDC_STATIC -1 |
||||
|
#endif |
||||
|
// Next default values for new objects |
||||
|
// |
||||
|
#ifdef APSTUDIO_INVOKED |
||||
|
#ifndef APSTUDIO_READONLY_SYMBOLS |
||||
|
|
||||
|
#define _APS_NO_MFC 130 |
||||
|
#define _APS_NEXT_RESOURCE_VALUE 129 |
||||
|
#define _APS_NEXT_COMMAND_VALUE 32771 |
||||
|
#define _APS_NEXT_CONTROL_VALUE 1000 |
||||
|
#define _APS_NEXT_SYMED_VALUE 110 |
||||
|
#endif |
||||
|
#endif |
||||
@ -0,0 +1,4 @@ |
|||||
|
APPLICATION_GUI : |
||||
|
{ |
||||
|
STARTUP_WINDOW_MODE = 1; |
||||
|
}; |
||||
@ -0,0 +1,25 @@ |
|||||
|
// header.h : include file for standard system include files, |
||||
|
// or project specific include files |
||||
|
// |
||||
|
|
||||
|
#pragma once |
||||
|
#ifndef __linux__ |
||||
|
#include <winsock2.h> |
||||
|
#endif |
||||
|
|
||||
|
#include <stdio.h> |
||||
|
//https://autotire.co.il/%D7%92%D7%A0%D7%98%D7%99%D7%9D-%D7%92%D7%A0%D7%98%D7%99%D7%9D-5x114.3-15 |
||||
|
#ifdef _NO_STDIO_IOB_FUNC_ |
||||
|
extern "C" { FILE __iob_func[3] = { *stdin,*stdout,*stderr }; } |
||||
|
#endif |
||||
|
|
||||
|
#include "main_window.h" |
||||
|
#include "targetver.h" |
||||
|
#define WIN32_LEAN_AND_MEAN // Exclude rarely-used stuff from Windows headers |
||||
|
// Windows Header Files |
||||
|
#include <windows.h> |
||||
|
// C RunTime Header Files |
||||
|
#include <stdlib.h> |
||||
|
#include <malloc.h> |
||||
|
#include <memory.h> |
||||
|
#include <tchar.h> |
||||
Binary file not shown.
Binary file not shown.
@ -0,0 +1,6 @@ |
|||||
|
#pragma once |
||||
|
|
||||
|
// // Including SDKDDKVer.h defines the highest available Windows platform. |
||||
|
// If you wish to build your application for a previous Windows platform, include WinSDKVer.h and |
||||
|
// set the _WIN32_WINNT macro to the platform you wish to support before including SDKDDKVer.h. |
||||
|
#include <SDKDDKVer.h> |
||||
@ -0,0 +1,275 @@ |
|||||
|
#include "main_window.h"
|
||||
|
|
||||
|
mainWinow* mainWinow::_instance = 0; |
||||
|
|
||||
|
void mainWinow::changeEvent(QEvent *event){ |
||||
|
if(event->type() == QEvent::WindowStateChange ){ |
||||
|
if (!isMinimized()) { |
||||
|
setAttribute(Qt::WA_Mapped); |
||||
|
}; |
||||
|
}; |
||||
|
}; |
||||
|
|
||||
|
mainWinow::mainWinow() : QMainWindow(){ |
||||
|
m_pSettings = basicSettingsProvider::getInstance()->getSubNode(NULL, (CSTR)"APPLICATION_GUI"); |
||||
|
m_pFactory = cortexLayersFactory::getInstance(); |
||||
|
m_pCortex = NULL; |
||||
|
m_bChangesAreSaved = true; |
||||
|
m_pMainWidget = new QWidget( NULL ); |
||||
|
m_pMainWidget->setObjectName("m_pMainWidget"); |
||||
|
setCentralWidget( m_pMainWidget ); |
||||
|
QVBoxLayout* layout = new QVBoxLayout; |
||||
|
layout->setContentsMargins(5, 5, 5, 5); |
||||
|
|
||||
|
//m_pMainWidget->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
|
||||
|
|
||||
|
m_pLayerTable = new QTableWidget( this ); |
||||
|
m_pLayerTable->setColumnCount( 5 ); |
||||
|
m_pLayerTable->setSortingEnabled( false ); |
||||
|
m_pLayerTable->setSelectionMode( QAbstractItemView::SingleSelection ); |
||||
|
m_pLayerTable->setSelectionBehavior( QAbstractItemView::SelectRows ); |
||||
|
m_pLayerTable->setGridStyle( Qt::DashLine ); |
||||
|
m_pLayerTable->setCornerButtonEnabled( true ); |
||||
|
layout->addWidget(m_pLayerTable); |
||||
|
|
||||
|
QTableWidgetItem* __qtablewidgetitem; |
||||
|
__qtablewidgetitem = new QTableWidgetItem(); |
||||
|
__qtablewidgetitem->setText("Type"); |
||||
|
m_pLayerTable->setHorizontalHeaderItem( 0, __qtablewidgetitem ); |
||||
|
__qtablewidgetitem = new QTableWidgetItem(); |
||||
|
__qtablewidgetitem->setText("Filter"); |
||||
|
m_pLayerTable->setHorizontalHeaderItem( 1, __qtablewidgetitem ); |
||||
|
__qtablewidgetitem = new QTableWidgetItem(); |
||||
|
__qtablewidgetitem->setText("FIlter Size"); |
||||
|
m_pLayerTable->setHorizontalHeaderItem( 2, __qtablewidgetitem ); |
||||
|
__qtablewidgetitem = new QTableWidgetItem(); |
||||
|
__qtablewidgetitem->setText("Input"); |
||||
|
m_pLayerTable->setHorizontalHeaderItem( 3, __qtablewidgetitem ); |
||||
|
__qtablewidgetitem = new QTableWidgetItem(); |
||||
|
__qtablewidgetitem->setText("Output"); |
||||
|
m_pLayerTable->setHorizontalHeaderItem( 4, __qtablewidgetitem ); |
||||
|
|
||||
|
connect(m_pLayerTable, &QTableWidget::cellClicked, this, &mainWinow::selectLayerRow ); |
||||
|
|
||||
|
|
||||
|
QHBoxLayout* hlayout = new QHBoxLayout; |
||||
|
hlayout->setContentsMargins(5, 5, 5, 5); |
||||
|
|
||||
|
m_pTabWidget = new QTabWidget( this ); |
||||
|
m_pTabWidget->setObjectName( "m_pTabWidget" ); |
||||
|
|
||||
|
m_pTabLayerVisual = new QWidget(); |
||||
|
m_pTabLayerVisual->setObjectName("m_pTabLayerVisual"); |
||||
|
QHBoxLayout* hlayout1 = new QHBoxLayout; |
||||
|
hlayout1->setContentsMargins(5, 5, 5, 5); |
||||
|
m_pLayerPreview = new CortexLayerWidget( m_pTabLayerVisual ); |
||||
|
if( m_pLayerPreview->init() ){ |
||||
|
|
||||
|
}; |
||||
|
hlayout1->addWidget(m_pLayerPreview); |
||||
|
m_pTabLayerVisual->setLayout(hlayout1); |
||||
|
|
||||
|
|
||||
|
m_pTabWidget->addTab(m_pTabLayerVisual, "Layer Visual"); |
||||
|
|
||||
|
m_pTabCategories = new QWidget(); |
||||
|
m_pTabCategories->setObjectName("m_pTabCategories"); |
||||
|
m_pTabWidget->addTab(m_pTabCategories, "Classes"); |
||||
|
|
||||
|
m_pTabLearning = new QWidget(); |
||||
|
m_pTabLearning->setObjectName("m_pTabLearning"); |
||||
|
m_pTabWidget->addTab(m_pTabLearning, "Learning"); |
||||
|
|
||||
|
m_pTabInput = new QWidget(); |
||||
|
m_pTabInput->setObjectName("m_pTabInput"); |
||||
|
QHBoxLayout* hlayout2 = new QHBoxLayout; |
||||
|
hlayout2->setContentsMargins(5, 5, 5, 5); |
||||
|
m_pInputStream = new MediaDestWidget( m_pTabInput ); |
||||
|
if( m_pInputStream->init() ){ |
||||
|
m_pAVLIBSource = new videoAVLIBSource(); |
||||
|
if (m_pAVLIBSource != NULL) { |
||||
|
if( m_pAVLIBSource->_open("C:\\KeepVid Pro Downloaded\\The Renter.mp4") ){ |
||||
|
m_pAVLIBSource->attachDestination(m_pInputStream); |
||||
|
}; |
||||
|
}; |
||||
|
}; |
||||
|
hlayout2->addWidget(m_pInputStream); |
||||
|
m_pTabInput->setLayout(hlayout2); |
||||
|
|
||||
|
m_pTabWidget->addTab(m_pTabInput, "Input"); |
||||
|
|
||||
|
m_pTabOutput = new QWidget(); |
||||
|
m_pTabOutput->setObjectName("m_pTabOutput"); |
||||
|
m_pOutputStream = new MediaDestWidget( m_pTabOutput ); |
||||
|
m_pOutputStream->init(); |
||||
|
|
||||
|
m_pTabWidget->addTab(m_pTabOutput, "Output"); |
||||
|
|
||||
|
m_pTabProcessingUnits = new QWidget(); |
||||
|
m_pTabProcessingUnits->setObjectName("m_pTabProcessingUnits"); |
||||
|
m_pTabWidget->addTab(m_pTabProcessingUnits, "Processing Unit"); |
||||
|
|
||||
|
|
||||
|
hlayout->addWidget(m_pTabWidget); |
||||
|
layout->addItem( hlayout ); |
||||
|
|
||||
|
m_pMainWidget->setLayout(layout); |
||||
|
|
||||
|
|
||||
|
|
||||
|
setObjectName("Mainwindow"); |
||||
|
/* Menu Things */ |
||||
|
actionNew_Network = new QAction( QIcon(":/general/file.png"), "&New", this ); |
||||
|
actionNew_Network->setShortcuts(QKeySequence::New); |
||||
|
actionNew_Network->setStatusTip(tr("Create a new Network")); |
||||
|
connect( actionNew_Network, &QAction::triggered, this, &mainWinow::newNetwork ); |
||||
|
|
||||
|
actionOpen = new QAction( QIcon(":/layout/PNG/layout/049.png"), "&Open", this ); |
||||
|
actionOpen->setShortcuts(QKeySequence::Open); |
||||
|
actionOpen->setStatusTip(tr("Open Network Config")); |
||||
|
connect( actionOpen, &QAction::triggered, this, &mainWinow::open ); |
||||
|
|
||||
|
actionSave = new QAction( QIcon(":/layout/PNG/layout/048.png"), "&Save", this ); |
||||
|
actionSave->setShortcuts(QKeySequence::Save); |
||||
|
actionSave->setStatusTip(tr("Save Network Config")); |
||||
|
connect(actionSave, &QAction::triggered, this, &mainWinow::save); |
||||
|
|
||||
|
actionSave_As = new QAction( QIcon(":/layout/PNG/layout/048.png"), "Save &As", this ); |
||||
|
actionSave_As->setShortcuts(QKeySequence::SaveAs); |
||||
|
actionSave_As->setStatusTip(tr("Save Network Config in Another File")); |
||||
|
connect(actionSave_As, &QAction::triggered, this, &mainWinow::saveAs); |
||||
|
|
||||
|
actionExit = new QAction( QIcon(":/layout/PNG/layout/076.png"), "&Exit", this); |
||||
|
actionExit->setShortcuts(QKeySequence::Close); |
||||
|
actionExit->setStatusTip(tr("Exit Application")); |
||||
|
connect(actionExit, &QAction::triggered, this, &mainWinow::exitApp); |
||||
|
|
||||
|
menuFile = menuBar()->addMenu(QIcon(":/menu/PNG/devices/008.png"),"&File"); |
||||
|
menuFile->setObjectName("menuFile"); |
||||
|
menuFile->addAction(actionNew_Network); |
||||
|
menuFile->addAction(actionOpen); |
||||
|
menuFile->addAction(actionSave); |
||||
|
menuFile->addAction(actionSave_As); |
||||
|
menuFile->addAction(actionExit); |
||||
|
|
||||
|
toolBar = addToolBar("Yoba!"); |
||||
|
toolBar->setObjectName("toolBar"); |
||||
|
toolBar->setOrientation(Qt::Horizontal); |
||||
|
toolBar->setToolButtonStyle(Qt::ToolButtonTextBesideIcon); |
||||
|
toolBar->setFloatable(true); |
||||
|
|
||||
|
tbActionAdd = toolBar->addAction(QIcon(":/layout/PNG/layout/064.png"), "Add Layer"); |
||||
|
tbActionInsert = toolBar->addAction(QIcon(":/layout/PNG/layout/067.png"), "Insert Layer"); |
||||
|
tbActionEdit = toolBar->addAction(QIcon(":/layout/PNG/layout/073.png"), "Edit Layer"); |
||||
|
tbActionEdit->setEnabled(false); |
||||
|
tbActionDelete = toolBar->addAction(QIcon(":/layout/PNG/layout/066.png"), "Delete Layer"); |
||||
|
tbActionDelete->setEnabled(false); |
||||
|
toolBar->addSeparator(); |
||||
|
tbActionLoadWeights = toolBar->addAction(QIcon(":/layout/PNG/layout/024.png"), "Load Weights"); |
||||
|
tbActionLoadWeights->setEnabled(false); |
||||
|
|
||||
|
insertToolBarBreak(toolBar); |
||||
|
statusBar()->showMessage("Init Done."); |
||||
|
|
||||
|
setWindowTitle(tr("Neural Network Manager")); |
||||
|
setMinimumSize(160, 160); |
||||
|
}; |
||||
|
|
||||
|
mainWinow::~mainWinow(){ |
||||
|
if (m_pAVLIBSource != NULL) { |
||||
|
m_pAVLIBSource->_stop(); |
||||
|
delete(m_pAVLIBSource); |
||||
|
}; |
||||
|
}; |
||||
|
|
||||
|
/**
|
||||
|
* Returns the single instance of the object. |
||||
|
*/ |
||||
|
mainWinow* mainWinow::getInstance() { |
||||
|
// check if the instance has been created yet
|
||||
|
if (0 == _instance){ |
||||
|
// if not, then create it
|
||||
|
_instance = new mainWinow(); |
||||
|
}; |
||||
|
// return the single instance
|
||||
|
return _instance; |
||||
|
}; |
||||
|
|
||||
|
void mainWinow::newNetwork(){ |
||||
|
if (m_pFactory != NULL) { |
||||
|
m_pFactory->cleanFactory(); |
||||
|
}; |
||||
|
}; |
||||
|
|
||||
|
void mainWinow::open(){ |
||||
|
QString fileName; |
||||
|
fileName = QFileDialog::getOpenFileName(this, "Open Data", "data/", "Data Files (*.cfg *.raw *.jpg *.bmp)"); |
||||
|
char fName[MAX_PATH]; |
||||
|
sprintf( fName, "%s", fileName.toStdString().c_str() ); |
||||
|
if( strlen(fName) ){ |
||||
|
char tBuff[1024]; |
||||
|
sprintf(tBuff, "Neural Network Manager: %s", fName ); |
||||
|
setWindowTitle(tBuff); |
||||
|
if (m_pCortex != NULL) { |
||||
|
for (uint32_t index = m_pLayerTable->rowCount(); index > -1; index-- ) m_pLayerTable->removeRow(index); |
||||
|
delete(m_pCortex); |
||||
|
m_pCortex = NULL; |
||||
|
}; |
||||
|
m_pCortex = m_pFactory->parseConfig(fName); |
||||
|
if( m_pCortex!= NULL ) { |
||||
|
for( uint32_t index = 0; index < m_pCortex->getLayersCount(); index++ ){ |
||||
|
char tBuff[256]; |
||||
|
m_pLayerTable->insertRow(index); |
||||
|
QTableWidgetItem * __qtablewidgetitem; |
||||
|
__qtablewidgetitem = new QTableWidgetItem(); |
||||
|
__qtablewidgetitem->setText( m_pCortex->getLayer(index)->getString() ); |
||||
|
m_pLayerTable->setItem( index, 0, __qtablewidgetitem ); |
||||
|
__qtablewidgetitem = new QTableWidgetItem(); |
||||
|
sprintf(tBuff, "%dx%dx%d", m_pCortex->getLayer(index)->getInputSizeWidth(), m_pCortex->getLayer(index)->getInputSizeHeight(), m_pCortex->getLayer(index)->getInputSizeChannels() ); |
||||
|
__qtablewidgetitem->setText(tBuff ); |
||||
|
m_pLayerTable->setItem(index, 3, __qtablewidgetitem); |
||||
|
__qtablewidgetitem = new QTableWidgetItem(); |
||||
|
sprintf(tBuff, "%dx%dx%d", m_pCortex->getLayer(index)->getOutputSizeWidth(), m_pCortex->getLayer(index)->getOutputSizeHeight(), m_pCortex->getLayer(index)->getOutputSizeChannels()); |
||||
|
__qtablewidgetitem->setText(tBuff); |
||||
|
m_pLayerTable->setItem(index, 4, __qtablewidgetitem); |
||||
|
}; |
||||
|
tbActionLoadWeights->setEnabled(true); |
||||
|
}; |
||||
|
}; |
||||
|
}; |
||||
|
|
||||
|
void mainWinow::save(){ |
||||
|
m_bChangesAreSaved = true; |
||||
|
}; |
||||
|
|
||||
|
void mainWinow::saveAs(){ |
||||
|
QString fileName; |
||||
|
fileName = QFileDialog::getSaveFileName(this, "Save Data As ...", "data/", "Data Files (*.raw *.jpg *.bmp)"); |
||||
|
m_bChangesAreSaved = true; |
||||
|
}; |
||||
|
|
||||
|
void mainWinow::exitApp() { |
||||
|
if (m_bChangesAreSaved) { |
||||
|
QApplication::quit(); |
||||
|
} else { |
||||
|
QMessageBox::StandardButton reply; |
||||
|
reply = QMessageBox::question( this, "Unsaved Data", "Are you sure to Quit?", QMessageBox::Yes | QMessageBox::No); |
||||
|
if( reply == QMessageBox::Yes ){ |
||||
|
QApplication::quit(); |
||||
|
}; |
||||
|
}; |
||||
|
}; |
||||
|
|
||||
|
void mainWinow::contextMenuEvent(QContextMenuEvent* event){ |
||||
|
QMenu menu(this); |
||||
|
//menu.addAction(cutAct);
|
||||
|
//menu.addAction(copyAct);
|
||||
|
//menu.addAction(pasteAct);
|
||||
|
menu.exec(event->globalPos()); |
||||
|
}; |
||||
|
|
||||
|
void mainWinow::selectLayerRow( int row, int col ){ |
||||
|
tbActionEdit->setEnabled(true); |
||||
|
tbActionDelete->setEnabled(true); |
||||
|
m_pLayerPreview->attachCortexLayer(m_pCortex->getLayer(row)); |
||||
|
}; |
||||
@ -0,0 +1,88 @@ |
|||||
|
#ifndef __QT5_MAIN_WINDOW_HEADER__ |
||||
|
#define __QT5_MAIN_WINDOW_HEADER__ |
||||
|
|
||||
|
#ifndef __linux__ |
||||
|
#include <WinSock2.h> |
||||
|
#endif |
||||
|
|
||||
|
#include "../../components/base/basicSettingsProvider.h" |
||||
|
#include "../../gui/guiClass.h" |
||||
|
#include "../../data/cortex/layers/layersFactory.h" |
||||
|
#include "../../data/media/video/videoAVLIBSource.h" |
||||
|
#include "../../gui/controls/MediaDestWidget.h" |
||||
|
#include "../../gui/controls/CortexLayerWidget.h" |
||||
|
|
||||
|
class mainWinow : public QMainWindow{ |
||||
|
//Q_OBJECT |
||||
|
private: |
||||
|
config_setting_t * m_pSettings; |
||||
|
QWidget * m_pMainWidget; |
||||
|
bool m_bChangesAreSaved; |
||||
|
cortexLayersFactory * m_pFactory; |
||||
|
basicCortex * m_pCortex; |
||||
|
QTableWidget * m_pLayerTable; |
||||
|
QTabWidget * m_pTabWidget; |
||||
|
QWidget * m_pTabProcessingUnits; |
||||
|
QWidget * m_pTabNetworkStageVisual; |
||||
|
QWidget * m_pTabLayerVisual; |
||||
|
QWidget * m_pTabCategories; |
||||
|
QWidget * m_pTabLearning; |
||||
|
QWidget * m_pTabInput; |
||||
|
QWidget * m_pTabOutput; |
||||
|
videoAVLIBSource * m_pAVLIBSource; |
||||
|
MediaDestWidget * m_pInputStream; |
||||
|
MediaDestWidget * m_pOutputStream; |
||||
|
CortexLayerWidget * m_pLayerPreview; |
||||
|
void * m_pInputImage; |
||||
|
|
||||
|
private slots: |
||||
|
void newNetwork(); |
||||
|
void open(); |
||||
|
void save(); |
||||
|
void saveAs(); |
||||
|
void exitApp(); |
||||
|
void selectLayerRow( int, int ); |
||||
|
public: |
||||
|
QAction * actionNew_Network; |
||||
|
QAction * actionOpen; |
||||
|
QAction * actionSave; |
||||
|
QAction * actionSave_As; |
||||
|
QAction * actionExit; |
||||
|
|
||||
|
QAction * tbActionInsert; |
||||
|
QAction * tbActionAdd; |
||||
|
QAction * tbActionEdit; |
||||
|
QAction * tbActionDelete; |
||||
|
QAction * tbActionLoadWeights; |
||||
|
|
||||
|
QMenu * menuFile; |
||||
|
QToolBar * toolBar; |
||||
|
// Method to fetch singleton instance. |
||||
|
static mainWinow * getInstance(); |
||||
|
// Destructor |
||||
|
virtual ~mainWinow(); |
||||
|
protected: |
||||
|
mainWinow(); |
||||
|
void changeEvent(QEvent *event); |
||||
|
void contextMenuEvent(QContextMenuEvent* event) override; |
||||
|
private: |
||||
|
// private static member referencing the single instance of the object |
||||
|
// TODO: Replace basicLogCollection with the type of object you want to |
||||
|
// return the single instance of |
||||
|
static mainWinow* _instance; |
||||
|
|
||||
|
// Copy constructor |
||||
|
// Declared but not defined to prevent auto-generated |
||||
|
// copy constructor. Refer to "Effective C++" by Meyers |
||||
|
mainWinow(const mainWinow& src); |
||||
|
|
||||
|
// Assignment operator |
||||
|
// Declared but not defined to prevent auto-generated |
||||
|
// assignment operator. Refer to "Effective C++" by Meyers |
||||
|
mainWinow& operator=(const mainWinow& src); |
||||
|
public slots: |
||||
|
// void callbackSettings(void); |
||||
|
// void callbackClear(void); |
||||
|
}; |
||||
|
|
||||
|
#endif |
||||
@ -0,0 +1,262 @@ |
|||||
|
<?xml version="1.0" encoding="UTF-8"?> |
||||
|
<ui version="4.0"> |
||||
|
<class>MainWindow</class> |
||||
|
<widget class="QMainWindow" name="MainWindow"> |
||||
|
<property name="geometry"> |
||||
|
<rect> |
||||
|
<x>0</x> |
||||
|
<y>0</y> |
||||
|
<width>794</width> |
||||
|
<height>604</height> |
||||
|
</rect> |
||||
|
</property> |
||||
|
<property name="windowTitle"> |
||||
|
<string>MainWindow</string> |
||||
|
</property> |
||||
|
<widget class="QWidget" name="centralwidget"> |
||||
|
<widget class="QWidget" name="verticalLayoutWidget"> |
||||
|
<property name="geometry"> |
||||
|
<rect> |
||||
|
<x>0</x> |
||||
|
<y>0</y> |
||||
|
<width>791</width> |
||||
|
<height>561</height> |
||||
|
</rect> |
||||
|
</property> |
||||
|
<layout class="QVBoxLayout" name="verticalLayout"> |
||||
|
<item> |
||||
|
<layout class="QHBoxLayout" name="horizontalLayout"> |
||||
|
<item> |
||||
|
<widget class="QListWidget" name="listWidget"> |
||||
|
<item> |
||||
|
<property name="text"> |
||||
|
<string>koko</string> |
||||
|
</property> |
||||
|
</item> |
||||
|
<item> |
||||
|
<property name="text"> |
||||
|
<string>kokol</string> |
||||
|
</property> |
||||
|
</item> |
||||
|
</widget> |
||||
|
</item> |
||||
|
<item> |
||||
|
<layout class="QVBoxLayout" name="verticalLayout_2"> |
||||
|
<item> |
||||
|
<widget class="QPushButton" name="pushButton"> |
||||
|
<property name="text"> |
||||
|
<string>PushButton</string> |
||||
|
</property> |
||||
|
</widget> |
||||
|
</item> |
||||
|
<item> |
||||
|
<spacer name="verticalSpacer"> |
||||
|
<property name="orientation"> |
||||
|
<enum>Qt::Vertical</enum> |
||||
|
</property> |
||||
|
<property name="sizeHint" stdset="0"> |
||||
|
<size> |
||||
|
<width>20</width> |
||||
|
<height>40</height> |
||||
|
</size> |
||||
|
</property> |
||||
|
</spacer> |
||||
|
</item> |
||||
|
</layout> |
||||
|
</item> |
||||
|
</layout> |
||||
|
</item> |
||||
|
<item> |
||||
|
<widget class="QTabWidget" name="tabWidget"> |
||||
|
<property name="currentIndex"> |
||||
|
<number>0</number> |
||||
|
</property> |
||||
|
<widget class="QWidget" name="tab"> |
||||
|
<attribute name="title"> |
||||
|
<string>Tab 1</string> |
||||
|
</attribute> |
||||
|
<widget class="QTableWidget" name="tableWidget"> |
||||
|
<property name="geometry"> |
||||
|
<rect> |
||||
|
<x>20</x> |
||||
|
<y>10</y> |
||||
|
<width>321</width> |
||||
|
<height>211</height> |
||||
|
</rect> |
||||
|
</property> |
||||
|
<property name="selectionMode"> |
||||
|
<enum>QAbstractItemView::SingleSelection</enum> |
||||
|
</property> |
||||
|
<property name="selectionBehavior"> |
||||
|
<enum>QAbstractItemView::SelectRows</enum> |
||||
|
</property> |
||||
|
<property name="gridStyle"> |
||||
|
<enum>Qt::DashLine</enum> |
||||
|
</property> |
||||
|
<property name="cornerButtonEnabled"> |
||||
|
<bool>true</bool> |
||||
|
</property> |
||||
|
<row> |
||||
|
<property name="text"> |
||||
|
<string>1</string> |
||||
|
</property> |
||||
|
</row> |
||||
|
<row> |
||||
|
<property name="text"> |
||||
|
<string>2</string> |
||||
|
</property> |
||||
|
</row> |
||||
|
<column> |
||||
|
<property name="text"> |
||||
|
<string>kaka</string> |
||||
|
</property> |
||||
|
</column> |
||||
|
<column> |
||||
|
<property name="text"> |
||||
|
<string>Maka</string> |
||||
|
</property> |
||||
|
</column> |
||||
|
<column> |
||||
|
<property name="text"> |
||||
|
<string>Baka</string> |
||||
|
</property> |
||||
|
</column> |
||||
|
<item row="0" column="0"> |
||||
|
<property name="text"> |
||||
|
<string>11</string> |
||||
|
</property> |
||||
|
</item> |
||||
|
<item row="0" column="1"> |
||||
|
<property name="text"> |
||||
|
<string>22</string> |
||||
|
</property> |
||||
|
</item> |
||||
|
<item row="0" column="2"> |
||||
|
<property name="text"> |
||||
|
<string>33</string> |
||||
|
</property> |
||||
|
</item> |
||||
|
<item row="1" column="0"> |
||||
|
<property name="text"> |
||||
|
<string>22</string> |
||||
|
</property> |
||||
|
</item> |
||||
|
<item row="1" column="1"> |
||||
|
<property name="text"> |
||||
|
<string>33</string> |
||||
|
</property> |
||||
|
</item> |
||||
|
<item row="1" column="2"> |
||||
|
<property name="text"> |
||||
|
<string>44</string> |
||||
|
</property> |
||||
|
</item> |
||||
|
</widget> |
||||
|
</widget> |
||||
|
<widget class="QWidget" name="tab_2"> |
||||
|
<attribute name="title"> |
||||
|
<string>Tab 2</string> |
||||
|
</attribute> |
||||
|
</widget> |
||||
|
</widget> |
||||
|
</item> |
||||
|
</layout> |
||||
|
</widget> |
||||
|
</widget> |
||||
|
<widget class="QMenuBar" name="menubar"> |
||||
|
<property name="geometry"> |
||||
|
<rect> |
||||
|
<x>0</x> |
||||
|
<y>0</y> |
||||
|
<width>794</width> |
||||
|
<height>21</height> |
||||
|
</rect> |
||||
|
</property> |
||||
|
<widget class="QMenu" name="menuFile"> |
||||
|
<property name="title"> |
||||
|
<string>File</string> |
||||
|
</property> |
||||
|
<addaction name="actionNew_Network"/> |
||||
|
<addaction name="actionOpen"/> |
||||
|
<addaction name="actionSave"/> |
||||
|
<addaction name="actionSave_As"/> |
||||
|
</widget> |
||||
|
<addaction name="menuFile"/> |
||||
|
</widget> |
||||
|
<widget class="QStatusBar" name="statusbar"/> |
||||
|
<widget class="QToolBar" name="toolBar"> |
||||
|
<property name="windowTitle"> |
||||
|
<string>toolBar</string> |
||||
|
</property> |
||||
|
<property name="orientation"> |
||||
|
<enum>Qt::Horizontal</enum> |
||||
|
</property> |
||||
|
<property name="floatable"> |
||||
|
<bool>true</bool> |
||||
|
</property> |
||||
|
<attribute name="toolBarArea"> |
||||
|
<enum>TopToolBarArea</enum> |
||||
|
</attribute> |
||||
|
<attribute name="toolBarBreak"> |
||||
|
<bool>true</bool> |
||||
|
</attribute> |
||||
|
</widget> |
||||
|
<action name="actionNew_Network"> |
||||
|
<property name="text"> |
||||
|
<string>New Network</string> |
||||
|
</property> |
||||
|
</action> |
||||
|
<action name="actionOpen"> |
||||
|
<property name="text"> |
||||
|
<string>Open</string> |
||||
|
</property> |
||||
|
</action> |
||||
|
<action name="actionSave"> |
||||
|
<property name="text"> |
||||
|
<string>Save</string> |
||||
|
</property> |
||||
|
</action> |
||||
|
<action name="actionSave_As"> |
||||
|
<property name="text"> |
||||
|
<string>Save As</string> |
||||
|
</property> |
||||
|
</action> |
||||
|
</widget> |
||||
|
<resources> |
||||
|
<include location="../../resources/cudawork_resources.qrc"/> |
||||
|
</resources> |
||||
|
<connections> |
||||
|
<connection> |
||||
|
<sender>listWidget</sender> |
||||
|
<signal>clicked(QModelIndex)</signal> |
||||
|
<receiver>MainWindow</receiver> |
||||
|
<slot>close()</slot> |
||||
|
<hints> |
||||
|
<hint type="sourcelabel"> |
||||
|
<x>353</x> |
||||
|
<y>160</y> |
||||
|
</hint> |
||||
|
<hint type="destinationlabel"> |
||||
|
<x>396</x> |
||||
|
<y>301</y> |
||||
|
</hint> |
||||
|
</hints> |
||||
|
</connection> |
||||
|
<connection> |
||||
|
<sender>tableWidget</sender> |
||||
|
<signal>cellClicked(int,int)</signal> |
||||
|
<receiver>MainWindow</receiver> |
||||
|
<slot>show()</slot> |
||||
|
<hints> |
||||
|
<hint type="sourcelabel"> |
||||
|
<x>183</x> |
||||
|
<y>454</y> |
||||
|
</hint> |
||||
|
<hint type="destinationlabel"> |
||||
|
<x>396</x> |
||||
|
<y>301</y> |
||||
|
</hint> |
||||
|
</hints> |
||||
|
</connection> |
||||
|
</connections> |
||||
|
</ui> |
||||
@ -0,0 +1,179 @@ |
|||||
|
#include "CortexLayerWidget.h"
|
||||
|
|
||||
|
#define LOG( X ) m_pLog->Log( "CortexLayerWidget", this, X )
|
||||
|
#define LOG_ERROR( X ) m_pLog->Log( "CortexLayerWidget", this, _LOG_ERROR, X )
|
||||
|
|
||||
|
CortexLayerWidget::CortexLayerWidget(QWidget* parent) : QWidget(parent) { |
||||
|
m_pLog = basicLogCollection::getInstance(); |
||||
|
m_pLayer = NULL; |
||||
|
m_bDirectDrawing = false; |
||||
|
setMinimumSize(QSize(320, 240)); |
||||
|
setSizeIncrement(QSize(20, 20)); |
||||
|
//m_backingStore = new QBackingStore( );
|
||||
|
//setBackgroundRole(QPalette::Window);
|
||||
|
setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding); |
||||
|
setAutoFillBackground(false); |
||||
|
setAttribute(Qt::WA_OpaquePaintEvent); |
||||
|
setCursor(QCursor(Qt::PointingHandCursor)); |
||||
|
m_pPixmap = NULL; |
||||
|
m_pOverlayPixmap = NULL; |
||||
|
m_pGraber = NULL; |
||||
|
m_mFrame = NULL; |
||||
|
m_mOutput = NULL; |
||||
|
m_pTimer = NULL; |
||||
|
m_pPropertiesProtectorMutex = new basicMutex(); |
||||
|
m_pWidgetProtectorMutex = new basicMutex(); |
||||
|
m_pPropertiesProtectorMutex->lock(); |
||||
|
m_pWidgetProtectorMutex->lock(); |
||||
|
}; |
||||
|
|
||||
|
CortexLayerWidget::~CortexLayerWidget() { |
||||
|
|
||||
|
}; |
||||
|
|
||||
|
bool CortexLayerWidget::init(void) { |
||||
|
LOG("init."); |
||||
|
m_pPixmap = new QPixmap(width(), height()); //, QImage::Format_RGB888 );
|
||||
|
if (m_pPixmap == NULL) return false; |
||||
|
m_pOverlayPixmap = new QPixmap(":pictures/43a.png", "PNG"); |
||||
|
m_pTimer = new QTimer(); |
||||
|
if (m_pTimer != NULL) { |
||||
|
QObject::connect(m_pTimer, SIGNAL(timeout()), this, SLOT(update())); |
||||
|
m_pTimer->start(40); |
||||
|
}; |
||||
|
m_pPixmap->fill(Qt::black); |
||||
|
m_pPropertiesProtectorMutex->unlock(); |
||||
|
m_pWidgetProtectorMutex->unlock(); |
||||
|
return true; |
||||
|
}; |
||||
|
|
||||
|
void CortexLayerWidget::renderNow() { |
||||
|
m_pWidgetProtectorMutex->lock(); |
||||
|
try { |
||||
|
QPainter painter(this); |
||||
|
painter.setRenderHint(QPainter::Antialiasing); |
||||
|
render(&painter); |
||||
|
} |
||||
|
catch (std::exception & e) { |
||||
|
LOG_ERROR("RenderNow exception!"); |
||||
|
}; |
||||
|
m_pWidgetProtectorMutex->unlock(); |
||||
|
}; |
||||
|
|
||||
|
void CortexLayerWidget::render(QPainter* painter) { |
||||
|
if (painter != NULL) { |
||||
|
try { |
||||
|
//char buffer[64];
|
||||
|
//sprintf(buffer, "Coords: %dx%d %d %d ? %d %d", pos().x(), pos().y(), width(), height(), m_nMouseX, m_nMouseY);
|
||||
|
painter->save(); |
||||
|
//painter->fillRect(QRect(0, 0, width(), height()), Qt::green);
|
||||
|
QPen BgPen(Qt::SolidPattern, 3); |
||||
|
BgPen.setColor(Qt::black); |
||||
|
//if (m_bErrorMode && m_pOverlayPixmap != NULL) {
|
||||
|
painter->drawPixmap(QRect(0, 0, width(), height()), *m_pOverlayPixmap); |
||||
|
//if (m_pErrorMsg != NULL) {
|
||||
|
//QPen FgPen(Qt::SolidPattern, 0);
|
||||
|
//FgPen.setColor(Qt::yellow);
|
||||
|
//painter->setPen(BgPen);
|
||||
|
//
|
||||
|
//painter->setPen(FgPen);
|
||||
|
//painter->drawText(QRect(0, 0, width(), height()), Qt::AlignHCenter | Qt::AlignBaseline, m_pErrorMsg);
|
||||
|
//};
|
||||
|
//} else {
|
||||
|
painter->drawPixmap(QRect(0, 0, width(), height()), *m_pPixmap); |
||||
|
//};
|
||||
|
//if (m_bSelected) {
|
||||
|
BgPen.setColor(Qt::blue); |
||||
|
painter->setPen(BgPen); |
||||
|
painter->drawRect(QRect(2, 2, width() - 4, height() - 4)); |
||||
|
//};
|
||||
|
//if (m_bMouseActive){
|
||||
|
// if (m_pOverlayPixmap != NULL){
|
||||
|
// painter->drawPixmap(QRect(0, 0, width(), height()), *m_pOverlayPixmap);
|
||||
|
// };
|
||||
|
//};
|
||||
|
|
||||
|
if (m_pLayer != NULL) { |
||||
|
QPen FgPen(Qt::SolidPattern, 0); |
||||
|
FgPen.setColor(Qt::yellow); |
||||
|
painter->setPen(FgPen); |
||||
|
painter->drawText( QRect(0, 0, width(), height()), Qt::AlignHCenter | Qt::AlignBaseline, m_pLayer->getString() ); |
||||
|
switch (m_pLayer->m_eType) { |
||||
|
case CONVOLUTIONAL: |
||||
|
case DECONVOLUTIONAL: |
||||
|
case CONNECTED: |
||||
|
case MAXPOOL: |
||||
|
case SOFTMAX: |
||||
|
case DETECTION: |
||||
|
case DROPOUT: |
||||
|
case CROP: |
||||
|
case ROUTE: |
||||
|
case COST: |
||||
|
case NORMALIZATION: |
||||
|
case AVGPOOL: |
||||
|
case LOCAL: |
||||
|
case SHORTCUT: |
||||
|
case ACTIVE: |
||||
|
case RNN: |
||||
|
case GRU: |
||||
|
case LSTM: |
||||
|
case CRNN: |
||||
|
case BATCHNORM: |
||||
|
case NETWORK: |
||||
|
case XNOR: |
||||
|
case REGION: |
||||
|
case REORG: |
||||
|
case BLANK: |
||||
|
break; |
||||
|
}; |
||||
|
}; |
||||
|
painter->restore(); |
||||
|
} catch (std::exception & e) { |
||||
|
LOG_ERROR("Render exception!"); |
||||
|
}; |
||||
|
}; |
||||
|
}; |
||||
|
|
||||
|
bool CortexLayerWidget::event(QEvent* event) { |
||||
|
/*
|
||||
|
if (event->type() == QEvent::UpdateRequest) { |
||||
|
m_bUpdateIsPending = false; |
||||
|
renderNow(); |
||||
|
return true; |
||||
|
} |
||||
|
if (event->type() == QEvent::MouseButtonRelease) { |
||||
|
//m_bSelected = (m_bSelected) ? false : true;
|
||||
|
if (((QMouseEvent*)event)->button() == Qt::RightButton) { |
||||
|
ShowContextMenu(QPoint(((QMouseEvent*)event)->x(), ((QMouseEvent*)event)->y())); |
||||
|
};// else selected(m_pSignalParameter);
|
||||
|
return true; |
||||
|
} |
||||
|
if (event->type() == QEvent::MouseButtonDblClick) { |
||||
|
m_bEnhanced = (m_bEnhanced) ? false : true; |
||||
|
renderLater(); |
||||
|
return true; |
||||
|
} |
||||
|
if (event->type() == QEvent::MouseMove) { |
||||
|
m_nMouseX = ((QMouseEvent*)event)->x(); |
||||
|
m_nMouseY = ((QMouseEvent*)event)->y(); |
||||
|
m_bMouseActive = true; |
||||
|
m_nMenuActivityCounter = 75;// 3 Sec
|
||||
|
};*/ |
||||
|
return QWidget::event(event); |
||||
|
}; |
||||
|
|
||||
|
void CortexLayerWidget::exposeEvent(QExposeEvent*) { |
||||
|
LOG_ERROR("Expose EVT!"); |
||||
|
}; |
||||
|
|
||||
|
void CortexLayerWidget::paintEvent(QPaintEvent* evt) { |
||||
|
renderNow(); |
||||
|
}; |
||||
|
|
||||
|
void CortexLayerWidget::attachCortexLayer(cortexLayer* L) { |
||||
|
m_pLayer = L; |
||||
|
}; |
||||
|
|
||||
|
#undef LOG
|
||||
|
#undef LOG_ERROR
|
||||
|
|
||||
@ -0,0 +1,56 @@ |
|||||
|
#ifndef __GUI_CORTEX_LAYER_WIDGET__ |
||||
|
#define __GUI_CORTEX_LAYER_WIDGET__ |
||||
|
|
||||
|
#include <opencv2/opencv.hpp> |
||||
|
#include "../../components/base/basicMutex.h" |
||||
|
#include "../../components/base/basicThread.h" |
||||
|
#include "../../data/cortex/base/basicLayer.h" |
||||
|
#include "../guiClass.h" |
||||
|
|
||||
|
class CortexLayerWidget : public QWidget{ |
||||
|
private: |
||||
|
bool m_bDirectDrawing; |
||||
|
|
||||
|
basicLogCollection * m_pLog; |
||||
|
IplImage * m_pGraber; |
||||
|
cv::Mat * m_mFrame; |
||||
|
cv::Mat * m_mOutput; |
||||
|
cortexLayer * m_pLayer; |
||||
|
|
||||
|
//basicVideoSource *m_pCapture; |
||||
|
basicMutex * m_pPropertiesProtectorMutex; |
||||
|
basicMutex * m_pWidgetProtectorMutex; |
||||
|
protected: |
||||
|
QPixmap * m_pPixmap; |
||||
|
QPixmap * m_pOverlayPixmap; |
||||
|
public: |
||||
|
explicit CortexLayerWidget(QWidget* parent = NULL); |
||||
|
~CortexLayerWidget(); |
||||
|
void attachCortexLayer( cortexLayer *L ); |
||||
|
virtual void render(QPainter* painter); |
||||
|
|
||||
|
bool init(void); |
||||
|
signals: |
||||
|
//void selected(void* P); |
||||
|
public slots: |
||||
|
//void setGrayScale(); |
||||
|
//void setEnhanced(); |
||||
|
//void showCameraSettings(); |
||||
|
//void removeThisCamera(); |
||||
|
void renderLater(); |
||||
|
void renderNow(); |
||||
|
//void ShowContextMenu(const QPoint& pos); |
||||
|
protected: |
||||
|
bool event(QEvent* event); |
||||
|
|
||||
|
//void resizeEvent(QResizeEvent *event); |
||||
|
void exposeEvent(QExposeEvent* event); |
||||
|
void paintEvent(QPaintEvent* event); |
||||
|
//void drawContents(QPainter * p, const QRectF & rect = QRectF()); |
||||
|
private: |
||||
|
bool m_bUpdateIsPending; |
||||
|
QTimer * m_pTimer; |
||||
|
}; |
||||
|
|
||||
|
|
||||
|
#endif |
||||
@ -0,0 +1,323 @@ |
|||||
|
#include "MediaDestWidget.h"
|
||||
|
|
||||
|
#define LOG( X ) m_pLog->Log( "MediaDestWidget", this, X )
|
||||
|
#define LOG_ERROR( X ) m_pLog->Log( "MediaDestWidget", this, _LOG_ERROR, X )
|
||||
|
|
||||
|
MediaDestWidget::MediaDestWidget(QWidget *parent) : |
||||
|
QWidget(parent), |
||||
|
basicMediaDestination(){ |
||||
|
m_bGrayScale = false; |
||||
|
m_bEnhanced = false; |
||||
|
m_bDirectDrawing = true; |
||||
|
m_bUpdateIsPending = false; |
||||
|
m_pLog = basicLogCollection::getInstance(); |
||||
|
//setFixedSize( 240, 180 );
|
||||
|
setMouseTracking( true ); |
||||
|
m_eStreamAspectRatio = FAR_UNKNOWN; |
||||
|
m_eWidgetAspectRatio = detectAspectRatio(width(), height()); |
||||
|
//setGeometry(m_nPosX, m_nPosY, m_nWidth+1, m_nHeight+1);
|
||||
|
setMinimumSize(QSize(320, 240)); |
||||
|
setSizeIncrement(QSize(20, 20)); |
||||
|
//m_backingStore = new QBackingStore( );
|
||||
|
//setBackgroundRole(QPalette::Window);
|
||||
|
setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding); |
||||
|
setAutoFillBackground(false); |
||||
|
setAttribute(Qt::WA_OpaquePaintEvent); |
||||
|
setCursor(QCursor(Qt::PointingHandCursor)); |
||||
|
//create();
|
||||
|
|
||||
|
m_pPixmap = NULL; |
||||
|
m_pOverlayPixmap = NULL; |
||||
|
m_pGraber = NULL; |
||||
|
m_mFrame = NULL; |
||||
|
m_mOutput = NULL; |
||||
|
m_pTimer = NULL; |
||||
|
m_bMouseActive = false; |
||||
|
m_bSelected = false; |
||||
|
m_bErrorMode = false; |
||||
|
m_pErrorMsg = NULL; |
||||
|
m_nMouseX = 0; |
||||
|
m_nMouseY = 0; |
||||
|
m_pPropertiesProtectorMutex = new basicMutex(); |
||||
|
m_pWidgetProtectorMutex = new basicMutex(); |
||||
|
m_pPropertiesProtectorMutex->lock(); |
||||
|
m_pWidgetProtectorMutex->lock(); |
||||
|
|
||||
|
//this->setContextMenuPolicy(Qt::CustomContextMenu);
|
||||
|
|
||||
|
//connect(this, SIGNAL(customContextMenuRequested(const QPoint &)),
|
||||
|
// this, SLOT(ShowContextMenu(const QPoint &)));
|
||||
|
}; |
||||
|
|
||||
|
void MediaDestWidget::ShowContextMenu(const QPoint &pos){ |
||||
|
QMenu contextMenu("Context menu", this); |
||||
|
|
||||
|
QAction action1("Togle Enhanced Mode", this); |
||||
|
action1.setIcon(QIcon(":pictures/appbar.candle.png")); |
||||
|
connect(&action1, &QAction::triggered, this, &MediaDestWidget::setEnhanced); |
||||
|
|
||||
|
QAction action2("Togle Video B/W", this); |
||||
|
action2.setIcon(QIcon(":pictures/appbar.alien.png")); |
||||
|
connect(&action2, &QAction::triggered, this, &MediaDestWidget::setGrayScale); |
||||
|
|
||||
|
QAction action3("Camera Settings", this); |
||||
|
action3.setIcon(QIcon(":pictures/appbar.cog.png")); |
||||
|
connect(&action3, &QAction::triggered, this, &MediaDestWidget::showCameraSettings); |
||||
|
|
||||
|
QAction action4("Remove Camera", this); |
||||
|
action4.setIcon(QIcon(":pictures/appbar.close.png")); |
||||
|
connect(&action4, &QAction::triggered, this, &MediaDestWidget::removeThisCamera); |
||||
|
|
||||
|
contextMenu.addAction(&action1); |
||||
|
contextMenu.addAction(&action2); |
||||
|
contextMenu.addAction(&action3); |
||||
|
contextMenu.addAction(&action4); |
||||
|
contextMenu.exec(mapToGlobal(pos)); |
||||
|
}; |
||||
|
|
||||
|
bool MediaDestWidget::event(QEvent *event){ |
||||
|
if (event->type() == QEvent::UpdateRequest){ |
||||
|
m_bUpdateIsPending = false; |
||||
|
renderNow(); |
||||
|
return true; |
||||
|
} |
||||
|
if (event->type() == QEvent::MouseButtonRelease){ |
||||
|
//m_bSelected = (m_bSelected) ? false : true;
|
||||
|
if (((QMouseEvent*)event)->button() == Qt::RightButton){ |
||||
|
ShowContextMenu(QPoint(((QMouseEvent*)event)->x(), ((QMouseEvent*)event)->y())); |
||||
|
};// else selected(m_pSignalParameter);
|
||||
|
return true; |
||||
|
} |
||||
|
if (event->type() == QEvent::MouseButtonDblClick){ |
||||
|
m_bEnhanced = (m_bEnhanced) ? false : true; |
||||
|
renderLater(); |
||||
|
return true; |
||||
|
} |
||||
|
if (event->type() == QEvent::MouseMove){ |
||||
|
m_nMouseX = ((QMouseEvent*)event)->x(); |
||||
|
m_nMouseY = ((QMouseEvent*)event)->y(); |
||||
|
m_bMouseActive = true; |
||||
|
m_nMenuActivityCounter = 75;// 3 Sec
|
||||
|
}; |
||||
|
return QWidget::event(event); |
||||
|
} |
||||
|
//! [7]
|
||||
|
|
||||
|
//! [6]
|
||||
|
void MediaDestWidget::renderLater(){ |
||||
|
if (!m_bUpdateIsPending) { |
||||
|
m_bUpdateIsPending = true; |
||||
|
QCoreApplication::postEvent(this, new QEvent(QEvent::UpdateRequest)); |
||||
|
LOG("Delayed Rendering Request"); |
||||
|
} |
||||
|
} |
||||
|
//! [6]
|
||||
|
|
||||
|
|
||||
|
//! [5]
|
||||
|
//void VideoWidget::resizeEvent(QResizeEvent *resizeEvent){
|
||||
|
// //m_backingStore->resize(resizeEvent->size());
|
||||
|
// this->backingStore()->resize(resizeEvent->size());
|
||||
|
// if( this->isEnabled() )
|
||||
|
// renderNow();
|
||||
|
//}
|
||||
|
//! [5]
|
||||
|
|
||||
|
//! [2]
|
||||
|
void MediaDestWidget::selected(void *P){ |
||||
|
//((VideoSourceChooser*)m_pParent)->selectForMainPreview(P);
|
||||
|
}; |
||||
|
void MediaDestWidget::exposeEvent(QExposeEvent *){ |
||||
|
LOG_ERROR("Expose EVT!"); |
||||
|
} |
||||
|
//! [2]
|
||||
|
|
||||
|
void MediaDestWidget::paintEvent(QPaintEvent *evt){ |
||||
|
renderNow(); |
||||
|
} |
||||
|
|
||||
|
//! [3]
|
||||
|
void MediaDestWidget::renderNow(){ |
||||
|
m_pWidgetProtectorMutex->lock(); |
||||
|
try{ |
||||
|
//if (m_nMenuActivityCounter)m_nMenuActivityCounter--;
|
||||
|
//else if (m_bMouseActive)m_bMouseActive = false;
|
||||
|
|
||||
|
QPainter painter(this); |
||||
|
painter.setRenderHint(QPainter::Antialiasing); |
||||
|
//painter.begin(this);
|
||||
|
render(&painter); |
||||
|
//painter.end();
|
||||
|
}catch (std::exception& e){ |
||||
|
LOG_ERROR("RenderNow exception!"); |
||||
|
}; |
||||
|
m_pWidgetProtectorMutex->unlock(); |
||||
|
} |
||||
|
//! [3]
|
||||
|
|
||||
|
//! [4]
|
||||
|
|
||||
|
void MediaDestWidget::render(QPainter *painter){ |
||||
|
if( painter != NULL ){ |
||||
|
try{ |
||||
|
//char buffer[64];
|
||||
|
//sprintf(buffer, "Coords: %dx%d %d %d ? %d %d", pos().x(), pos().y(), width(), height(), m_nMouseX, m_nMouseY);
|
||||
|
painter->save(); |
||||
|
//painter->fillRect(QRect(0, 0, width(), height()), Qt::green);
|
||||
|
QPen BgPen(Qt::SolidPattern, 3); |
||||
|
BgPen.setColor(Qt::black); |
||||
|
if( m_bErrorMode && m_pOverlayPixmap!= NULL ){ |
||||
|
painter->drawPixmap(QRect(0, 0, width(), height()), *m_pOverlayPixmap); |
||||
|
if (m_pErrorMsg != NULL){ |
||||
|
QPen FgPen(Qt::SolidPattern, 0); |
||||
|
FgPen.setColor(Qt::yellow); |
||||
|
painter->setPen(BgPen); |
||||
|
painter->drawText(QRect(0, 0, width(), height()), Qt::AlignHCenter | Qt::AlignBaseline, m_pErrorMsg); |
||||
|
painter->setPen(FgPen); |
||||
|
painter->drawText(QRect(0, 0, width(), height()), Qt::AlignHCenter | Qt::AlignBaseline, m_pErrorMsg); |
||||
|
}; |
||||
|
} else { |
||||
|
painter->drawPixmap(QRect(0, 0, width(), height()), *m_pPixmap); |
||||
|
}; |
||||
|
if (m_bSelected){ |
||||
|
BgPen.setColor(Qt::blue); |
||||
|
painter->setPen(BgPen); |
||||
|
painter->drawRect(QRect(2, 2, width() - 4, height() - 4)); |
||||
|
}; |
||||
|
//if (m_bMouseActive){
|
||||
|
// if (m_pOverlayPixmap != NULL){
|
||||
|
// painter->drawPixmap(QRect(0, 0, width(), height()), *m_pOverlayPixmap);
|
||||
|
// };
|
||||
|
//};
|
||||
|
painter->restore(); |
||||
|
}catch (std::exception& e){ |
||||
|
LOG_ERROR("Render exception!"); |
||||
|
}; |
||||
|
}; |
||||
|
} |
||||
|
|
||||
|
|
||||
|
bool MediaDestWidget::init( void ){ |
||||
|
m_pPixmap = new QPixmap(width(), height()); //, QImage::Format_RGB888 );
|
||||
|
if( m_pPixmap==NULL ) return false; |
||||
|
m_pOverlayPixmap = new QPixmap(":pictures/43a.png", "PNG"); |
||||
|
m_pTimer = new QTimer(); |
||||
|
if (m_pTimer != NULL){ |
||||
|
QObject::connect(m_pTimer, SIGNAL(timeout()), this, SLOT( update())); |
||||
|
//connect( m_pTimer, &QTimer::timeout, this, &QWidget::update );
|
||||
|
m_pTimer->start(40); |
||||
|
}; |
||||
|
m_pPixmap->fill(Qt::black); |
||||
|
m_pPropertiesProtectorMutex->unlock(); |
||||
|
m_pWidgetProtectorMutex->unlock(); |
||||
|
return true; |
||||
|
}; |
||||
|
|
||||
|
MediaDestWidget::~MediaDestWidget(){ |
||||
|
if (m_pTimer){ |
||||
|
m_pTimer->stop(); |
||||
|
delete(m_pTimer); |
||||
|
}; |
||||
|
delete( m_pPropertiesProtectorMutex ); |
||||
|
delete( m_pWidgetProtectorMutex ); |
||||
|
}; |
||||
|
|
||||
|
void MediaDestWidget::setGrayScale(){ |
||||
|
m_pPropertiesProtectorMutex->lock(); |
||||
|
m_bGrayScale = (m_bGrayScale) ? false : true; |
||||
|
m_pPropertiesProtectorMutex->unlock(); |
||||
|
}; |
||||
|
|
||||
|
void MediaDestWidget::setEnhanced(){ |
||||
|
m_pPropertiesProtectorMutex->lock(); |
||||
|
m_bEnhanced = (m_bEnhanced) ? false : true; |
||||
|
m_pPropertiesProtectorMutex->unlock(); |
||||
|
}; |
||||
|
|
||||
|
void MediaDestWidget::setError(bool AAA, CSTR Message){ |
||||
|
m_bErrorMode = AAA; |
||||
|
m_pErrorMsg = Message; |
||||
|
if (AAA) LOG("ERROR TRUE"); else LOG("ERROR FALSE"); |
||||
|
}; |
||||
|
|
||||
|
void MediaDestWidget::pushFrame(cv::Mat *Frame, void *src){ |
||||
|
if (Frame != NULL && m_pPixmap!= NULL){ |
||||
|
m_pPropertiesProtectorMutex->lock(); |
||||
|
m_eStreamAspectRatio = detectAspectRatio(Frame->cols, Frame->rows); |
||||
|
if (m_bGrayScale) { |
||||
|
cvtColor(*Frame, *Frame, CV_BGR2GRAY); |
||||
|
}; |
||||
|
if (m_bEnhanced) { |
||||
|
if (!m_bGrayScale) { |
||||
|
vector<cv::Mat> channels; |
||||
|
cv::Mat img_hist_equalized; |
||||
|
cvtColor(*Frame, img_hist_equalized, CV_BGR2YCrCb); //change the color image from BGR to YCrCb format
|
||||
|
cv::split(img_hist_equalized, channels); //split the image into channels
|
||||
|
cv::equalizeHist(channels[0], channels[0]); //equalize histogram on the 1st channel (Y)
|
||||
|
merge(channels, img_hist_equalized); //merge 3 channels including the modified 1st channel into one image
|
||||
|
cvtColor(img_hist_equalized, *Frame, CV_YCrCb2BGR); //change the color image from YCrCb to BGR format (to display image properly)
|
||||
|
} else { |
||||
|
equalizeHist(*Frame, *Frame); |
||||
|
}; |
||||
|
}; |
||||
|
if (!m_bGrayScale){ |
||||
|
cvtColor(*Frame, *Frame, CV_BGR2RGB); |
||||
|
} else { |
||||
|
cvtColor(*Frame, *Frame, CV_GRAY2RGB); |
||||
|
}; |
||||
|
m_pPropertiesProtectorMutex->unlock(); |
||||
|
m_mOutput = Frame; |
||||
|
try{ |
||||
|
assert(m_mOutput->isContinuous()); |
||||
|
m_pWidgetProtectorMutex->lock(); |
||||
|
assert(m_pPixmap); |
||||
|
QPainter dbPainter(m_pPixmap); |
||||
|
if (m_eStreamAspectRatio != m_eWidgetAspectRatio){ |
||||
|
int tOffset; |
||||
|
if (m_eStreamAspectRatio > m_eWidgetAspectRatio){ |
||||
|
int tHeight; |
||||
|
tHeight = (int)((float)m_pPixmap->width() / m_eStreamAspectRatio); |
||||
|
tOffset = (m_pPixmap->height() - tHeight) >> 1; |
||||
|
dbPainter.drawImage(QRect(0, tOffset, width(), tHeight), |
||||
|
QImage((unsigned char*)m_mOutput->data, m_mOutput->cols, m_mOutput->rows, QImage::Format_RGB888), |
||||
|
QRect(0, 0, m_mOutput->cols, m_mOutput->rows)); |
||||
|
} else { |
||||
|
int tWidth; |
||||
|
tWidth = (int)((float)m_pPixmap->height() * m_eStreamAspectRatio); |
||||
|
tOffset = (m_pPixmap->width() - tWidth) >> 1; |
||||
|
dbPainter.drawImage(QRect(tOffset, 0, tWidth, height()), |
||||
|
QImage((unsigned char*)m_mOutput->data, m_mOutput->cols, m_mOutput->rows, QImage::Format_RGB888), |
||||
|
QRect(0, 0, m_mOutput->cols, m_mOutput->rows)); |
||||
|
}; |
||||
|
} else { |
||||
|
dbPainter.drawImage(QRect(0, 0, width(), height()), QImage((unsigned char*)m_mOutput->data, m_mOutput->cols, m_mOutput->rows, QImage::Format_RGB888), QRect(0, 0, m_mOutput->cols, m_mOutput->rows)); |
||||
|
}; |
||||
|
m_pWidgetProtectorMutex->unlock(); |
||||
|
} catch (std::exception& e){ |
||||
|
LOG_ERROR("Exception catched:"); |
||||
|
LOG_ERROR(e.what()); |
||||
|
}; |
||||
|
//delete(Frame);
|
||||
|
}; |
||||
|
}; |
||||
|
|
||||
|
void MediaDestWidget::showCameraSettings(){ |
||||
|
//if (m_pSettingsDialog == NULL){
|
||||
|
// m_pSettingsDialog = new DialogSettingsCamera(this);
|
||||
|
//}
|
||||
|
//m_pSettingsDialog->attachDevice( m_pSignalParameter );
|
||||
|
//m_pSettingsDialog->show();
|
||||
|
}; |
||||
|
|
||||
|
void MediaDestWidget::removeThisCamera(){ |
||||
|
//if( m_pParent != NULL ){
|
||||
|
// if (m_pSignalParameter != NULL){
|
||||
|
// m_pParent->removeCamera(m_pSignalParameter);
|
||||
|
// };
|
||||
|
//};
|
||||
|
}; |
||||
|
|
||||
|
|
||||
|
#undef LOG
|
||||
|
#undef LOG_ERROR
|
||||
|
|
||||
@ -0,0 +1,73 @@ |
|||||
|
#ifndef __GUI_MEDIA_DESTINATION_WIDGET__ |
||||
|
#define __GUI_MEDIA_DESTINATION_WIDGET__ |
||||
|
|
||||
|
#include <opencv2/opencv.hpp> |
||||
|
#include "../../components/base/basicMutex.h" |
||||
|
#include "../../components/base/basicMediaDestination.h" |
||||
|
#include "../../components/base/basicLIBAV.h" |
||||
|
#include "../guiClass.h" |
||||
|
|
||||
|
class MediaDestWidget : public QWidget, public basicMediaDestination { |
||||
|
private: |
||||
|
U8 m_bStatus; |
||||
|
int m_nMouseX; |
||||
|
int m_nMouseY; |
||||
|
bool m_bMouseActive; |
||||
|
bool m_bSelected; |
||||
|
int m_nMenuActivityCounter; |
||||
|
bool m_bGrayScale; |
||||
|
bool m_bEnhanced; |
||||
|
bool m_bErrorMode; |
||||
|
CSTR m_pErrorMsg; |
||||
|
bool m_bDirectDrawing; |
||||
|
|
||||
|
FrameAspectRatio m_eWidgetAspectRatio; |
||||
|
FrameAspectRatio m_eStreamAspectRatio; |
||||
|
|
||||
|
basicLogCollection* m_pLog; |
||||
|
IplImage* m_pGraber; |
||||
|
cv::Mat* m_mFrame; |
||||
|
cv::Mat* m_mOutput; |
||||
|
|
||||
|
//basicVideoSource *m_pCapture; |
||||
|
basicMutex* m_pPropertiesProtectorMutex; |
||||
|
basicMutex* m_pWidgetProtectorMutex; |
||||
|
//void m_fThreadProc(void); |
||||
|
|
||||
|
protected: |
||||
|
QPixmap* m_pPixmap; |
||||
|
QPixmap* m_pOverlayPixmap; |
||||
|
public: |
||||
|
explicit MediaDestWidget(QWidget* parent = NULL); |
||||
|
~MediaDestWidget(); |
||||
|
|
||||
|
virtual void render(QPainter* painter); |
||||
|
|
||||
|
bool init(void); |
||||
|
virtual void pushFrame(cv::Mat* Frame, void* src = NULL); |
||||
|
void setSourceType(int Type); |
||||
|
void setError(bool AAA, CSTR Message = NULL); |
||||
|
signals: |
||||
|
void selected(void* P); |
||||
|
public slots: |
||||
|
void setGrayScale(); |
||||
|
void setEnhanced(); |
||||
|
void showCameraSettings(); |
||||
|
void removeThisCamera(); |
||||
|
void renderLater(); |
||||
|
void renderNow(); |
||||
|
void ShowContextMenu(const QPoint& pos); |
||||
|
protected: |
||||
|
bool event(QEvent* event); |
||||
|
|
||||
|
//void resizeEvent(QResizeEvent *event); |
||||
|
void exposeEvent(QExposeEvent* event); |
||||
|
void paintEvent(QPaintEvent* event); |
||||
|
//void drawContents(QPainter * p, const QRectF & rect = QRectF()); |
||||
|
private: |
||||
|
bool m_bUpdateIsPending; |
||||
|
QTimer * m_pTimer; |
||||
|
}; |
||||
|
|
||||
|
|
||||
|
#endif |
||||
@ -0,0 +1,231 @@ |
|||||
|
<RCC> |
||||
|
<qresource prefix="layout"> |
||||
|
<file>PNG/layout/001.png</file> |
||||
|
<file>PNG/layout/002.png</file> |
||||
|
<file>PNG/layout/003.png</file> |
||||
|
<file>PNG/layout/004.png</file> |
||||
|
<file>PNG/layout/005.png</file> |
||||
|
<file>PNG/layout/006.png</file> |
||||
|
<file>PNG/layout/007.png</file> |
||||
|
<file>PNG/layout/008.png</file> |
||||
|
<file>PNG/layout/009.png</file> |
||||
|
<file>PNG/layout/010.png</file> |
||||
|
<file>PNG/layout/011.png</file> |
||||
|
<file>PNG/layout/012.png</file> |
||||
|
<file>PNG/layout/013.png</file> |
||||
|
<file>PNG/layout/014.png</file> |
||||
|
<file>PNG/layout/015.png</file> |
||||
|
<file>PNG/layout/016.png</file> |
||||
|
<file>PNG/layout/017.png</file> |
||||
|
<file>PNG/layout/018.png</file> |
||||
|
<file>PNG/layout/019.png</file> |
||||
|
<file>PNG/layout/020.png</file> |
||||
|
<file>PNG/layout/021.png</file> |
||||
|
<file>PNG/layout/022.png</file> |
||||
|
<file>PNG/layout/023.png</file> |
||||
|
<file>PNG/layout/024.png</file> |
||||
|
<file>PNG/layout/025.png</file> |
||||
|
<file>PNG/layout/026.png</file> |
||||
|
<file>PNG/layout/027.png</file> |
||||
|
<file>PNG/layout/028.png</file> |
||||
|
<file>PNG/layout/029.png</file> |
||||
|
<file>PNG/layout/030.png</file> |
||||
|
<file>PNG/layout/031.png</file> |
||||
|
<file>PNG/layout/032.png</file> |
||||
|
<file>PNG/layout/033.png</file> |
||||
|
<file>PNG/layout/034.png</file> |
||||
|
<file>PNG/layout/035.png</file> |
||||
|
<file>PNG/layout/036.png</file> |
||||
|
<file>PNG/layout/037.png</file> |
||||
|
<file>PNG/layout/038.png</file> |
||||
|
<file>PNG/layout/039.png</file> |
||||
|
<file>PNG/layout/040.png</file> |
||||
|
<file>PNG/layout/041.png</file> |
||||
|
<file>PNG/layout/042.png</file> |
||||
|
<file>PNG/layout/043.png</file> |
||||
|
<file>PNG/layout/044.png</file> |
||||
|
<file>PNG/layout/045.png</file> |
||||
|
<file>PNG/layout/046.png</file> |
||||
|
<file>PNG/layout/047.png</file> |
||||
|
<file>PNG/layout/048.png</file> |
||||
|
<file>PNG/layout/049.png</file> |
||||
|
<file>PNG/layout/050.png</file> |
||||
|
<file>PNG/layout/051.png</file> |
||||
|
<file>PNG/layout/052.png</file> |
||||
|
<file>PNG/layout/053.png</file> |
||||
|
<file>PNG/layout/054.png</file> |
||||
|
<file>PNG/layout/055.png</file> |
||||
|
<file>PNG/layout/056.png</file> |
||||
|
<file>PNG/layout/057.png</file> |
||||
|
<file>PNG/layout/058.png</file> |
||||
|
<file>PNG/layout/059.png</file> |
||||
|
<file>PNG/layout/060.png</file> |
||||
|
<file>PNG/layout/061.png</file> |
||||
|
<file>PNG/layout/062.png</file> |
||||
|
<file>PNG/layout/063.png</file> |
||||
|
<file>PNG/layout/064.png</file> |
||||
|
<file>PNG/layout/065.png</file> |
||||
|
<file>PNG/layout/066.png</file> |
||||
|
<file>PNG/layout/067.png</file> |
||||
|
<file>PNG/layout/068.png</file> |
||||
|
<file>PNG/layout/069.png</file> |
||||
|
<file>PNG/layout/070.png</file> |
||||
|
<file>PNG/layout/071.png</file> |
||||
|
<file>PNG/layout/072.png</file> |
||||
|
<file>PNG/layout/073.png</file> |
||||
|
<file>PNG/layout/074.png</file> |
||||
|
<file>PNG/layout/075.png</file> |
||||
|
<file>PNG/layout/076.png</file> |
||||
|
<file>PNG/layout/077.png</file> |
||||
|
<file>PNG/layout/078.png</file> |
||||
|
<file>PNG/layout/079.png</file> |
||||
|
<file>PNG/layout/080.png</file> |
||||
|
<file>PNG/layout/081.png</file> |
||||
|
<file>PNG/layout/082.png</file> |
||||
|
<file>PNG/layout/083.png</file> |
||||
|
<file>PNG/layout/084.png</file> |
||||
|
<file>PNG/layout/085.png</file> |
||||
|
<file>PNG/layout/086.png</file> |
||||
|
<file>PNG/layout/087.png</file> |
||||
|
<file>PNG/layout/088.png</file> |
||||
|
<file>PNG/layout/089.png</file> |
||||
|
<file>PNG/layout/090.png</file> |
||||
|
<file>PNG/layout/091.png</file> |
||||
|
<file>PNG/layout/092.png</file> |
||||
|
<file>PNG/layout/093.png</file> |
||||
|
<file>PNG/layout/094.png</file> |
||||
|
<file>PNG/layout/095.png</file> |
||||
|
<file>PNG/layout/096.png</file> |
||||
|
<file>PNG/layout/097.png</file> |
||||
|
<file>PNG/layout/098.png</file> |
||||
|
<file>PNG/layout/099.png</file> |
||||
|
<file>PNG/layout/100.png</file> |
||||
|
<file>PNG/layout/101.png</file> |
||||
|
<file>PNG/layout/102.png</file> |
||||
|
<file>PNG/layout/103.png</file> |
||||
|
<file>PNG/layout/104.png</file> |
||||
|
<file>PNG/layout/105.png</file> |
||||
|
<file>PNG/layout/106.png</file> |
||||
|
<file>PNG/layout/107.png</file> |
||||
|
<file>PNG/layout/108.png</file> |
||||
|
<file>PNG/layout/109.png</file> |
||||
|
<file>PNG/layout/110.png</file> |
||||
|
<file>PNG/layout/111.png</file> |
||||
|
<file>PNG/layout/112.png</file> |
||||
|
<file>PNG/layout/113.png</file> |
||||
|
<file>PNG/layout/114.png</file> |
||||
|
<file>PNG/layout/115.png</file> |
||||
|
<file>PNG/layout/116.png</file> |
||||
|
<file>PNG/layout/117.png</file> |
||||
|
<file>PNG/layout/118.png</file> |
||||
|
<file>PNG/layout/119.png</file> |
||||
|
<file>PNG/layout/120.png</file> |
||||
|
<file>PNG/layout/121.png</file> |
||||
|
<file>PNG/layout/122.png</file> |
||||
|
<file>PNG/layout/123.png</file> |
||||
|
<file>PNG/layout/124.png</file> |
||||
|
</qresource> |
||||
|
<qresource prefix="menu"> |
||||
|
<file>PNG/devices/001.png</file> |
||||
|
<file>PNG/devices/002.png</file> |
||||
|
<file>PNG/devices/003.png</file> |
||||
|
<file>PNG/devices/004.png</file> |
||||
|
<file>PNG/devices/005.png</file> |
||||
|
<file>PNG/devices/006.png</file> |
||||
|
<file>PNG/devices/007.png</file> |
||||
|
<file>PNG/devices/008.png</file> |
||||
|
<file>PNG/devices/009.png</file> |
||||
|
<file>PNG/devices/010.png</file> |
||||
|
<file>PNG/devices/011.png</file> |
||||
|
<file>PNG/devices/012.png</file> |
||||
|
<file>PNG/devices/013.png</file> |
||||
|
<file>PNG/devices/014.png</file> |
||||
|
<file>PNG/devices/015.png</file> |
||||
|
<file>PNG/devices/016.png</file> |
||||
|
<file>PNG/devices/017.png</file> |
||||
|
<file>PNG/devices/018.png</file> |
||||
|
<file>PNG/devices/019.png</file> |
||||
|
<file>PNG/devices/020.png</file> |
||||
|
<file>PNG/devices/021.png</file> |
||||
|
<file>PNG/devices/022.png</file> |
||||
|
<file>PNG/devices/023.png</file> |
||||
|
<file>PNG/devices/024.png</file> |
||||
|
<file>PNG/devices/025.png</file> |
||||
|
<file>PNG/devices/026.png</file> |
||||
|
<file>PNG/devices/027.png</file> |
||||
|
<file>PNG/devices/028.png</file> |
||||
|
<file>PNG/devices/029.png</file> |
||||
|
<file>PNG/devices/030.png</file> |
||||
|
<file>PNG/devices/031.png</file> |
||||
|
<file>PNG/devices/032.png</file> |
||||
|
<file>PNG/devices/033.png</file> |
||||
|
<file>PNG/devices/034.png</file> |
||||
|
<file>PNG/devices/035.png</file> |
||||
|
<file>PNG/devices/036.png</file> |
||||
|
<file>PNG/devices/037.png</file> |
||||
|
<file>PNG/devices/038.png</file> |
||||
|
<file>PNG/devices/039.png</file> |
||||
|
<file>PNG/devices/040.png</file> |
||||
|
<file>PNG/devices/041.png</file> |
||||
|
<file>PNG/devices/042.png</file> |
||||
|
<file>PNG/devices/043.png</file> |
||||
|
<file>PNG/devices/044.png</file> |
||||
|
<file>PNG/devices/045.png</file> |
||||
|
<file>PNG/devices/046.png</file> |
||||
|
<file>PNG/devices/047.png</file> |
||||
|
<file>PNG/devices/048.png</file> |
||||
|
<file>PNG/devices/049.png</file> |
||||
|
</qresource> |
||||
|
<qresource prefix="general"> |
||||
|
<file>025.png</file> |
||||
|
<file>026.png</file> |
||||
|
<file>alert.png</file> |
||||
|
<file>alert_clock.ico</file> |
||||
|
<file>alert_clock.png</file> |
||||
|
<file>audio_high.png</file> |
||||
|
<file>audio_low.png</file> |
||||
|
<file>battery_20_2.png</file> |
||||
|
<file>battery_40.png</file> |
||||
|
<file>battery_100_2.png</file> |
||||
|
<file>battery_charge.png</file> |
||||
|
<file>battery_charge_2.png</file> |
||||
|
<file>bulb.ico</file> |
||||
|
<file>bulb.png</file> |
||||
|
<file>cancel.ico</file> |
||||
|
<file>cancel.png</file> |
||||
|
<file>close.ico</file> |
||||
|
<file>close.png</file> |
||||
|
<file>cog_02_2x.png</file> |
||||
|
<file>faq.ico</file> |
||||
|
<file>faq.png</file> |
||||
|
<file>fax.ico</file> |
||||
|
<file>fax.png</file> |
||||
|
<file>file.png</file> |
||||
|
<file>id_card.ico</file> |
||||
|
<file>id_card.png</file> |
||||
|
<file>information.ico</file> |
||||
|
<file>information.png</file> |
||||
|
<file>locked.png</file> |
||||
|
<file>map_2.png</file> |
||||
|
<file>megaphone.ico</file> |
||||
|
<file>megaphone.png</file> |
||||
|
<file>page_empty_2x.png</file> |
||||
|
<file>pin_2.png</file> |
||||
|
<file>refresh (1).png</file> |
||||
|
<file>refresh.png</file> |
||||
|
<file>refresh_2x.png</file> |
||||
|
<file>resources.qrc</file> |
||||
|
<file>save.ico</file> |
||||
|
<file>save.png</file> |
||||
|
<file>settings_4.png</file> |
||||
|
<file>settings1.png</file> |
||||
|
<file>settings2.png</file> |
||||
|
<file>success.ico</file> |
||||
|
<file>success.png</file> |
||||
|
<file>target.ico</file> |
||||
|
<file>target.png</file> |
||||
|
<file>unlocked.png</file> |
||||
|
<file>watch.png</file> |
||||
|
<file>watch_2.png</file> |
||||
|
</qresource> |
||||
|
</RCC> |
||||
@ -0,0 +1 @@ |
|||||
|
C:\LIBS\Qt\5.12.2\msvc2015_64\bin\rcc.exe -binary cudawork_resources.qrc -o resources2.rcc |
||||
Write
Preview
Loading…
Cancel
Save
Reference in new issue