Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

升级到VS2019,x64,OpenCV3416,去掉了编译产生的文件 #3

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -27,26 +27,26 @@
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v120</PlatformToolset>
<PlatformToolset>v142</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v120</PlatformToolset>
<PlatformToolset>v142</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v120</PlatformToolset>
<PlatformToolset>v142</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v120</PlatformToolset>
<PlatformToolset>v142</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>MultiByte</CharacterSet>
</PropertyGroup>
Expand Down Expand Up @@ -78,6 +78,8 @@
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<LinkIncremental>true</LinkIncremental>
<IncludePath>E:\Temp\OpenCV3.4\build\include;E:\Temp\OpenCV3.4\build\include\opencv;E:\Temp\OpenCV3.4\build\include\opencv2;$(IncludePath)</IncludePath>
<LibraryPath>E:\Temp\OpenCV3.4\build\x64\vc14\lib;$(LibraryPath)</LibraryPath>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
Expand Down Expand Up @@ -143,6 +145,7 @@
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<AdditionalDependencies>opencv_world3416.lib;%(AdditionalDependencies)</AdditionalDependencies>
</Link>
</ItemDefinitionGroup>
<ItemGroup>
Expand Down
28 changes: 22 additions & 6 deletions ApplySaliencyToSurfaceInspection/itti/itti.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,15 @@
#include "opencv2/imgproc/imgproc.hpp"
#include "opencv2/imgcodecs.hpp"
#include "opencv2/highgui/highgui.hpp"
#include<math.h>
#include <math.h>
#include <opencv2/opencv.hpp>
#include <fstream>
#include <vector>
#include <time.h>
#include<algorithm>
#include <algorithm>



void ITTI::calculateSaliencyMap(const Mat* src, Mat* dst, int corlor, int scaleBase)
{
createChannels(src);//Create a pyramid for 9 layers.The top is same as src img
Expand Down Expand Up @@ -175,23 +178,36 @@ void ITTI::createOrientationFeatureMaps(int orientation)
int delta[2] = { 3, 4 };
CvGabor *gabor = new CvGabor(orientation, 0);
IplImage* gbr_fineScaleImage, *gbr_coarseScaleImage;

CvSize sizeTemp;

for (int scaleIndex = 0; scaleIndex < fineScaleNumber; scaleIndex++)
{
Mat fineScaleImage = gaussianPyramid_I.at(c[scaleIndex]);
Size fineScaleImageSize = fineScaleImage.size();

IplImage src_fineScaleImage = IplImage(fineScaleImage);
gbr_fineScaleImage = cvCreateImage(fineScaleImage.size(), IPL_DEPTH_8U, 1);
//IplImage src_fineScaleImage = IplImage(fineScaleImage);
//IplImage src_fineScaleImage = cvarrToMat(fineScaleImage);
IplImage src_fineScaleImage = cvIplImage(fineScaleImage);

sizeTemp.width = fineScaleImage.cols; sizeTemp.height = fineScaleImage.rows;
//gbr_fineScaleImage = cvCreateImage(src_fineScaleImage..size(), IPL_DEPTH_8U, 1);
gbr_fineScaleImage = cvCreateImage(sizeTemp, IPL_DEPTH_8U, 1);

gabor->conv_img(&src_fineScaleImage, gbr_fineScaleImage, CV_GABOR_REAL);
Mat src_responseImg = cvarrToMat(gbr_fineScaleImage);

for (int scaleDiffIndex = 0; scaleDiffIndex<scaleDiff; scaleDiffIndex++)
{
int s = c[scaleIndex] + delta[scaleDiffIndex];
Mat coarseScaleImage = gaussianPyramid_I.at(s);
IplImage src_coarseScaleImage = IplImage(coarseScaleImage);
gbr_coarseScaleImage = cvCreateImage(coarseScaleImage.size(), IPL_DEPTH_8U, 1);
//IplImage src_coarseScaleImage = IplImage(coarseScaleImage);
IplImage src_coarseScaleImage = cvIplImage(coarseScaleImage);

//gbr_coarseScaleImage = cvCreateImage(coarseScaleImage.size(), IPL_DEPTH_8U, 1);
sizeTemp.width = coarseScaleImage.cols; sizeTemp.height = coarseScaleImage.rows;
gbr_coarseScaleImage = cvCreateImage(sizeTemp, IPL_DEPTH_8U, 1);

gabor->conv_img(&src_coarseScaleImage, gbr_coarseScaleImage, CV_GABOR_REAL);
Mat coarse_responseImg = cvarrToMat(gbr_coarseScaleImage);

Expand Down
Binary file removed ApplySaliencyToSurfaceInspection/x64/Release/AC.obj
Binary file not shown.

This file was deleted.

Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

This file was deleted.

This file was deleted.

Binary file removed ApplySaliencyToSurfaceInspection/x64/Release/BMS.obj
Binary file not shown.
Binary file not shown.
Binary file removed ApplySaliencyToSurfaceInspection/x64/Release/FT.obj
Binary file not shown.
Binary file removed ApplySaliencyToSurfaceInspection/x64/Release/GMR.obj
Binary file not shown.
Binary file removed ApplySaliencyToSurfaceInspection/x64/Release/HC.obj
Binary file not shown.
Binary file removed ApplySaliencyToSurfaceInspection/x64/Release/LC.obj
Binary file not shown.
Binary file removed ApplySaliencyToSurfaceInspection/x64/Release/MBP.obj
Binary file not shown.
Binary file removed ApplySaliencyToSurfaceInspection/x64/Release/MSS.obj
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed ApplySaliencyToSurfaceInspection/x64/Release/RC.obj
Binary file not shown.
Binary file removed ApplySaliencyToSurfaceInspection/x64/Release/SF.obj
Binary file not shown.
Binary file not shown.
Binary file removed ApplySaliencyToSurfaceInspection/x64/Release/SR.obj
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
2 changes: 1 addition & 1 deletion opencv31vs2013x64r.props
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
</PropertyGroup>
<ItemDefinitionGroup>
<Link>
<AdditionalDependencies>opencv_world310.lib;%(AdditionalDependencies)</AdditionalDependencies>
<AdditionalDependencies>opencv_world3416.lib;%(AdditionalDependencies)</AdditionalDependencies>
</Link>
</ItemDefinitionGroup>
<ItemGroup />
Expand Down
Binary file removed x64/Release/ApplySaliencyToSurfaceInspection.exe
Binary file not shown.
Binary file removed x64/Release/ApplySaliencyToSurfaceInspection.pdb
Binary file not shown.