Implement remote hybrid rendering server. More...
#include <rhr/rhrserver.h>
Classes | |
struct | ImageParameters |
struct | Light |
struct | Screen |
struct | ViewData |
struct | ViewParameters |
Public Types | |
typedef asio::ip::tcp::socket | socket |
typedef asio::ip::tcp::acceptor | acceptor |
typedef asio::ip::address | address |
typedef std::map< std::string, vistle::RenderObject::InitialVariantVisibility > | InitialVariantVisibilityMap |
typedef std::map< std::string, bool > | VariantVisibilityMap |
Public Member Functions | |
RhrServer (vistle::Module *module) | |
called when plugin is loaded More... | |
~RhrServer () | |
int | numClients () const |
bool | isConnecting () const |
bool | isConnected () const |
unsigned short | port () const |
unsigned short | destinationPort () const |
const std::string & | destinationHost () const |
void | setClientModuleId (int roduleId) |
int | width (size_t viewNum) const |
int | height (size_t viewNum) const |
unsigned char * | rgba (size_t viewNum) |
const unsigned char * | rgba (size_t viewNum) const |
float * | depth (size_t viewNum) |
const float * | depth (size_t viewNum) const |
void | resize (size_t viewNum, int w, int h) |
void | init () |
called after plug-in is loaded and scenegraph is initialized More... | |
bool | startServer (unsigned short port) |
bool | makeConnection (const std::string &host, unsigned short port, int secondsToTry=-1) |
void | preFrame () |
this is called before every frame, used for polling for RFB messages More... | |
ViewParameters | getViewParameters (int viewNum) const |
void | invalidate (int viewNum, int x, int y, int w, int h, const ViewParameters ¶m, bool lastView) |
void | updateModificationCount () |
void | setColorCodec (CompressionParameters::ColorCodec value) |
void | setDepthCodec (CompressionParameters::DepthCodec value) |
void | setColorCompression (message::CompressionMode mode) |
void | setDepthPrecision (int bits) |
void | setDepthCompression (message::CompressionMode mode) |
void | setTileSize (int w, int h) |
void | setZfpMode (CompressionParameters::ZfpMode mode) |
void | setDumpImages (bool enable) |
int | timestep () const |
void | setNumTimesteps (unsigned num) |
size_t | updateCount () const |
const VariantVisibilityMap & | getVariants () const |
bool | handleMessage (const vistle::message::Message *message, const vistle::MessagePayload &payload) |
bool | handleRemoteRenderMessage (std::shared_ptr< socket > sock, const vistle::message::RemoteRenderMessage &rr) |
bool | handleMatrices (std::shared_ptr< socket > sock, const matricesMsg &mat) |
handle matrix update message More... | |
bool | handleLights (std::shared_ptr< socket > sock, const lightsMsg &light) |
handle light update message More... | |
bool | handleBounds (std::shared_ptr< socket > sock, const boundsMsg &bound) |
handle request for a bounding sphere update More... | |
bool | handleAnimation (std::shared_ptr< socket > sock, const animationMsg &anim) |
bool | handleVariant (std::shared_ptr< socket > sock, const variantMsg &variant) |
size_t | numViews () const |
const vistle::Matrix4 & | viewMat (size_t viewNum) const |
const vistle::Matrix4 & | projMat (size_t viewNum) const |
const vistle::Matrix4 & | modelMat (size_t viewNum) const |
void | setBoundingSphere (const vistle::Vector3 ¢er, const vistle::Scalar &radius) |
void | updateVariants (const std::vector< std::pair< std::string, vistle::RenderObject::InitialVariantVisibility > > &added, const std::vector< std::string > &removed) |
Public Attributes | |
std::vector< Light > | lights |
size_t | lightsUpdateCount |
Friends | |
struct | EncodeTask |
Implement remote hybrid rendering server.
typedef asio::ip::tcp::acceptor vistle::RhrServer::acceptor |
typedef asio::ip::address vistle::RhrServer::address |
typedef std::map<std::string, vistle::RenderObject::InitialVariantVisibility> vistle::RhrServer::InitialVariantVisibilityMap |
typedef asio::ip::tcp::socket vistle::RhrServer::socket |
typedef std::map<std::string, bool> vistle::RhrServer::VariantVisibilityMap |
|
explicit |
called when plugin is loaded
vistle::RhrServer::~RhrServer | ( | ) |
float * vistle::RhrServer::depth | ( | size_t | viewNum | ) |
const float * vistle::RhrServer::depth | ( | size_t | viewNum | ) | const |
const std::string & vistle::RhrServer::destinationHost | ( | ) | const |
unsigned short vistle::RhrServer::destinationPort | ( | ) | const |
const RhrServer::VariantVisibilityMap & vistle::RhrServer::getVariants | ( | ) | const |
RhrServer::ViewParameters vistle::RhrServer::getViewParameters | ( | int | viewNum | ) | const |
bool vistle::RhrServer::handleAnimation | ( | std::shared_ptr< socket > | sock, |
const animationMsg & | anim | ||
) |
handle request for a bounding sphere update
handle light update message
bool vistle::RhrServer::handleMatrices | ( | std::shared_ptr< socket > | sock, |
const matricesMsg & | mat | ||
) |
handle matrix update message
bool vistle::RhrServer::handleMessage | ( | const vistle::message::Message * | message, |
const vistle::MessagePayload & | payload | ||
) |
bool vistle::RhrServer::handleRemoteRenderMessage | ( | std::shared_ptr< socket > | sock, |
const vistle::message::RemoteRenderMessage & | rr | ||
) |
bool vistle::RhrServer::handleVariant | ( | std::shared_ptr< socket > | sock, |
const variantMsg & | variant | ||
) |
int vistle::RhrServer::height | ( | size_t | viewNum | ) | const |
void vistle::RhrServer::init | ( | ) |
called after plug-in is loaded and scenegraph is initialized
void vistle::RhrServer::invalidate | ( | int | viewNum, |
int | x, | ||
int | y, | ||
int | w, | ||
int | h, | ||
const ViewParameters & | param, | ||
bool | lastView | ||
) |
bool vistle::RhrServer::isConnected | ( | ) | const |
bool vistle::RhrServer::isConnecting | ( | ) | const |
bool vistle::RhrServer::makeConnection | ( | const std::string & | host, |
unsigned short | port, | ||
int | secondsToTry = -1 |
||
) |
const vistle::Matrix4 & vistle::RhrServer::modelMat | ( | size_t | viewNum | ) | const |
int vistle::RhrServer::numClients | ( | ) | const |
size_t vistle::RhrServer::numViews | ( | ) | const |
unsigned short vistle::RhrServer::port | ( | ) | const |
void vistle::RhrServer::preFrame | ( | ) |
this is called before every frame, used for polling for RFB messages
const vistle::Matrix4 & vistle::RhrServer::projMat | ( | size_t | viewNum | ) | const |
void vistle::RhrServer::resize | ( | size_t | viewNum, |
int | w, | ||
int | h | ||
) |
unsigned char * vistle::RhrServer::rgba | ( | size_t | viewNum | ) |
const unsigned char * vistle::RhrServer::rgba | ( | size_t | viewNum | ) | const |
void vistle::RhrServer::setBoundingSphere | ( | const vistle::Vector3 & | center, |
const vistle::Scalar & | radius | ||
) |
void vistle::RhrServer::setClientModuleId | ( | int | roduleId | ) |
void vistle::RhrServer::setColorCodec | ( | CompressionParameters::ColorCodec | value | ) |
void vistle::RhrServer::setColorCompression | ( | message::CompressionMode | mode | ) |
void vistle::RhrServer::setDepthCodec | ( | CompressionParameters::DepthCodec | value | ) |
void vistle::RhrServer::setDepthCompression | ( | message::CompressionMode | mode | ) |
void vistle::RhrServer::setDepthPrecision | ( | int | bits | ) |
void vistle::RhrServer::setDumpImages | ( | bool | enable | ) |
void vistle::RhrServer::setNumTimesteps | ( | unsigned | num | ) |
void vistle::RhrServer::setTileSize | ( | int | w, |
int | h | ||
) |
void vistle::RhrServer::setZfpMode | ( | CompressionParameters::ZfpMode | mode | ) |
bool vistle::RhrServer::startServer | ( | unsigned short | port | ) |
int vistle::RhrServer::timestep | ( | ) | const |
size_t vistle::RhrServer::updateCount | ( | ) | const |
void vistle::RhrServer::updateModificationCount | ( | ) |
void vistle::RhrServer::updateVariants | ( | const std::vector< std::pair< std::string, vistle::RenderObject::InitialVariantVisibility > > & | added, |
const std::vector< std::string > & | removed | ||
) |
const vistle::Matrix4 & vistle::RhrServer::viewMat | ( | size_t | viewNum | ) | const |
int vistle::RhrServer::width | ( | size_t | viewNum | ) | const |
|
friend |
std::vector<Light> vistle::RhrServer::lights |
size_t vistle::RhrServer::lightsUpdateCount |