/* this file has been autogenerated by vtkNodeJsWrap */
/* editing this might proof futile */

#define VTK_WRAPPING_CXX
#define VTK_STREAMS_FWD_ONLY
#include <nan.h>

#include "vtkSliderRepresentationWrap.h"
#include "vtkSliderRepresentation3DWrap.h"
#include "vtkObjectBaseWrap.h"
#include "vtkCoordinateWrap.h"
#include "vtkPropertyWrap.h"
#include "vtkPropCollectionWrap.h"
#include "vtkWindowWrap.h"
#include "vtkViewportWrap.h"
#include "../../plus/plus.h"

using namespace v8;

extern Nan::Persistent<v8::Object> vtkNodeJsNoWrap;
Nan::Persistent<v8::FunctionTemplate> VtkSliderRepresentation3DWrap::ptpl;

VtkSliderRepresentation3DWrap::VtkSliderRepresentation3DWrap()
{ }

VtkSliderRepresentation3DWrap::VtkSliderRepresentation3DWrap(vtkSmartPointer<vtkSliderRepresentation3D> _native)
{ native = _native; }

VtkSliderRepresentation3DWrap::~VtkSliderRepresentation3DWrap()
{ }

void VtkSliderRepresentation3DWrap::Init(v8::Local<v8::Object> exports)
{
	Nan::SetAccessor(exports, Nan::New("vtkSliderRepresentation3D").ToLocalChecked(), ConstructorGetter);
	Nan::SetAccessor(exports, Nan::New("SliderRepresentation3D").ToLocalChecked(), ConstructorGetter);
}

void VtkSliderRepresentation3DWrap::ConstructorGetter(
	v8::Local<v8::String> property,
	const Nan::PropertyCallbackInfo<v8::Value>& info)
{
	InitPtpl();
	info.GetReturnValue().Set(Nan::New(ptpl)->GetFunction());
}

