-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from dpozimski/develop
Develop
- Loading branch information
Showing
91 changed files
with
13,799 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
|
||
Microsoft Visual Studio Solution File, Format Version 12.00 | ||
# Visual Studio 14 | ||
VisualStudioVersion = 14.0.25420.1 | ||
MinimumVisualStudioVersion = 10.0.40219.1 | ||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "LicensePlateCharsExtractor", "LicensePlateCharsExtractor\LicensePlateCharsExtractor.vcxproj", "{8D9543FA-EE49-4F5A-A514-B88F61A3E1FB}" | ||
EndProject | ||
Global | ||
GlobalSection(SolutionConfigurationPlatforms) = preSolution | ||
Debug|x64 = Debug|x64 | ||
Debug|x86 = Debug|x86 | ||
Release|x64 = Release|x64 | ||
Release|x86 = Release|x86 | ||
EndGlobalSection | ||
GlobalSection(ProjectConfigurationPlatforms) = postSolution | ||
{8D9543FA-EE49-4F5A-A514-B88F61A3E1FB}.Debug|x64.ActiveCfg = Debug|x64 | ||
{8D9543FA-EE49-4F5A-A514-B88F61A3E1FB}.Debug|x64.Build.0 = Debug|x64 | ||
{8D9543FA-EE49-4F5A-A514-B88F61A3E1FB}.Debug|x86.ActiveCfg = Debug|Win32 | ||
{8D9543FA-EE49-4F5A-A514-B88F61A3E1FB}.Debug|x86.Build.0 = Debug|Win32 | ||
{8D9543FA-EE49-4F5A-A514-B88F61A3E1FB}.Release|x64.ActiveCfg = Release|x64 | ||
{8D9543FA-EE49-4F5A-A514-B88F61A3E1FB}.Release|x64.Build.0 = Release|x64 | ||
{8D9543FA-EE49-4F5A-A514-B88F61A3E1FB}.Release|x86.ActiveCfg = Release|Win32 | ||
{8D9543FA-EE49-4F5A-A514-B88F61A3E1FB}.Release|x86.Build.0 = Release|Win32 | ||
EndGlobalSection | ||
GlobalSection(SolutionProperties) = preSolution | ||
HideSolutionNode = FALSE | ||
EndGlobalSection | ||
EndGlobal |
25 changes: 25 additions & 0 deletions
25
LicensePlateCharsExtractor/LicensePlateCharsExtractor/ContourWithData.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
#pragma once | ||
|
||
#include<opencv2/core/core.hpp> | ||
|
||
const int MIN_CONTOUR_AREA = 100; | ||
|
||
class ContourWithData { | ||
public: | ||
// member variables /////////////////////////////////////////////////////////////////////////// | ||
std::vector<cv::Point> ptContour; // contour | ||
cv::Rect boundingRect; // bounding rect for contour | ||
float fltArea; // area of contour | ||
|
||
/////////////////////////////////////////////////////////////////////////////////////////////// | ||
bool checkIfContourIsValid() { // obviously in a production grade program | ||
if (fltArea < MIN_CONTOUR_AREA) return false; // we would have a much more robust function for | ||
return true; // identifying if a contour is valid !! | ||
} | ||
|
||
/////////////////////////////////////////////////////////////////////////////////////////////// | ||
static bool sortByBoundingRectXPosition(const ContourWithData& cwdLeft, const ContourWithData& cwdRight) { // this function allows us to sort | ||
return(cwdLeft.boundingRect.x < cwdRight.boundingRect.x); // the contours from left to right | ||
} | ||
|
||
}; |
Oops, something went wrong.