mirror of
https://github.com/mapmapteam/mapmap.git
synced 2026-06-16 12:33:19 +02:00
Merge branch 'master' of github.com:libremapping/libremapping
This commit is contained in:
+23
-6
@@ -209,12 +209,29 @@ void MainWindow::addTriangle()
|
||||
|
||||
void MainWindow::about()
|
||||
{
|
||||
QMessageBox::about(this, tr("About Libremapping"),
|
||||
tr("<h2>Libremapping "
|
||||
QMessageBox::about(this, tr("About LibreMapping"),
|
||||
tr("<h2>LibreMapping "
|
||||
LIBREMAPPING_VERSION
|
||||
"</h2>"
|
||||
"<p>Copyright © 2013 Office International de la Francophonie"
|
||||
"<p>Libremapping is a free software for video mapping."));
|
||||
"<p>Copyright © 2013 Organisation internationale de la Francophonie"
|
||||
|
||||
"<p>Copyright © 2013 Sofian Audry"
|
||||
"<p>Copyright © 2013 Alexandre Quessy"
|
||||
"<p>Copyright © 2013 Vasilis Liaskovitis"
|
||||
"<p>Copyright © 2013 Sylvain Cormier"
|
||||
"<p>Libremapping is a free software for video mapping. "
|
||||
"<p>Projection mapping, also known as video mapping and spatial augmented reality, "
|
||||
"is a projection technology used to turn objects, often irregularly shaped, into "
|
||||
"a display surface for video projection. These objects may be complex industrial "
|
||||
"landscapes, such as buildings. By using specialized software, a two or three "
|
||||
"dimensional object is spatially mapped on the virtual program which mimics the "
|
||||
"real environment it is to be projected on. The software can interact with a "
|
||||
"projector to fit any desired image onto the surface of that object. This "
|
||||
"technique is used by artists and advertisers alike who can add extra dimensions, "
|
||||
"optical illusions, and notions of movement onto previously static objects. The "
|
||||
"video is commonly combined with, or triggered by, audio to create an "
|
||||
"audio-visual narrative."
|
||||
));
|
||||
}
|
||||
|
||||
void MainWindow::updateStatusBar()
|
||||
@@ -543,14 +560,14 @@ void MainWindow::setCurrentFile(const QString &fileName)
|
||||
shownName = strippedName(curFile);
|
||||
}
|
||||
|
||||
setWindowTitle(tr("%1[*] - %2").arg(shownName).arg(tr("Spreadsheet")));
|
||||
setWindowTitle(tr("%1[*] - %2").arg(shownName).arg(tr("LibreMapping Project")));
|
||||
}
|
||||
|
||||
bool MainWindow::importFile(const QString &fileName)
|
||||
{
|
||||
QFile file(fileName);
|
||||
if (!file.open(QIODevice::ReadOnly)) {
|
||||
QMessageBox::warning(this, tr("Spreadsheet"),
|
||||
QMessageBox::warning(this, tr("LibreMapping Project"),
|
||||
tr("Cannot read file %1:\n%2.")
|
||||
.arg(file.fileName())
|
||||
.arg(file.errorString()));
|
||||
|
||||
@@ -24,8 +24,13 @@
|
||||
|
||||
#include <QtGlobal>
|
||||
|
||||
#include <tr1/memory>
|
||||
#if __APPLE__
|
||||
#include <OpenGL/gl.h>
|
||||
#else
|
||||
#include <GL/gl.h>
|
||||
#endif
|
||||
|
||||
#include <tr1/memory>
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
|
||||
@@ -25,7 +25,13 @@
|
||||
#include <QtGlobal>
|
||||
#include <QtOpenGL>
|
||||
#include <string>
|
||||
|
||||
#if __APPLE__
|
||||
#include <OpenGL/gl.h>
|
||||
#else
|
||||
#include <GL/gl.h>
|
||||
#endif
|
||||
|
||||
#include <tr1/memory>
|
||||
|
||||
/**
|
||||
|
||||
@@ -20,7 +20,11 @@
|
||||
#ifndef UTIL_H_
|
||||
#define UTIL_H_
|
||||
|
||||
#if __APPLE__
|
||||
#include <OpenGL/gl.h>
|
||||
#else
|
||||
#include <GL/gl.h>
|
||||
#endif
|
||||
|
||||
#include "Shape.h"
|
||||
#include "Paint.h"
|
||||
|
||||
+6
-1
@@ -3,10 +3,15 @@ TEMPLATE = app
|
||||
HEADERS = MainWindow.h Util.h MapperGLCanvas.h SourceGLCanvas.h DestinationGLCanvas.h Mapper.h Mapping.h Shape.h Paint.h MappingManager.h
|
||||
SOURCES = main.cpp MainWindow.cpp Util.cpp Mapper.cpp MapperGLCanvas.cpp SourceGLCanvas.cpp DestinationGLCanvas.cpp MappingManager.cpp
|
||||
QT += gui opengl
|
||||
LIBS += -lglut -lGLU
|
||||
RESOURCES = libremapping.qrc
|
||||
|
||||
docs.depends = $(HEADERS) $(SOURCES)
|
||||
docs.commands = (cat Doxyfile; echo "INPUT = $?") | doxygen -
|
||||
QMAKE_EXTRA_TARGETS += docs
|
||||
|
||||
# mac
|
||||
macx:LIBS += -framework OpenGL -framework GLUT
|
||||
macx:QMAKE_CXXFLAGS += -D__MACOSX_CORE__
|
||||
|
||||
# not mac
|
||||
!macx:LIBS += -lglut -lGLU
|
||||
|
||||
@@ -0,0 +1,2 @@
|
||||
Doesn't work yet, but that is how properties work in Qt4.
|
||||
|
||||
Executable
+4
@@ -0,0 +1,4 @@
|
||||
#!/bin/bash
|
||||
# qt4-default qt4-qmake
|
||||
qmake-qt4
|
||||
make
|
||||
@@ -0,0 +1,11 @@
|
||||
CONFIG += qt debug
|
||||
TEMPLATE = app
|
||||
HEADERS =
|
||||
SOURCES = main.cpp
|
||||
QT += gui
|
||||
RESOURCES =
|
||||
|
||||
docs.depends = $(HEADERS) $(SOURCES)
|
||||
docs.commands = (cat Doxyfile; echo "INPUT = $?") | doxygen -
|
||||
QMAKE_EXTRA_TARGETS += docs
|
||||
|
||||
@@ -0,0 +1,66 @@
|
||||
#include <iostream>
|
||||
#include <QObject>
|
||||
#include <QVariant>
|
||||
#include <QMetaProperty>
|
||||
|
||||
class MyClass : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_PROPERTY(Priority priority READ priority WRITE setPriority NOTIFY priorityChanged)
|
||||
Q_ENUMS(Priority)
|
||||
Q_CLASSINFO("Version", "3.0.0")
|
||||
public:
|
||||
MyClass() {}
|
||||
//MyClass(QObject *parent = 0);
|
||||
~MyClass();
|
||||
|
||||
enum Priority { High, Low, VeryHigh, VeryLow };
|
||||
|
||||
void setPriority(Priority priority)
|
||||
{
|
||||
m_priority = priority;
|
||||
emit priorityChanged(priority);
|
||||
}
|
||||
Priority priority() const
|
||||
{ return m_priority; }
|
||||
|
||||
signals:
|
||||
void priorityChanged(Priority);
|
||||
|
||||
private:
|
||||
Priority m_priority;
|
||||
};
|
||||
|
||||
|
||||
void MyClass::priorityChanged(Priority)
|
||||
{
|
||||
// pass
|
||||
}
|
||||
void dump (QObject *object)
|
||||
{
|
||||
std::cout << "object: " << std::endl;
|
||||
const QMetaObject *metaobject = object->metaObject();
|
||||
int count = metaobject->propertyCount();
|
||||
for (int i=0; i<count; ++i)
|
||||
{
|
||||
QMetaProperty metaproperty = metaobject->property(i);
|
||||
const char *name = metaproperty.name();
|
||||
QVariant value = object->property(name);
|
||||
std::cout << " * " << name << " = " << value.toString().toStdString() << std::endl;
|
||||
}
|
||||
}
|
||||
|
||||
int main(int /* argc */, char ** /* argv */)
|
||||
{
|
||||
MyClass *myinstance = new MyClass();
|
||||
//QObject *object = myinstance;
|
||||
|
||||
myinstance->setPriority(MyClass::VeryHigh);
|
||||
//object->setProperty("priority", "VeryHigh");
|
||||
|
||||
dump ((QObject *) myinstance);
|
||||
|
||||
delete myinstance;
|
||||
|
||||
return 0;
|
||||
}
|
||||
@@ -0,0 +1,150 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
||||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<title>Maquette 01 pour LibreMapping - Logiciel libre de vid�o mapping</title>
|
||||
<!-- author: Alexandre Quessy -->
|
||||
<!-- date: dec 2013 -->
|
||||
<meta charset="UTF-8">
|
||||
<style type="text/css">
|
||||
body {
|
||||
color: #333333;
|
||||
background-color: #cccccc;
|
||||
font-family: monospace;
|
||||
}
|
||||
a {
|
||||
color: #3333ff;
|
||||
}
|
||||
h1, h2, h3, h4, h5 {
|
||||
color: #333333;
|
||||
}
|
||||
hr {
|
||||
border: 3px #333333 solid;
|
||||
}
|
||||
#example {
|
||||
border: 3px #333333 solid;
|
||||
}
|
||||
pre {
|
||||
font-size: 1.4em;
|
||||
}
|
||||
#mixing {
|
||||
border-right: 3px #333333 solid;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>Sources</h1>
|
||||
|
||||
<form action="">
|
||||
<p>
|
||||
type=movie
|
||||
<br />
|
||||
name=movie1
|
||||
<br />
|
||||
playing=<input type="checkbox" name="playing" value="playing">
|
||||
<br />
|
||||
uri=<input type="text" size="12" name="uri" value="~/Downloads/puppies.mov">
|
||||
<br />
|
||||
Some are OSC-only: seek
|
||||
<br />
|
||||
</p>
|
||||
</form>
|
||||
|
||||
<h1>Layers</h1>
|
||||
<h2>Layer 1</h2>
|
||||
<div id="example">
|
||||
<form action="">
|
||||
<table>
|
||||
<tr>
|
||||
<td id="mixing">
|
||||
shape=quad
|
||||
visible=<input type="checkbox" name="visible" value="visible">
|
||||
<br />
|
||||
solo=<input type="checkbox" name="mute" value="mute">
|
||||
<br />
|
||||
lock=<input type="checkbox" name="lock" value="lock">
|
||||
<br />
|
||||
opacity=<input type="text" size="4" name="opacity" value="1.0">
|
||||
<br />
|
||||
z-index=<input type="text" size="4" name="z-index" value="100">
|
||||
|
||||
<!-- td -->
|
||||
</td>
|
||||
<td id=painting">
|
||||
|
||||
name=<input type="text" size="12" name="name" value="rect1">
|
||||
|
||||
<!--
|
||||
XXX: trop complique de pouvoir changer la forme une fois créée
|
||||
shape=
|
||||
<select name="shape">
|
||||
<option value="quad">quad</option>
|
||||
<option value="polygon">polygon</option>
|
||||
<option value="ellipse">ellipse</option>
|
||||
<option value="triangle">triangle</option>
|
||||
<option value="mesh">mesh</option>
|
||||
</select>
|
||||
-->
|
||||
src=
|
||||
<select name="src">
|
||||
<option value="movie1">movie1</option>
|
||||
<option value="test">Test Source 1</option>
|
||||
<option value="image1">image1</option>
|
||||
<option value="red">Color #ff0000</option>
|
||||
</select>
|
||||
|
||||
<hr />
|
||||
Dynamic attributes selon le type de shape:
|
||||
<br />
|
||||
x1=<input type="text" size="4" name="x1" value="0">
|
||||
y1=<input type="text" size="4" name="y1" value="0">
|
||||
x2=<input type="text" size="4" name="x2" value="640">
|
||||
y2=<input type="text" size="4" name="y2" value="0">
|
||||
x3=<input type="text" size="4" name="x3" value="640">
|
||||
y3=<input type="text" size="4" name="y3" value="480">
|
||||
x4=<input type="text" size="4" name="x4" value="0">
|
||||
y4=<input type="text" size="4" name="y4" value="480">
|
||||
<hr />
|
||||
<br/>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
<p>
|
||||
Légende OSC:
|
||||
|
||||
<pre>
|
||||
/lmap/layer/layer1/opacity ,f
|
||||
/lmap/layer/layer1/visible ,b
|
||||
/lmap/layer/layer1/solo ,b
|
||||
/lmap/layer/layer1/lock ,b
|
||||
|
||||
/lmap/src/movie1/uri ,s
|
||||
/lmap/src/movie1/seek ,f
|
||||
/lmap/src/movie1/playing ,b
|
||||
|
||||
/lmap/dst/rect1/x1 ,i
|
||||
/lmap/dst/rect1/y1 ,i
|
||||
/lmap/dst/rect1/x2 ,i
|
||||
/lmap/dst/rect1/y2 ,i
|
||||
/lmap/dst/rect1/x3 ,i
|
||||
/lmap/dst/rect1/y3 ,i
|
||||
/lmap/dst/rect1/x4 ,i
|
||||
/lmap/dst/rect1/y4 ,i
|
||||
/lmap/dst/rect1/src ,s
|
||||
/lmap/dst/rect1/shape ,s
|
||||
/lmap/dst/rect1/layer ,s
|
||||
/lmap/dst/rect1/opacity ,f
|
||||
/lmap/dst/rect1/lock ,b
|
||||
/lmap/dst/rect1/solo ,b
|
||||
/lmap/dst/rect1/visible ,b
|
||||
</pre>
|
||||
</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user