void VtkSliderRepresentation3DWrap::InitPtpl()
{
	if (!ptpl.IsEmpty()) return;
	v8::Local<v8::FunctionTemplate> tpl = Nan::New<v8::FunctionTemplate>(New);
	VtkSliderRepresentationWrap::InitPtpl( );
	tpl->Inherit(Nan::New<FunctionTemplate>(VtkSliderRepresentationWrap::ptpl));
	tpl->SetClassName(Nan::New("VtkSliderRepresentation3DWrap").ToLocalChecked());
	tpl->InstanceTemplate()->SetInternalFieldCount(1);

	Nan::SetPrototypeMethod(tpl, "BuildRepresentation", BuildRepresentation);
	Nan::SetPrototypeMethod(tpl, "buildRepresentation", BuildRepresentation);

	Nan::SetPrototypeMethod(tpl, "GetActors", GetActors);
	Nan::SetPrototypeMethod(tpl, "getActors", GetActors);

	Nan::SetPrototypeMethod(tpl, "GetBounds", GetBounds);
	Nan::SetPrototypeMethod(tpl, "getBounds", GetBounds);

	Nan::SetPrototypeMethod(tpl, "GetCapProperty", GetCapProperty);
	Nan::SetPrototypeMethod(tpl, "getCapProperty", GetCapProperty);

	Nan::SetPrototypeMethod(tpl, "GetPoint1Coordinate", GetPoint1Coordinate);
	Nan::SetPrototypeMethod(tpl, "getPoint1Coordinate", GetPoint1Coordinate);

	Nan::SetPrototypeMethod(tpl, "GetPoint2Coordinate", GetPoint2Coordinate);
	Nan::SetPrototypeMethod(tpl, "getPoint2Coordinate", GetPoint2Coordinate);

	Nan::SetPrototypeMethod(tpl, "GetRotation", GetRotation);
	Nan::SetPrototypeMethod(tpl, "getRotation", GetRotation);

	Nan::SetPrototypeMethod(tpl, "GetSelectedProperty", GetSelectedProperty);
	Nan::SetPrototypeMethod(tpl, "getSelectedProperty", GetSelectedProperty);

	Nan::SetPrototypeMethod(tpl, "GetSliderProperty", GetSliderProperty);
	Nan::SetPrototypeMethod(tpl, "getSliderProperty", GetSliderProperty);

	Nan::SetPrototypeMethod(tpl, "GetSliderShape", GetSliderShape);
	Nan::SetPrototypeMethod(tpl, "getSliderShape", GetSliderShape);

	Nan::SetPrototypeMethod(tpl, "GetSliderShapeMaxValue", GetSliderShapeMaxValue);
	Nan::SetPrototypeMethod(tpl, "getSliderShapeMaxValue", GetSliderShapeMaxValue);

	Nan::SetPrototypeMethod(tpl, "GetSliderShapeMinValue", GetSliderShapeMinValue);
	Nan::SetPrototypeMethod(tpl, "getSliderShapeMinValue", GetSliderShapeMinValue);

	Nan::SetPrototypeMethod(tpl, "GetTitleText", GetTitleText);
	Nan::SetPrototypeMethod(tpl, "getTitleText", GetTitleText);

	Nan::SetPrototypeMethod(tpl, "GetTubeProperty", GetTubeProperty);
	Nan::SetPrototypeMethod(tpl, "getTubeProperty", GetTubeProperty);

	Nan::SetPrototypeMethod(tpl, "HasTranslucentPolygonalGeometry", HasTranslucentPolygonalGeometry);
	Nan::SetPrototypeMethod(tpl, "hasTranslucentPolygonalGeometry", HasTranslucentPolygonalGeometry);

	Nan::SetPrototypeMethod(tpl, "Highlight", Highlight);
	Nan::SetPrototypeMethod(tpl, "highlight", Highlight);

	Nan::SetPrototypeMethod(tpl, "NewInstance", NewInstance);
	Nan::SetPrototypeMethod(tpl, "newInstance", NewInstance);

	Nan::SetPrototypeMethod(tpl, "PlaceWidget", PlaceWidget);
	Nan::SetPrototypeMethod(tpl, "placeWidget", PlaceWidget);

	Nan::SetPrototypeMethod(tpl, "ReleaseGraphicsResources", ReleaseGraphicsResources);
	Nan::SetPrototypeMethod(tpl, "releaseGraphicsResources", ReleaseGraphicsResources);

	Nan::SetPrototypeMethod(tpl, "RenderOpaqueGeometry", RenderOpaqueGeometry);
	Nan::SetPrototypeMethod(tpl, "renderOpaqueGeometry", RenderOpaqueGeometry);

	Nan::SetPrototypeMethod(tpl, "RenderTranslucentPolygonalGeometry", RenderTranslucentPolygonalGeometry);
	Nan::SetPrototypeMethod(tpl, "renderTranslucentPolygonalGeometry", RenderTranslucentPolygonalGeometry);

	Nan::SetPrototypeMethod(tpl, "SafeDownCast", SafeDownCast);
	Nan::SetPrototypeMethod(tpl, "safeDownCast", SafeDownCast);

	Nan::SetPrototypeMethod(tpl, "SetPoint1InWorldCoordinates", SetPoint1InWorldCoordinates);
	Nan::SetPrototypeMethod(tpl, "setPoint1InWorldCoordinates", SetPoint1InWorldCoordinates);

	Nan::SetPrototypeMethod(tpl, "SetPoint2InWorldCoordinates", SetPoint2InWorldCoordinates);
	Nan::SetPrototypeMethod(tpl, "setPoint2InWorldCoordinates", SetPoint2InWorldCoordinates);

	Nan::SetPrototypeMethod(tpl, "SetRotation", SetRotation);
	Nan::SetPrototypeMethod(tpl, "setRotation", SetRotation);

	Nan::SetPrototypeMethod(tpl, "SetSliderShape", SetSliderShape);
	Nan::SetPrototypeMethod(tpl, "setSliderShape", SetSliderShape);

	Nan::SetPrototypeMethod(tpl, "SetSliderShapeToCylinder", SetSliderShapeToCylinder);
	Nan::SetPrototypeMethod(tpl, "setSliderShapeToCylinder", SetSliderShapeToCylinder);

	Nan::SetPrototypeMethod(tpl, "SetSliderShapeToSphere", SetSliderShapeToSphere);
	Nan::SetPrototypeMethod(tpl, "setSliderShapeToSphere", SetSliderShapeToSphere);

	Nan::SetPrototypeMethod(tpl, "SetTitleText", SetTitleText);
	Nan::SetPrototypeMethod(tpl, "setTitleText", SetTitleText);

	Nan::SetPrototypeMethod(tpl, "StartWidgetInteraction", StartWidgetInteraction);
	Nan::SetPrototypeMethod(tpl, "startWidgetInteraction", StartWidgetInteraction);

	Nan::SetPrototypeMethod(tpl, "WidgetInteraction", WidgetInteraction);
	Nan::SetPrototypeMethod(tpl, "widgetInteraction", WidgetInteraction);

#ifdef VTK_NODE_PLUS_VTKSLIDERREPRESENTATION3DWRAP_INITPTPL
	VTK_NODE_PLUS_VTKSLIDERREPRESENTATION3DWRAP_INITPTPL
#endif
	ptpl.Reset( tpl );
}

