1/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2008 Robert Osfield
3 * This library is open source and may be redistributed and/or modified under
4 * the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
5 * (at your option) any later version. The full license is in LICENSE file
6 * included with this distribution, and on the openscenegraph.org website.
8 * This library is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * OpenSceneGraph Public License for more details.
14#ifndef OSGWIDGET_VNCCLIENT
15#define OSGWIDGET_VNCCLIENT
17#include <osgDB/ReaderWriter>
19#include <osgWidget/PdfReader>
23/** Pure virtual base class for VncImage that is sublcassed by vnc plugin to provide the actual implementation.*/
24class VncImage : public osg::Image
30 virtual bool connect(const std::string& hostname) = 0;
32 virtual void close() = 0;
36 virtual ~VncImage() {}
41/** Convenience Vnc Client class that provides a interactive quad that can be placed directly in the scene.*/
42class OSGWIDGET_EXPORT VncClient : public osg::Geode
48 VncClient(const std::string& hostname, const GeometryHints& hints = GeometryHints());
50 bool assign(VncImage* vncImage, const GeometryHints& hints = GeometryHints());
52 bool connect(const std::string& hostname, const GeometryHints& hints = GeometryHints());
58 osg::ref_ptr<VncImage> _vncImage;