Ri2DWindow

Encapsulates a glut window for 2D drawing.

[ Gui | Source | Search | Keywords | Summary | Ancestors | All Members | Descendants ]

Quick Index

DESCRIPTION
KEYBOARD BINDINGS

Class Summary

class Ri2DWindow : public RiWindow
{
public:
// Constructors and assignment
Ri2DWindow(int sizeX , int sizeY , int posX , int posY );
// Accessors
void SetTranslateFraction(RiReal newFraction);
void SetScaleBase(RiReal newBase);
// Members
protected:
void PrintHelp();
void Keyboard(unsigned char key, int x, int y);
void Reshape();
void DoOpen();
void DoSetSize();
RiReal GetTranslateX();
RiReal GetTranslateY();
RiReal GetScale();
}; // Ri2DWindow


DESCRIPTION


KEYBOARD BINDINGS

u zoom in o zoom out i move up j move left k move down l move right


Ri2DWindow(int sizeX , int sizeY , int posX , int posY );

Default Constructor

    Ri2DWindow(int sizeX = -1, int sizeY = -1, int posX = -1, int posY = -1);

void SetTranslateFraction(RiReal newFraction);

Set the fraction of the window to translate with each key press

    void SetTranslateFraction(RiReal newFraction);

void SetScaleBase(RiReal newBase);

Set scale base for scaling. 2 means double/half each time.

    void SetScaleBase(RiReal newBase);

void PrintHelp();

Print the help for this window.

    virtual   void  PrintHelp();

void Keyboard(unsigned char key, int x, int y);

Handle keyboard input

    virtual void Keyboard(unsigned char key, int x, int y);

void Reshape();

actions to be performed upon reshaping the window size[XY] and pos[XY] will have been updated.

    virtual void Reshape();

void DoOpen();

really open the window

    virtual void DoOpen();

void DoSetSize();

really notify the system that the window needs to be redrawn

    virtual void DoSetSize();

RiReal GetTranslateX();

    RiReal 	GetTranslateX();

RiReal GetTranslateY();

    RiReal 	GetTranslateY();

RiReal GetScale();

    RiReal 	GetScale();

All Members

public:
// Accessors
int GetWidth();
int GetHeight();
int GetXPosition();
int GetYPosition();
// Members
void Open(const char *name);
void Close();
void Save();
void NeedsRedraw();
void SetSize(int width, int height);
void AddTimeout(int ms);
static int GetNumOpenWindows();
// Accessors
void SetTranslateFraction(RiReal newFraction);
void SetScaleBase(RiReal newBase);
protected:
void PrintHelp();
void MakeCurrent();
void Keyboard(unsigned char key, int x, int y);
void Mouse(int button, int state, int x, int y);
int Timeout();
void Redraw();
void Reshape();
void DoOpen();
void DoClose();
void DoSave();
void DoNeedsRedraw();
void DoSetSize();
void DoAddTimeout();
static void InsertAction(const RiWindowAction &act);
static void GuiLock();
static void GuiUnlock();
static RiWindow *GetCurrentWindow();
RiReal GetTranslateX();
RiReal GetTranslateY();
RiReal GetScale();

Ancestors

Inheritance chain for Ri2DWindow:


Descendants


Generated from source by the Cocoon utilities on Fri Feb 25 15:15:18 2000 .