void VtkSliderRepresentation3DWrap::New(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	if(!info.IsConstructCall())
	{
		Nan::ThrowError("Constructor not called in a construct call.");
		return;
	}

	if(info.Length() == 0)
	{
		vtkSmartPointer<vtkSliderRepresentation3D> native = vtkSmartPointer<vtkSliderRepresentation3D>::New();
		VtkSliderRepresentation3DWrap* obj = new VtkSliderRepresentation3DWrap(native);
		obj->Wrap(info.This());
	}
	else
	{
		if(info[0]->ToObject() != vtkNodeJsNoWrap )
		{
			Nan::ThrowError("Parameter Error");
			return;
		}
	}

	info.GetReturnValue().Set(info.This());
}

void VtkSliderRepresentation3DWrap::BuildRepresentation(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
		if(info.Length() != 0)
	{
		Nan::ThrowError("Too many parameters.");
		return;
	}
	native->BuildRepresentation();
}

void VtkSliderRepresentation3DWrap::GetActors(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	if(info.Length() > 0 && info[0]->IsObject() && (Nan::New(VtkPropCollectionWrap::ptpl))->HasInstance(info[0]))
	{
		VtkPropCollectionWrap *a0 = ObjectWrap::Unwrap<VtkPropCollectionWrap>(info[0]->ToObject());
				if(info.Length() != 1)
		{
			Nan::ThrowError("Too many parameters.");
			return;
		}
		native->GetActors(
			(vtkPropCollection *) a0->native.GetPointer()
		);
		return;
	}
	Nan::ThrowError("Parameter mismatch");
}

void VtkSliderRepresentation3DWrap::GetBounds(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	double const * r;
	if(info.Length() != 0)
	{
		Nan::ThrowError("Too many parameters.");
		return;
	}
	r = native->GetBounds();
	Local<v8::ArrayBuffer> ab = v8::ArrayBuffer::New(v8::Isolate::GetCurrent(), 6 * sizeof(double));
	Local<v8::Float64Array> at = v8::Float64Array::New(ab, 0, 6);
	memcpy(ab->GetContents().Data(), r, 6 * sizeof(double));
	info.GetReturnValue().Set(at);
}

void VtkSliderRepresentation3DWrap::GetCapProperty(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	vtkProperty * r;
	if(info.Length() != 0)
	{
		Nan::ThrowError("Too many parameters.");
		return;
	}
	r = native->GetCapProperty();
	VtkPropertyWrap::InitPtpl();
	v8::Local<v8::Value> argv[1] =
		{ Nan::New(vtkNodeJsNoWrap) };
	v8::Local<v8::Function> cons =
		Nan::New<v8::FunctionTemplate>(VtkPropertyWrap::ptpl)->GetFunction();
	v8::Local<v8::Object> wo = cons->NewInstance(1, argv);
	VtkPropertyWrap *w = new VtkPropertyWrap();
	w->native = r;
	w->Wrap(wo);
	info.GetReturnValue().Set(wo);
}

void VtkSliderRepresentation3DWrap::GetPoint1Coordinate(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	vtkCoordinate * r;
	if(info.Length() != 0)
	{
		Nan::ThrowError("Too many parameters.");
		return;
	}
	r = native->GetPoint1Coordinate();
	VtkCoordinateWrap::InitPtpl();
	v8::Local<v8::Value> argv[1] =
		{ Nan::New(vtkNodeJsNoWrap) };
	v8::Local<v8::Function> cons =
		Nan::New<v8::FunctionTemplate>(VtkCoordinateWrap::ptpl)->GetFunction();
	v8::Local<v8::Object> wo = cons->NewInstance(1, argv);
	VtkCoordinateWrap *w = new VtkCoordinateWrap();
	w->native = r;
	w->Wrap(wo);
	info.GetReturnValue().Set(wo);
}

