[visionegg] projections

Hi All,

While hoping to get the movies working asap, I've been trying to implement
projections in my code. Here's a simple attempt to use them with texture
demo. When projection related lines are uncommented everything works fine.
When I try to run them, I'll get a grey screen. I've spend a day trying to
make it work with various stimuli I have (textures, gratings, movies), but
I'm still totally clueless what is going wrong.

Please let me know if you have ideas.

Cheers,
Mikko

#!/usr/bin/env python
"""Load a texture from a file."""

import os
import VisionEgg
VisionEgg.start_default_logging(); VisionEgg.watch_exceptions()

from VisionEgg.Core import *
from VisionEgg.FlowControl import Presentation
from VisionEgg.Textures import *

filename =
os.path.join(VisionEgg.config.VISIONEGG_SYSTEM_DIR,"data","panorama.jpg")
texture = Texture(filename)

screen = get_default_screen()

#projection = SimplePerspectiveProjection(90.0)

# Create the instance of TextureStimulus
stimulus = TextureStimulus(texture = texture,
                           position =
(screen.size[0]/2.0,screen.size[1]/2.0),
                           anchor = 'center',
                           shrink_texture_ok=1)

viewport = Viewport(screen=screen,
                    size=screen.size,
#                    projection=projection,
                    stimuli=[stimulus])

p = Presentation(go_duration=(5.0,'seconds'),viewports=[viewport])
p.go()
pygame.quit()


======================================
The Vision Egg mailing list
Archives: http://www.freelists.org/archives/visionegg
Website: http://www.visionegg.org/mailinglist.html

Other related posts: