Commit Graph

61 Commits

Author SHA1 Message Date
Tats
e8870db92a Replaced Shape by MShape to avoid name conflicts. 2014-10-31 17:03:18 -04:00
Tats
3496bd1315 Allows displacement of selected vertex with arrow keys. 2014-10-23 13:41:08 +00:00
Tats
07e1b26436 Allows individual selection of a vertex to be shown on screen. 2014-10-23 13:40:01 +00:00
Tats
3acb257cf0 Cleanup in MapperGLCanvas.cpp mousePressedEvent. 2014-10-22 17:18:49 +00:00
Alexandre Quessy
cbee34aabd Feature: Select a shape with a click 2014-10-14 07:40:17 -04:00
Alexandre Quessy
5e6e4909e1 Fix: radius for dragging vertices. Drag shape with left click. 2014-10-14 06:20:22 -04:00
Alexandre Quessy
1b73d45a89 New feature: menu option toggle sticky vertices 2014-10-14 01:48:00 -04:00
Alexandre Quessy
42b0a6708f Merge branch 'develop' into osc-fix-july-2014 2014-07-07 15:30:37 -04:00
Alexandre Quessy
c5b5a48d23 less prints 2014-07-07 15:15:22 -04:00
Tats
2cbab1bf2d Some cleanup in MapperGLCanvas 2014-06-25 23:00:39 -04:00
Tats
4a4b1f05b2 Cosmetic refactoring and variable inits 2014-06-23 18:30:49 -04:00
Alexandre Quessy
64889af9a9 Fixed OSX-related runtime errors that were making the application crash 2014-06-23 14:53:29 -04:00
Alexandre Quessy
0f40608562 Fixed basic problem with QGLFormat that was causing a crash; still re-building the application step by step 2014-06-23 12:54:58 -04:00
Vasilis Liaskovitis
1aace8a578 Change the uri of existing media or color paint with double-click
When double-clicking a paint QListWidgetItem, the uri of that paint can be
altered.

A new signal is sent to ColorMapper and TextureMapper objects so that they can
update heir color and texture paints respectively. Mappings of the old paint are
transferred to the new paint.

TODO: the active mapping may be lost in some cases, needs some more testing.
2014-05-22 11:30:25 +02:00
Alexandre Quessy
7177d62f90 remove useless endl in prints 2014-05-08 16:06:31 -04:00
Vasilis Liaskovitis
06e8c57db2 MapperGLCanvas: avoid segfault on right-click with no active shape 2014-05-06 10:43:17 -04:00
Tats
27b41db8af Renamed _active_vertex to _activeVertex. 2014-05-03 13:30:00 -04:00
Tats
d98eb516f4 Use method distSq and MM:: definitions for vertex selection. 2014-05-03 13:29:30 -04:00
Tats
ca78874387 Cosmetic changes 2014-05-03 13:17:00 -04:00
Tats
2285716ed2 Fix bug and potential bugs with painters not being reset between draws. 2014-05-03 13:10:46 -04:00
Tats
ded32de4c1 Fixed bug: When moving vertices in the input area while a color mapping exists, we have a null pointer and it crashes. 2014-05-03 12:52:18 -04:00
Tats
f5d375442a Improved the style of the control rendering. 2014-05-03 00:26:02 -04:00
Tats
3ad20ddd9b Changed the stick vertex comparison code to work with the new distance methods 2014-05-02 14:13:40 -04:00
Tats
86c91cae39 Cleanup 2014-05-02 14:08:47 -04:00
Tats
7cc816f625 Even better antialiasing using setFormat() 2014-05-01 14:13:23 -04:00
Tats
9dd753a38c Added some antialiasing. 2014-05-01 13:53:01 -04:00
Tats
4d3694fe28 Added an option to toggle the display of shape control points 2014-04-10 18:27:40 -04:00
Tats
419834b0ee Removed MainWindow singleton, replacing it with much more appropriate member pointers in custom widgets 2014-04-10 17:39:37 -04:00
Tats
d511243618 Bug fix in the iteration over ids (was iterating over vector index, not item uids). 2014-03-18 23:01:45 -04:00
Tats
392869f56f Manage appropriate layout and resizing of output GL canvas 2014-03-15 23:37:54 -04:00
Tats
195c426991 Removed the Point class and replace all instances by QPointF. 2014-02-09 01:02:13 -05:00
Tats
0ff52de66a Major reconfiguration of the GL canvases and the Mapper interface to allow for the use of a QPainter and for integrating ColorPaint mappings 2014-01-22 15:01:00 -05:00
Tats
62492a9c41 Minor: added some Q_UNUSED() to prevent warnings 2014-01-11 21:59:56 -05:00
Tats
4639a228c6 Resolved all compilation errors from merging 2014-01-05 18:07:19 -05:00
Tats
559a7ebf90 Merge branch 'develop' into statesaving
Conflicts:
	DestinationGLCanvas.cpp
	MainWindow.cpp
	MainWindow.h
	Mapper.h
	MappingManager.cpp
	MappingManager.h
	Paint.h
	Shape.h
	SourceGLCanvas.cpp
	Util.cpp
	libremapping.pro
	main.cpp
2014-01-05 18:06:41 -05:00
Vasilis Liaskovitis
5852cde869 Shape: Convert Point to QObject / QPointF
Also add one Q_PROPERTY for each coordinate (x and y) of a Point. This will
enable the controller to set and get these properties.

Since QObjects cannot be copied, we also need to change the Shape class to have
a vector of pointers to Points, instead of actual Point structs.
2013-12-24 13:50:20 +02:00
Tats
6b864b64ed Removed some debugging code 2013-12-15 23:12:44 -05:00
Tats
f66f67c654 Better managing of vertex selection 2013-12-10 22:27:39 -05:00
Alexandre Quessy
dce8f0b35d Saves an XML file. 2013-12-09 15:20:33 -05:00
Tats
cd2639812d Replaced signal quadChanged for shapeChanged 2013-12-08 11:56:55 -05:00
Tats
4a80c0a328 Merge branch 'sticky-vertices' of github.com:vliaskov/libremapping into develop
Conflicts:
	Shape.h
	SourceGLCanvas.cpp
2013-12-06 18:06:28 -05:00
Vasilis Liaskovitis
b3340e2633 GLCanvas: Implement sticky vertex movement
If the vertex of the current Shape is being moved, it may be useful to "glue" it
to a vertex of another shape, if the 2 vertices are close together. This patch
implements this. THe sticky-sensitivity is controlled by the dist_stick
variable, which is currently hardcoded but could be made configurable e.g.
through the GUI.

The patch also uses a new pure virtual method called getShapeFromMappingId(),
which is implemented by Source / Dest Canvas subclasses. getCurrentShape() is
now using this function, so it is now a non-virtual function in MapperGLCanvas.
2013-12-05 23:48:16 +02:00
Tats
3e34947a88 Merge branch 'shape-drag' of github.com:vliaskov/libremapping
Conflicts:
	MapperGLCanvas.h
	Shape.h
2013-12-04 23:02:47 -05:00
Vasilis Liaskovitis
d7c09a5426 Move active_vertex from Shape to MapperGLCanvas 2013-12-03 01:34:49 +02:00
Vasilis Liaskovitis
35fb1ca821 Implement shape drag-and-drop
A user may find it useful in some cases to drag and drop a whole shape, instead
of moving each vertex separately. This patch implements shape drag-and-drop by
pressing and holding the right mouse button. Point inclusion algorithm should
work for non-convex and convex polygons, as suggested in
http://www.cs.tufts.edu/comp/163/notes05/point_inclusion_handout.pdf
2013-12-03 01:14:17 +02:00
Tats
8b205526fe Completed integration of one source -> many quads (everything working) 2013-11-30 21:48:01 -05:00
Tats
73d934b4d0 Some cleanup in switching of image source 2013-11-30 19:23:35 -05:00
Tats
5a999f1983 - Put all mappings and paints in a single MappingManager class
- Basic compiling / running program (no quads for now)
2013-11-30 19:19:29 -05:00
Tats
7fce243072 Merge remote-tracking branch 'vliaskov/click-drag' 2013-11-29 12:09:58 -05:00
Tats
fd958cecf2 Merge branch 'master' of github.com:libremapping/libremapping
Conflicts:
	Common.cpp
	Common.h
	DestinationGLCanvas.cpp
	SourceGLCanvas.cpp
	main.cpp
2013-11-29 12:09:49 -05:00