void VtkSliderRepresentation3DWrap::GetPoint2Coordinate(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	vtkCoordinate * r;
	if(info.Length() != 0)
	{
		Nan::ThrowError("Too many parameters.");
		return;
	}
	r = native->GetPoint2Coordinate();
	VtkCoordinateWrap::InitPtpl();
	v8::Local<v8::Value> argv[1] =
		{ Nan::New(vtkNodeJsNoWrap) };
	v8::Local<v8::Function> cons =
		Nan::New<v8::FunctionTemplate>(VtkCoordinateWrap::ptpl)->GetFunction();
	v8::Local<v8::Object> wo = cons->NewInstance(1, argv);
	VtkCoordinateWrap *w = new VtkCoordinateWrap();
	w->native = r;
	w->Wrap(wo);
	info.GetReturnValue().Set(wo);
}

void VtkSliderRepresentation3DWrap::GetRotation(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	double r;
	if(info.Length() != 0)
	{
		Nan::ThrowError("Too many parameters.");
		return;
	}
	r = native->GetRotation();
	info.GetReturnValue().Set(Nan::New(r));
}

void VtkSliderRepresentation3DWrap::GetSelectedProperty(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	vtkProperty * r;
	if(info.Length() != 0)
	{
		Nan::ThrowError("Too many parameters.");
		return;
	}
	r = native->GetSelectedProperty();
	VtkPropertyWrap::InitPtpl();
	v8::Local<v8::Value> argv[1] =
		{ Nan::New(vtkNodeJsNoWrap) };
	v8::Local<v8::Function> cons =
		Nan::New<v8::FunctionTemplate>(VtkPropertyWrap::ptpl)->GetFunction();
	v8::Local<v8::Object> wo = cons->NewInstance(1, argv);
	VtkPropertyWrap *w = new VtkPropertyWrap();
	w->native = r;
	w->Wrap(wo);
	info.GetReturnValue().Set(wo);
}

void VtkSliderRepresentation3DWrap::GetSliderProperty(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	vtkProperty * r;
	if(info.Length() != 0)
	{
		Nan::ThrowError("Too many parameters.");
		return;
	}
	r = native->GetSliderProperty();
	VtkPropertyWrap::InitPtpl();
	v8::Local<v8::Value> argv[1] =
		{ Nan::New(vtkNodeJsNoWrap) };
	v8::Local<v8::Function> cons =
		Nan::New<v8::FunctionTemplate>(VtkPropertyWrap::ptpl)->GetFunction();
	v8::Local<v8::Object> wo = cons->NewInstance(1, argv);
	VtkPropertyWrap *w = new VtkPropertyWrap();
	w->native = r;
	w->Wrap(wo);
	info.GetReturnValue().Set(wo);
}

void VtkSliderRepresentation3DWrap::GetSliderShape(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	int r;
	if(info.Length() != 0)
	{
		Nan::ThrowError("Too many parameters.");
		return;
	}
	r = native->GetSliderShape();
	info.GetReturnValue().Set(Nan::New(r));
}

void VtkSliderRepresentation3DWrap::GetSliderShapeMaxValue(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	int r;
	if(info.Length() != 0)
	{
		Nan::ThrowError("Too many parameters.");
		return;
	}
	r = native->GetSliderShapeMaxValue();
	info.GetReturnValue().Set(Nan::New(r));
}

void VtkSliderRepresentation3DWrap::GetSliderShapeMinValue(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	int r;
	if(info.Length() != 0)
	{
		Nan::ThrowError("Too many parameters.");
		return;
	}
	r = native->GetSliderShapeMinValue();
	info.GetReturnValue().Set(Nan::New(r));
}

void VtkSliderRepresentation3DWrap::GetTitleText(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	char const * r;
	if(info.Length() != 0)
	{
		Nan::ThrowError("Too many parameters.");
		return;
	}
	r = native->GetTitleText();
	info.GetReturnValue().Set(Nan::New(r).ToLocalChecked());
}

void VtkSliderRepresentation3DWrap::GetTubeProperty(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	vtkProperty * r;
	if(info.Length() != 0)
	{
		Nan::ThrowError("Too many parameters.");
		return;
	}
	r = native->GetTubeProperty();
	VtkPropertyWrap::InitPtpl();
	v8::Local<v8::Value> argv[1] =
		{ Nan::New(vtkNodeJsNoWrap) };
	v8::Local<v8::Function> cons =
		Nan::New<v8::FunctionTemplate>(VtkPropertyWrap::ptpl)->GetFunction();
	v8::Local<v8::Object> wo = cons->NewInstance(1, argv);
	VtkPropertyWrap *w = new VtkPropertyWrap();
	w->native = r;
	w->Wrap(wo);
	info.GetReturnValue().Set(wo);
}

void VtkSliderRepresentation3DWrap::HasTranslucentPolygonalGeometry(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	int r;
	if(info.Length() != 0)
	{
		Nan::ThrowError("Too many parameters.");
		return;
	}
	r = native->HasTranslucentPolygonalGeometry();
	info.GetReturnValue().Set(Nan::New(r));
}

void VtkSliderRepresentation3DWrap::Highlight(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	if(info.Length() > 0 && info[0]->IsInt32())
	{
				if(info.Length() != 1)
		{
			Nan::ThrowError("Too many parameters.");
			return;
		}
		native->Highlight(
			info[0]->Int32Value()
		);
		return;
	}
	Nan::ThrowError("Parameter mismatch");
}

void VtkSliderRepresentation3DWrap::NewInstance(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	vtkSliderRepresentation3D * r;
	if(info.Length() != 0)
	{
		Nan::ThrowError("Too many parameters.");
		return;
	}
	r = native->NewInstance();
	VtkSliderRepresentation3DWrap::InitPtpl();
	v8::Local<v8::Value> argv[1] =
		{ Nan::New(vtkNodeJsNoWrap) };
	v8::Local<v8::Function> cons =
		Nan::New<v8::FunctionTemplate>(VtkSliderRepresentation3DWrap::ptpl)->GetFunction();
	v8::Local<v8::Object> wo = cons->NewInstance(1, argv);
	VtkSliderRepresentation3DWrap *w = new VtkSliderRepresentation3DWrap();
	w->native = r;
	w->Wrap(wo);
	info.GetReturnValue().Set(wo);
}

void VtkSliderRepresentation3DWrap::PlaceWidget(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	size_t i;
	if(info.Length() > 0 && info[0]->IsFloat64Array())
	{
		v8::Local<v8::Float64Array>a0(v8::Local<v8::Float64Array>::Cast(info[0]->ToObject()));
		if( a0->Length() < 6 )
		{
			Nan::ThrowError("Array too short.");
			return;
		}

				if(info.Length() != 1)
		{
			Nan::ThrowError("Too many parameters.");
			return;
		}
		native->PlaceWidget(
			(double *)(a0->Buffer()->GetContents().Data())
		);
		return;
	}
	else if(info.Length() > 0 && info[0]->IsArray())
	{
		v8::Local<v8::Array>a0(v8::Local<v8::Array>::Cast(info[0]->ToObject()));
		double b0[6];
		if( a0->Length() < 6 )
		{
			Nan::ThrowError("Array too short.");
			return;
		}

		for( i = 0; i < 6; i++ )
		{
			if( !a0->Get(i)->IsNumber() )
			{
				Nan::ThrowError("Array contents invalid.");
				return;
			}
			b0[i] = a0->Get(i)->NumberValue();
		}
				if(info.Length() != 1)
		{
			Nan::ThrowError("Too many parameters.");
			return;
		}
		native->PlaceWidget(
			b0
		);
		return;
	}
	Nan::ThrowError("Parameter mismatch");
}

void VtkSliderRepresentation3DWrap::ReleaseGraphicsResources(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	if(info.Length() > 0 && info[0]->IsObject() && (Nan::New(VtkWindowWrap::ptpl))->HasInstance(info[0]))
	{
		VtkWindowWrap *a0 = ObjectWrap::Unwrap<VtkWindowWrap>(info[0]->ToObject());
				if(info.Length() != 1)
		{
			Nan::ThrowError("Too many parameters.");
			return;
		}
		native->ReleaseGraphicsResources(
			(vtkWindow *) a0->native.GetPointer()
		);
		return;
	}
	Nan::ThrowError("Parameter mismatch");
}

