Commit 1de68ac3 authored by schultezub's avatar schultezub
Browse files

* little bug fix in DataContainerInspectorCanvas

 * added mouse wheel interaction to IxpvDemo

git-svn-id: https://camplinux.in.tum.de/svn/campvis/trunk@398 bb408c1c-ae56-11e1-83d9-df6b3e0c105e
parent 7fa00b85
......@@ -200,7 +200,7 @@ namespace campvis {
}
else {
for (int y = 0; y < _numTiles.y; ++y) {
for (int x = 0; x < _numTiles.y; ++x) {
for (int x = 0; x < _numTiles.x; ++x) {
int index = (_numTiles.x * y) + x;
if (index >= static_cast<int>(textures.size()))
break;
......
......@@ -81,8 +81,12 @@ namespace campvis {
/**
* Clips this MeshGeometry against an aribtrary clip plane.
* The clipped MeshGeometry is returned.
* \note When clipping against one of the faces of this mesh, the mesh closing
* algorithm might fail and return an invalid mesh!
* \param p Point on clip plane
* \param normal Clip plane normal
* \param close Flag, whether the returned mesh shall be closed.
* If true, the closing face will be the last one in the returned MeshGeometry.
* \param epsilon Clipping precision
* \return The clipped MeshGeometry
*/
......
......@@ -54,6 +54,7 @@ namespace campvis {
, _ixpvCompositor(_effectiveRenderTargetSize)
, _camera("camera", "Camera")
, _trackballHandler(0)
, _wheelHandler(&_usSliceRenderer.p_sliceNumber)
{
addProcessor(&_xrayReader);
......@@ -75,8 +76,8 @@ namespace campvis {
addProperty(&_camera);
_trackballHandler = new TrackballNavigationEventHandler(this, &_camera, _renderTargetSize);
addEventHandler(&_wheelHandler);
addEventHandler(_trackballHandler);
//addEventHandler(&_tfWindowingHandler);
}
IxpvDemo::~IxpvDemo() {
......@@ -202,9 +203,9 @@ namespace campvis {
_ctDVR.p_transferFunction.getTF()->setImageHandle(dh);
_ctDVR.p_transferFunction.getTF()->setIntensityDomain(tgt::vec2(ii.getLeft(), ii.getRight()));
_ctFullDRR.p_transferFunction.getTF()->setImageHandle(dh);
_ctFullDRR.p_transferFunction.getTF()->setIntensityDomain(tgt::vec2(.33f, .7f));
_ctFullDRR.p_transferFunction.getTF()->setIntensityDomain(tgt::vec2(.3f, .73f));
_ctClippedDRR.p_transferFunction.getTF()->setImageHandle(dh);
_ctClippedDRR.p_transferFunction.getTF()->setIntensityDomain(tgt::vec2(.33f, .7f));
_ctClippedDRR.p_transferFunction.getTF()->setIntensityDomain(tgt::vec2(.3f, .73f));
{
tgt::GLContextScopedLock lock(_canvas->getContext());
......
......@@ -32,7 +32,7 @@
#include "core/datastructures/imagedatalocal.h"
#include "core/eventhandlers/trackballnavigationeventhandler.h"
#include "core/eventhandlers/transfuncwindowingeventhandler.h"
#include "core/eventhandlers/mwheeltonumericpropertyeventhandler.h"
#include "core/properties/cameraproperty.h"
#include "core/pipeline/visualizationpipeline.h"
......@@ -97,6 +97,7 @@ namespace campvis {
CameraProperty _camera;
TrackballNavigationEventHandler* _trackballHandler;
MWheelToNumericPropertyEventHandler _wheelHandler;
};
}
......
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