Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
matthill committed Apr 11, 2017
1 parent 86cb254 commit 2c3fdf0
Show file tree
Hide file tree
Showing 63 changed files with 5,357 additions and 0 deletions.
35 changes: 35 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
plates.exe
*.app
obj
*.pro.user*
*~
*.autosave
*.a
*.core
*.moc
*.o
*.obj
*.orig
*.rej
*_pch.h.cpp
*_resource.rc
*.qm
.#*
*.*#
core
!core/
tags
.DS_Store
.directory
*.debug
Makefile*
*.prl
*.app
moc_*.cpp
ui_*.h
qrc_*.cpp
Thumbs.db
*.res
/.qmake.cache
/.qmake.stash
build/
59 changes: 59 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
cmake_minimum_required(VERSION 2.8.11)

project(openalpr_tagger)

SET(VERSION_MAJOR 1)
SET(VERSION_MINOR 0)
SET(VERSION_PATCH 0)

SET (VERSION "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}")
add_definitions(-DVERSION_MAJOR=${VERSION_MAJOR})
add_definitions(-DVERSION_MINOR=${VERSION_MINOR})
add_definitions(-DVERSION_PATCH=${VERSION_PATCH})
add_definitions(-DVERSION_STRING="${VERSION}")


add_definitions(-DTARGET="openalpr_tagger")
add_definitions(-DTARGET_STRING="openalpr_tagger")
add_definitions(-DTARGET_UPPER_STRING="OPENALPR_TAGGER")
add_definitions(-DTARGET_HUMAN_STRING="openalpr_tagger")

ADD_DEFINITIONS(
-std=c++11
)


# Find the QtWidgets library
find_package(Qt5Widgets)

set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTOUIC ON)
set(CMAKE_INCLUDE_CURRENT_DIR ON)

# Tell CMake to create the helloworld executable
add_executable(openalpr_tagger
about.cpp
directoryloader.cpp
dot.cpp
imagefile.cpp
imageview.cpp
imageviewerbase.cpp
imageviewerobserver.cpp
imageviewerplateselector.cpp
main.cpp
mainwindow.cpp
options.cpp
platefile.cpp
plateselector.cpp
polygons.cpp
selection.cpp
settings.cpp
squeezedlabel.cpp
threadedimageloader.cpp
utils.cpp
qprogressindicator/QProgressIndicator.cpp
)

include_directories(${CMAKE_SOURCE_DIR}/qprogressindicator)
# Use the Widgets module from Qt 5.
target_link_libraries(openalpr_tagger Qt5::Widgets)
34 changes: 34 additions & 0 deletions Info.plist
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>NSPrincipalClass</key>
<string>NSApplication</string>
<key>NSHumanReadableCopyright</key>
<string>(C) 2017, Dmitry Baryshev</string>
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleIconFile</key>
<string>plates.icns</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleGetInfoString</key>
<string>OpenALPR Training Utility</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleExecutable</key>
<string>plates</string>
<key>CFBundleIdentifier</key>
<string>net.plates</string>
<key>CFBundleName</key>
<string>OpenALPR Training Utility</string>
<key>CFBundleDisplayName</key>
<string>OpenALPR Training Utility</string>
<key>CFBundleShortVersionString</key>
<string>1.0.0</string>
<key>CFBundleVersion</key>
<string>1.0.0</string>
</dict>
</plist>
32 changes: 32 additions & 0 deletions about.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
#include <QtGui>

#include "about.h"
#include "ui_about.h"

About::About(QWidget *parent)
: QDialog(parent)
, ui(new Ui::About)
{
ui->setupUi(this);

ui->labelProduct->setText(TARGET_HUMAN_STRING);
ui->labelVersion->setText(tr("Version %1").arg(VERSION_STRING));
ui->labelIcon->setPixmap(QIcon(":/images/" TARGET_STRING ".ico").pixmap(48, 48));

// %1 will be replaced with a product name
ui->labelWarranty->setText(tr("%1 is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.")
.arg(TARGET_HUMAN_STRING));

#ifdef Q_OS_MAC
ui->pushOK->hide();
#else
setWindowTitle(tr("About"));
#endif

adjustSize();
}

About::~About()
{
delete ui;
}
23 changes: 23 additions & 0 deletions about.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
#ifndef ABOUT_H
#define ABOUT_H

#include <QDialog>

namespace Ui
{
class About;
}

class About : public QDialog
{
Q_OBJECT

public:
explicit About(QWidget *parent = 0);
~About();

private:
Ui::About *ui;
};

#endif // ABOUT_H
193 changes: 193 additions & 0 deletions about.ui
Original file line number Diff line number Diff line change
@@ -0,0 +1,193 @@
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>About</class>
<widget class="QDialog" name="About">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>280</width>
<height>124</height>
</rect>
</property>
<layout class="QGridLayout" name="gridLayout">
<item row="3" column="0" colspan="5">
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>0</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QPushButton" name="pushOK">
<property name="text">
<string>OK</string>
</property>
<property name="default">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item row="0" column="0">
<spacer name="horizontalSpacer_4">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>0</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="0" column="2">
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>0</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="2" column="0" colspan="5">
<widget class="QLabel" name="labelWarranty">
<property name="text">
<string/>
</property>
<property name="alignment">
<set>Qt::AlignJustify|Qt::AlignVCenter</set>
</property>
<property name="wordWrap">
<bool>true</bool>
</property>
</widget>
</item>
<item row="0" column="1">
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QLabel" name="labelIcon"/>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>0</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
<item row="0" column="4">
<spacer name="horizontalSpacer_5">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>0</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="0" column="3">
<layout class="QVBoxLayout" name="verticalLayout">
<property name="spacing">
<number>8</number>
</property>
<item>
<widget class="QLabel" name="labelProduct">
<property name="font">
<font>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="labelVersion">
<property name="alignment">
<set>Qt::AlignCenter</set>
</property>
</widget>
</item>
<item>
<spacer name="verticalSpacer_2">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>0</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
<item row="1" column="0">
<spacer name="verticalSpacer_3">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>6</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<resources/>
<connections>
<connection>
<sender>pushOK</sender>
<signal>clicked()</signal>
<receiver>About</receiver>
<slot>accept()</slot>
<hints>
<hint type="sourcelabel">
<x>175</x>
<y>131</y>
</hint>
<hint type="destinationlabel">
<x>423</x>
<y>230</y>
</hint>
</hints>
</connection>
</connections>
<slots>
<slot>slotShowIPs()</slot>
</slots>
</ui>
5 changes: 5 additions & 0 deletions debian/changelog
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
plates (1.0.0-1) unstable; urgency=medium

* Initial release.

-- Dmitry Baryshev <[email protected]> Fri, 07 Apr 2017 14:51:50 +0300
1 change: 1 addition & 0 deletions debian/compat
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
9
Loading

0 comments on commit 2c3fdf0

Please sign in to comment.