Assignment title: Information


Key Skills to be Assessed C/C++ programming Application of a structured OO framework for graphics applications Critical Evaluation of tools used The Assessment Task For your resit assignment you should review your previous feedback for this assignment and address the issues raised in it. Your task is produce a OSG based viewer application that allows you to load and explore a structured scene file and enact, within this environment, object creation and manipulation, scene graph manipulation and user interaction. Your basic viewer application should use the OSG framework to deliver a programme that will load a scene file (in a standard format) as a command line instruction to the programme. Once loaded the visual rendition of this data should be explorable and navigable using the standard navigation tools supported by the scene graph library. As the scene description can be modified during the operation of the application, the viewer should be capable of saving a scene description file (in response to a key press, without overwriting the source file). The functionality of this basic viewer should also be extended to allow the following features. 1. Scene Graph Manipulation and Interaction. You are provided with a scene description file (raaRobot.osg, available on blackboard) which has the scene description for a multi jointed robotic arm. This should be used as the source file for running the viewer. The robot arm within the file is created in a structured manner, with the spatial relationships between parts defined as part of the data structure. In this each matrix transformation node that controls the orientation of a part is named (*_Rotator or *_Locator). You should create an extended node visitor that will traverse the scene graph and present the name (where available), and type, for each node visited to the console. Your application should match the basic layout of the sample application provided, with 4 to 8 robots arranged in a ring layout. The basic control mechanisms should enable the robots rotate around the ring, and perform synchronised actions in response to key presses. This will require basic scene composition to re-use the single instance of the loaded model. Interaction with the robot, to create animation, through the use of the identified transformation nodes will require production of classes and structures that extend the OSG framework for detecting user input and directing it to the appropriate arm and body section for manipulation. This can be achieved in several ways, with the ideal being a generic reusable approach that decorates the SG with updater nodes (based on osg::NodeCallback). An ideal solution will enable the individual arm parts to: • Move in response to a specific key press (translation of the body and rotation of the arms). • Highlight the arm part (and only the specific part) under control. • Constrain the motion within defined limits. • Highlight when the arm is constrained by the motion limits. Advanced control of the robot. In this part of the assignment you should extend the application to enable recording and playback of the actions undertaken by the robotic troop. This should enable simple record of the control path in response to a key press to stop and start recording. Playback should be started and stopped with a key press and should loop repeatedly until stopped. The actions should be recorded in a time context and playback should maintain both the order of events and the relative timing of actions. Enhanced/improved environment. The initial scene is a little sparse for dancing robots. You should add content into this to both create static structure and add dynamic content (disco lights, procedurally generated shapes created at the control robot's hand position, floor plane, etc). Advanced scene enhancement should include provision of functionality for displaying a historical trail of the hand movement for each robot's hand. Additional features that could also be considered would be the inclusion of the ability to save and re-load recorded animation paths, the use of mouse for selection and/or control of the robot's parts, and enhanced navigation modes. In addition, to the technical aspects of this assignment, you are also required to produce a report (Guideline 2 pages (1000 words)) that compares and critically evaluates the use of C/OpenGL against C++/OSG in the production of this application. This may refer to the similar implementation undertaken for the 1st assignment. Recommended Reading The OSG website (www.openscenegraph.org) will be invaluable in helping you to complete this assignment. Key areas within this site are the reference documentation and the example programmes Equipment and Facilities to be Used The university laboratory computers are installed with MS Visual Studio 20XX. OSG is a freely available open source toolkit, that can be downloaded for use on personal systems. A basic template, with OSG installed is provided as a starting example for the assignment. During tutorials in Sem2, an outline for home installation of OSG has been given . Marking scheme The work will be assessed using a marking grid comprising 5 equally weighted components (provided below). 4 of these (Programming structure and design, Viewer Implementation, Object Creation and Manipulation, and Scene Graph Manipulation and Interaction relate to the programming element of the assignment, while the last, Critical Evaluation, relates to the written element. Assessment criteria 0-19% 20-39% 40-59% 60-79% 80-100% Level 6 Assessment Scale Extremely Poor Very poor Poor Unsatisfactory Adequate Fair Good Very Good Excellent Outstanding Programming, structure and design Little or no generic code reuse, with the majority of functionality bespoke to the task. Poor use of formatting (white space etc) Inconsistency in naming styles and conventions Hard coded static structures used throughout. Some use of accepted C++ file structure for classes and functions Inconsistent formatting of code Elements of generic functionality, allowing some reuse, but inconsistently applied Use of bespoke classes and structures to handle and manage scene and interaction Well defined and decomposed code structure with all classes adhering to C++ file structure and file based decomposition of functions. Constant and clear formatting of all code throughout Generic code used in all cases, where possible. Some use of toolkit classes in a specialised form to achieve functional goals Evidence of planned and optimised class based structure that encapsulates multi-functional, generic , reusable structures in all cases. Decomposition of programme features to generic control pipelines for each feature set. Refined class structure, based on toolkit specialisation, for all functional goals Use of own file I/O functionality to save and restore animation paths Use of appropriate data structures for recording each motion step Use of appropriate data structures for capturing all hand motion events for trail lines Use of advanced language features (eg templates, stl, etc) for the creation of refined data structures and algorithms Refined and effective use of data structures and algorithms throughout Use of own file I/O functionality to save and restore state of application Use of own file I/O functionality to save and restore animation paths Use of appropriate data structures for recording motion control events Use of refined data structure for capturing refined (reduced) set of hand motion points in efficient data structure Scene Graph Manipulation and Interaction Creation and use of own approaches for investigation and review of the scene structure Import and placing of a single robot in the scene Creation and use of specialised standard tools (api classes)for investigation and review of the scene structure Creation and use of specialised standard tools (api classes) to search for and select scene nodes of a specific type Import multiple robot model instances to create composition Instantiation and presentation of troop of dancing robots within the scene (without animation) Formation of a single control entity for manipulation of the robotic device Control of robot motion using key presses to enact synchronised motion for one instance Decoration of scene with standard objects for basic used interaction control on a distributed, per node basis. Implementation of separate call-back nodes for scene decoration for both translation and rotation Disconnection of user input cycle from control update cycle to enable smooth motion control of parts Modification of scene graph structure to enable visual identification of node(s) under user interaction Import and reuse of a single robot instance to form scene composition. Control of robot motion using key presses to enact synchronised motion for all instances Use of standard api features to record and playback animation of robot motion Extended call-back decorator classes to report motion events to animation control system Refined hierarchic class structure to unify control callback nodes within a single generic interface Recording of a single animation path Playback of recorded animation Modification of scene graph structure to enable visual identification of node(s) under user interaction with difference visual highlight when motion limit is applied Provision of scene structures and mechanisms to enable runtime addition of artefacts to the scene Provision on basic rendering mechanism for trail lines Creation and use of specialised standard tools (api classes) to search for and select scene nodes of any type with type being a factor in the identification Synchronised playback (on user command) of dance actions by troop of dancing robots Ability to save and load a animation sequence for the dancing robots Integrated (with the S) rendering solution for display of the trail lines using appropriate OGL functionality User Interaction and Control Basic navigation of scene (explore mode) through use of mouse and keyboard using api standard tools. Ability to reset view to starting position Switchable navigation modes to enable both explore and fly within scene Implementation of standard api approaches to capture key presses and directly control robot motion within the key press cycle Implementation of advanced control mechanism to disconnect key press cycle from update cycle for motion control of robot Smooth motion control of motion with fixed velocity for all parts Provision of information (within console window) of current mode of operation Reset functionality to jump robot configuration back to start conditions Smooth control of motion with ability to define different velocities for all parts Definition and enaction of specific limits to motion of all parts Provision of information (within visualisation window) of current mode of operation Provision of key based control to change animation state (record, pause/stop, playback) Key based control of environmental effects (eg switch on/off additional disco lights) Provision of simple mechanism to save and load animation paths Extended key based input to add additional artefacts to the scene (eg box, sphere, etc) Refined reset functionality to animate robot's return to start configuration. Scene Enrichment Basic scene loaded with no additional artefacts Addition of a static structure to scene to frame the environment (eg floor, walls, etc) Use of texture on static scene objects Provision of multiple static light sources within the scene Use of multiple static objects within the scene to create a surrounding environment to the robotic models Provision of a basic floor plane Provision of dynamic lighting effects to add visual effect to robots in scene Ability to dynamically add a basic artefact to the scene at the control robot hand position Provision of a textured floor plane and additional structural elements to frame the scene Ability to block remove dynamically added artefacts Ability to dynamically add a basic artefact (of multiple types) to the scene at the control robot hand position Basic continual animation of static scene objects Provision of advanced functionality (eg transparency, floor reflection) within the scene. Use of advanced effects (eg particle system to add interest in scene) Extended presentation of user information to the visualisation window (eg HUD) with ability to show/hide this feature User menu, within the graphical display Scene enrichment with artefacts (eg lights, colour changing objects, etc), that respond to the motion of the robots during control and animation. Critical Evaluation & response to previous feedback Basic narrative of the creation of the assignment 2 application without reference to C/OpenGL implementation of a similar system Discussion of implementation of system in C++/OSG compared to C/OpenGL approach. Without direct comparison and evaluation of the differences between the approaches Evidence of some comparative elements between C++/OSG and C/OpenGL implementations within a basic framework alluding to level of functionality and complexity of programming Some review of both assignment implementations Basic commentary on previous feedback, with little evidence to support claims Review of approaches taken for C/OpenGL and C++/OSG implementations demonstrating differences and similarities between the two languages and libraries Review of both assignment implementations with some suggestions of how approaches could be bettered in future cases Extended commentary on previous feedback, with specific evidence to support claims Critical evaluation of the language and toolkits used with an analysis of key differences and advantages/disadvantages of both. Detailed review of both assignment implementations with suggestions of how approaches could be bettered in future cases Extended commentary on previous feedback, with specific evidence to support claims and overall reflection on the outcomes of responding to the previous feedback Submission Details A working application and MS visual studio solution should be provided in a zipped file (without the OSG library included).