void VtkSliderRepresentation3DWrap::RenderOpaqueGeometry(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	if(info.Length() > 0 && info[0]->IsObject() && (Nan::New(VtkViewportWrap::ptpl))->HasInstance(info[0]))
	{
		VtkViewportWrap *a0 = ObjectWrap::Unwrap<VtkViewportWrap>(info[0]->ToObject());
		int r;
		if(info.Length() != 1)
		{
			Nan::ThrowError("Too many parameters.");
			return;
		}
		r = native->RenderOpaqueGeometry(
			(vtkViewport *) a0->native.GetPointer()
		);
		info.GetReturnValue().Set(Nan::New(r));
		return;
	}
	Nan::ThrowError("Parameter mismatch");
}

void VtkSliderRepresentation3DWrap::RenderTranslucentPolygonalGeometry(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	if(info.Length() > 0 && info[0]->IsObject() && (Nan::New(VtkViewportWrap::ptpl))->HasInstance(info[0]))
	{
		VtkViewportWrap *a0 = ObjectWrap::Unwrap<VtkViewportWrap>(info[0]->ToObject());
		int r;
		if(info.Length() != 1)
		{
			Nan::ThrowError("Too many parameters.");
			return;
		}
		r = native->RenderTranslucentPolygonalGeometry(
			(vtkViewport *) a0->native.GetPointer()
		);
		info.GetReturnValue().Set(Nan::New(r));
		return;
	}
	Nan::ThrowError("Parameter mismatch");
}

void VtkSliderRepresentation3DWrap::SafeDownCast(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	if(info.Length() > 0 && info[0]->IsObject() && (Nan::New(VtkObjectBaseWrap::ptpl))->HasInstance(info[0]))
	{
		VtkObjectBaseWrap *a0 = ObjectWrap::Unwrap<VtkObjectBaseWrap>(info[0]->ToObject());
		vtkSliderRepresentation3D * r;
		if(info.Length() != 1)
		{
			Nan::ThrowError("Too many parameters.");
			return;
		}
		r = native->SafeDownCast(
			(vtkObjectBase *) a0->native.GetPointer()
		);
		VtkSliderRepresentation3DWrap::InitPtpl();
		v8::Local<v8::Value> argv[1] =
			{ Nan::New(vtkNodeJsNoWrap) };
		v8::Local<v8::Function> cons =
			Nan::New<v8::FunctionTemplate>(VtkSliderRepresentation3DWrap::ptpl)->GetFunction();
		v8::Local<v8::Object> wo = cons->NewInstance(1, argv);
		VtkSliderRepresentation3DWrap *w = new VtkSliderRepresentation3DWrap();
		w->native = r;
		w->Wrap(wo);
		info.GetReturnValue().Set(wo);
		return;
	}
	Nan::ThrowError("Parameter mismatch");
}

void VtkSliderRepresentation3DWrap::SetPoint1InWorldCoordinates(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	if(info.Length() > 0 && info[0]->IsNumber())
	{
		if(info.Length() > 1 && info[1]->IsNumber())
		{
			if(info.Length() > 2 && info[2]->IsNumber())
			{
								if(info.Length() != 3)
				{
					Nan::ThrowError("Too many parameters.");
					return;
				}
				native->SetPoint1InWorldCoordinates(
					info[0]->NumberValue(),
					info[1]->NumberValue(),
					info[2]->NumberValue()
				);
				return;
			}
		}
	}
	Nan::ThrowError("Parameter mismatch");
}

void VtkSliderRepresentation3DWrap::SetPoint2InWorldCoordinates(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	if(info.Length() > 0 && info[0]->IsNumber())
	{
		if(info.Length() > 1 && info[1]->IsNumber())
		{
			if(info.Length() > 2 && info[2]->IsNumber())
			{
								if(info.Length() != 3)
				{
					Nan::ThrowError("Too many parameters.");
					return;
				}
				native->SetPoint2InWorldCoordinates(
					info[0]->NumberValue(),
					info[1]->NumberValue(),
					info[2]->NumberValue()
				);
				return;
			}
		}
	}
	Nan::ThrowError("Parameter mismatch");
}

void VtkSliderRepresentation3DWrap::SetRotation(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	if(info.Length() > 0 && info[0]->IsNumber())
	{
				if(info.Length() != 1)
		{
			Nan::ThrowError("Too many parameters.");
			return;
		}
		native->SetRotation(
			info[0]->NumberValue()
		);
		return;
	}
	Nan::ThrowError("Parameter mismatch");
}

