(Solved) : Gaining Familiarity Openframeworks 2d Graphics Using Visual Studio Xcode 1 Create Rectangl Q30774575 . . .
Gaining Familiarity with OpenFrameworks and 2DGraphics
(using Visual Studio or XCode)
1) Create a Rectangle class that maintains size, position and abool state variable to indicate if the rectangle is pressed down onwith the mouse. Initialized the rectangle to initially be centeredin your window with a width/height to be 100. Set to a defaultcolor of your choice.
2) When the mouse moves into the rectangle and the left mousebutton is pressed, the button should turn from red to green (or anyother color of your choice. When the mouse button is released thebutton should turn back to its original color .
3) When the mouse button is pressed in the rectangle and thendragged, the button should then move (by changing it’s position)with the mouse pointer. Note that if the mouse pointer moves fastand momentarily leaves the boundaries of the rectangle whiledragging, the rectangle should not stop. It should continue tomove. Think of the mouse pointer being attached to a virtual rubberband while it is being dragged.
The program needs to be written in #C!!
Expert Answer
Answer to Gaining Familiarity Openframeworks 2d Graphics Using Visual Studio Xcode 1 Create Rectangl Q30774575 . . .
OR