Katana Plug-in APIs 0.1

NewFrameMessage.h

00001 // Copyright (c) 2012 The Foundry Visionmongers Ltd. All Rights Reserved.
00002 
00003 #ifndef NEWFRAMEMESSAGE_H
00004 #define NEWFRAMEMESSAGE_H
00005 
00006 #include <stdint.h>
00007 #include <string>
00008 
00009 #include "Message.h"
00010 
00011 namespace Foundry
00012 {
00013 namespace Katana
00014 {
00034 class NewFrameMessage : public Message
00035 {
00036 public:
00053     NewFrameMessage(float frameTime = 0.0,
00054                     uint32_t height = 0,
00055                     uint32_t width = 0,
00056                     int xorigin = 0,
00057                     int yorigin = 0);
00058 
00062     virtual ~NewFrameMessage() {}
00063 
00076     int setFrameName(const std::string& name);
00077 
00083     void setFrameTime(float time);
00084 
00091     void setFrameDimensions(uint32_t width, uint32_t height);
00092 
00101     void setFrameOrigin(int ox, int oy);
00102 
00109     const uint8_t* frameUUID() const;
00110 
00111     uint32_t frameHeight() const;
00112     uint32_t frameWidth() const;
00113     int frameXOrigin() const;
00114     int frameYOrigin() const;
00115     float frameTime() const;
00116     const std::string& frameName() const;
00117     uint32_t frameNameLength() const;
00118 
00119 private:
00120     NewFrameMessage(const NewFrameMessage& rhs);
00121     NewFrameMessage& operator=(const NewFrameMessage& rhs);
00122 
00123     mutable std::string _frameName;
00124 };
00125 
00135 void encodeLegacyName(const std::string& legacyFrameName,
00136                       int legacyFrameNumber,
00137                       std::string& buffer);
00138 
00142 }  // namespace Katana
00143 }  // namespace Foundry
00144 
00145 #endif
 All Classes Functions Variables Typedefs Enumerations Enumerator