void VtkSliderRepresentation3DWrap::SetSliderShape(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	if(info.Length() > 0 && info[0]->IsInt32())
	{
				if(info.Length() != 1)
		{
			Nan::ThrowError("Too many parameters.");
			return;
		}
		native->SetSliderShape(
			info[0]->Int32Value()
		);
		return;
	}
	Nan::ThrowError("Parameter mismatch");
}

void VtkSliderRepresentation3DWrap::SetSliderShapeToCylinder(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
		if(info.Length() != 0)
	{
		Nan::ThrowError("Too many parameters.");
		return;
	}
	native->SetSliderShapeToCylinder();
}

void VtkSliderRepresentation3DWrap::SetSliderShapeToSphere(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
		if(info.Length() != 0)
	{
		Nan::ThrowError("Too many parameters.");
		return;
	}
	native->SetSliderShapeToSphere();
}

void VtkSliderRepresentation3DWrap::SetTitleText(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	if(info.Length() > 0 && info[0]->IsString())
	{
		Nan::Utf8String a0(info[0]);
				if(info.Length() != 1)
		{
			Nan::ThrowError("Too many parameters.");
			return;
		}
		native->SetTitleText(
			*a0
		);
		return;
	}
	Nan::ThrowError("Parameter mismatch");
}

void VtkSliderRepresentation3DWrap::StartWidgetInteraction(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	size_t i;
	if(info.Length() > 0 && info[0]->IsFloat64Array())
	{
		v8::Local<v8::Float64Array>a0(v8::Local<v8::Float64Array>::Cast(info[0]->ToObject()));
		if( a0->Length() < 2 )
		{
			Nan::ThrowError("Array too short.");
			return;
		}

				if(info.Length() != 1)
		{
			Nan::ThrowError("Too many parameters.");
			return;
		}
		native->StartWidgetInteraction(
			(double *)(a0->Buffer()->GetContents().Data())
		);
		return;
	}
	else if(info.Length() > 0 && info[0]->IsArray())
	{
		v8::Local<v8::Array>a0(v8::Local<v8::Array>::Cast(info[0]->ToObject()));
		double b0[2];
		if( a0->Length() < 2 )
		{
			Nan::ThrowError("Array too short.");
			return;
		}

		for( i = 0; i < 2; i++ )
		{
			if( !a0->Get(i)->IsNumber() )
			{
				Nan::ThrowError("Array contents invalid.");
				return;
			}
			b0[i] = a0->Get(i)->NumberValue();
		}
				if(info.Length() != 1)
		{
			Nan::ThrowError("Too many parameters.");
			return;
		}
		native->StartWidgetInteraction(
			b0
		);
		return;
	}
	Nan::ThrowError("Parameter mismatch");
}

void VtkSliderRepresentation3DWrap::WidgetInteraction(const Nan::FunctionCallbackInfo<v8::Value>& info)
{
	VtkSliderRepresentation3DWrap *wrapper = ObjectWrap::Unwrap<VtkSliderRepresentation3DWrap>(info.Holder());
	vtkSliderRepresentation3D *native = (vtkSliderRepresentation3D *)wrapper->native.GetPointer();
	size_t i;
	if(info.Length() > 0 && info[0]->IsFloat64Array())
	{
		v8::Local<v8::Float64Array>a0(v8::Local<v8::Float64Array>::Cast(info[0]->ToObject()));
		if( a0->Length() < 2 )
		{
			Nan::ThrowError("Array too short.");
			return;
		}

				if(info.Length() != 1)
		{
			Nan::ThrowError("Too many parameters.");
			return;
		}
		native->WidgetInteraction(
			(double *)(a0->Buffer()->GetContents().Data())
		);
		return;
	}
	else if(info.Length() > 0 && info[0]->IsArray())
	{
		v8::Local<v8::Array>a0(v8::Local<v8::Array>::Cast(info[0]->ToObject()));
		double b0[2];
		if( a0->Length() < 2 )
		{
			Nan::ThrowError("Array too short.");
			return;
		}

		for( i = 0; i < 2; i++ )
		{
			if( !a0->Get(i)->IsNumber() )
			{
				Nan::ThrowError("Array contents invalid.");
				return;
			}
			b0[i] = a0->Get(i)->NumberValue();
		}
				if(info.Length() != 1)
		{
			Nan::ThrowError("Too many parameters.");
			return;
		}
		native->WidgetInteraction(
			b0
		);
		return;
	}
	Nan::ThrowError("Parameter mismatch");
}

