Commit 9f8f3714 authored by Jan Möbius's avatar Jan Möbius
Browse files

Docu

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@13620 383ad7c9-94d9-4d36-a494-682f7c89f535
parent e2a77e62
......@@ -40,6 +40,9 @@
//== INCLUDES =================================================================
/** \def DATA_CAMERA
* Use this macro to reference cameras
*/
#define DATA_CAMERA typeId("Camera")
#include <ObjectTypes/Camera/CameraObject.hh>
......
/** \page CameraType Camera
/** \page CameraType Camera (DATA_CAMERA)
\image html type_camera_thumb.png
\section type_Camera_info Camera Datatype Information
......
......@@ -51,6 +51,9 @@
//== INCLUDES =================================================================
/** \def DATA_COORDSYS
* Use this macro to reference Coordinate systems
*/
#define DATA_COORDSYS typeId("Coordsys")
#include <ObjectTypes/Coordsys/CoordsysObject.hh>
......
/** \page coordsysType Coordinate System
/** \page coordsysType Coordinate System (DATA_COORDSYS)
\image html type_coordsys_thumb.png
*/
......@@ -50,6 +50,9 @@
//== INCLUDES =================================================================
/** \def DATA_HEXAHEDRAL_MESH
* Use this macro to reference Hexahedral Meshes
*/
#define DATA_HEXAHEDRAL_MESH typeId("HexahedralMesh")
#include <ObjectTypes/VolumeMeshObject/VolumeMeshObject.hh>
#include <ObjectTypes/HexahedralMesh/OpenFlipperHexahedralMesh.hh>
......
......@@ -50,6 +50,9 @@
//== INCLUDES =================================================================
/** \def DATA_POLYHEDRAL_MESH
* Use this macro to reference Polyhedral Meshes
*/
#define DATA_POLYHEDRAL_MESH typeId("PolyhedralMesh")
#include <ObjectTypes/VolumeMeshObject/VolumeMeshObject.hh>
#include <ObjectTypes/PolyhedralMesh/OpenFlipperPolyhedralMesh.hh>
......
......@@ -51,6 +51,9 @@
//== INCLUDES =================================================================
/** \def DATA_SPHERE
* Use this macro to reference Spheres
*/
#define DATA_SPHERE typeId("Sphere")
#include <ObjectTypes/Sphere/SphereObject.hh>
......
/** \page sphereType Sphere
/** \page sphereType Sphere (DATA_SPHERE)
\image html type_Sphere_thumb.png
*/
......@@ -52,7 +52,9 @@
//== DEFINES =====================================================
/** \def DATA_SPLATCLOUD
* Use this macro to reference Splat Clouds
*/
#define DATA_SPLATCLOUD typeId( "SplatCloud" )
......
/** \page splatType Point Splats
/** \page splatType Point Splats (DATA_SPLATCLOUD)
\image html type_splats_thumb.png
*/
......@@ -33,6 +33,8 @@ signals:
To generate the object you can implement the following in one of your functions:
\code
#include <OpenFlipper/BasePlugin/PluginFunctions.hh>
void ExamplePlugin::exampleFunction() {
// Variable which will store the id of the newly created object.
int newObjectId = -1;
......
......@@ -1435,7 +1435,11 @@ void FileOBJPlugin::checkTypes(QString _filename, OBJImporter& _importer, QStrin
} else {
// Mesh does not contain any faces
PolyMeshCount++;
_importer.setObjectOptions(OBJImporter::TRIMESH);
unsigned int currentOptions = _importer.objectOptions()[_importer.currentObject()];
// this is only a triangle mesh if the object is not a curve and not a surface
if (!(currentOptions & OBJImporter::CURVE) && !(currentOptions & OBJImporter::SURFACE)) {
_importer.setObjectOptions(OBJImporter::TRIMESH);
}
}
if (TriMeshCount == 0 && PolyMeshCount == 0)
......
......@@ -265,11 +265,8 @@ void HistogramItem::drawBar(QPainter *painter,
painter->save();
const QColor color(painter->pen().color());
#if QT_VERSION >= 0x040000
const QRect r = rect.normalized();
#else
const QRect r = rect.normalize();
#endif
const int factor = 125;
const QColor light(color.light(factor));
......@@ -282,50 +279,29 @@ void HistogramItem::drawBar(QPainter *painter,
painter->setBrush(Qt::NoBrush);
painter->setPen(QPen(light, 2));
#if QT_VERSION >= 0x040000
QwtPainter::drawLine(painter,
r.left() + 1, r.top() + 2, r.right() + 1, r.top() + 2);
#else
QwtPainter::drawLine(painter,
r.left(), r.top() + 2, r.right() + 1, r.top() + 2);
#endif
painter->setPen(QPen(dark, 2));
#if QT_VERSION >= 0x040000
QwtPainter::drawLine(painter,
r.left() + 1, r.bottom(), r.right() + 1, r.bottom());
#else
QwtPainter::drawLine(painter,
r.left(), r.bottom(), r.right() + 1, r.bottom());
#endif
painter->setPen(QPen(light, 1));
#if QT_VERSION >= 0x040000
QwtPainter::drawLine(painter,
r.left(), r.top() + 1, r.left(), r.bottom());
QwtPainter::drawLine(painter,
r.left() + 1, r.top() + 2, r.left() + 1, r.bottom() - 1);
#else
QwtPainter::drawLine(painter,
r.left(), r.top() + 1, r.left(), r.bottom() + 1);
QwtPainter::drawLine(painter,
r.left() + 1, r.top() + 2, r.left() + 1, r.bottom());
#endif
painter->setPen(QPen(dark, 1));
#if QT_VERSION >= 0x040000
QwtPainter::drawLine(painter,
r.right() + 1, r.top() + 1, r.right() + 1, r.bottom());
QwtPainter::drawLine(painter,
r.right(), r.top() + 2, r.right(), r.bottom() - 1);
#else
QwtPainter::drawLine(painter,
r.right() + 1, r.top() + 1, r.right() + 1, r.bottom() + 1);
QwtPainter::drawLine(painter,
r.right(), r.top() + 2, r.right(), r.bottom());
#endif
painter->restore();
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment