Tuesday 11 January 2011

Developer Journal 35



The second image is a copy of the second viewport in the top image.

COMPLETED ACTIONS
* Release robot from possession when switching from possession mode to observer mode.
* Save the contents of 1 viewport to a file to check that the robots are seeing what they should be seeing.
* F4 is my capture screenshot key. Alt + F4 is how I often exit. Prevent screenshot capture when I exit.
* Get image into robot.

NEXT ACTIONS
* Figure out a way to get the frame rate up.
* Convert image into format that the neural network can use.
* Connect view port to agent vision input.
* Round to the nearest integer in the CaptureViewport() code.
* Re-examine angular and linear deceleration code.
* Consider always applying a deceleration force.
* Enable displaying the mouse pointer when running the simulation.
* Add food
* Re-enable serialization.
* Get agent populations surviving again.
* Have a neuron for rotating left and another neuron for rotating right.
* Have a neuron for moving forwards and another neuron for moving backwards.
* Add code to reset a cube that is not on its "feet".
* Increase heights of walls.
* Get shadows working properly.
* Implement command controls.
* Implement FPS controls.
* Re-enable communication.
* Conduct gender experiments.
* Conduct maturation experiment.
* Experiment with joints and more advanced body shapes.
* Make the graphics look more like the demos in Bullet.
* Display frames per second
* Implement a way to use the mouse to re-size the viewports.
* Implement a way to use the mouse to re-position the viewports.
* Implement a way to use the mouse to move a screen like on an iPhone.
* Implement off-screen rendering.

NOTES

Seems like I can't output a viewport to a file without some fiddling.

Ogre::RenderTarget::copyContentsToMemory() copies a whole screen to memory or more precisely, into class Ogre::PixelBox.

Then you can put Ogre::PixelBox into class Ogre::Image.

Then you can get the smaller image from Ogre::Image into an unsigned char array.

Then you can put the unsigned char array into another Ogre::Image and then output the smaller image.

Interesting. If you call Ogre::RenderWindow::copyContentsToMemory() before Ogre::Root::renderOneFrame() then you will get a segmentation fault on exit.

Things are starting to slow down a little. I create big image from the screen. Then I create a small image from the big image.

No comments:

Post a Comment