[visionegg] Re: mirroring a text strimulus?
- From: Andrew Straw <astraw@xxxxxxxxxxx>
- To: visionegg@xxxxxxxxxxxxx
- Date: Tue, 18 Nov 2008 13:54:47 -0800
Hi Gary,
I just added such functionality including a demo script. The new demo
can be seen at
http://visionegg.org/trac/browser/trunk/visionegg/demo/texture_as_numpy_array.py
This will require the latest VE from svn, however. If that's a pain, you
should just be able to take the latest VisionEgg/Textures.py from the
source repository and overwrite the version in your installation. Test
it with the new demo script.
-Andrew
Gary Lupyan wrote:
> Thanks! Do you know offhand what the command is for converting Texture
> to a numpy buffer and back?
>
> -Gary
>
>
> On Tue, Nov 18, 2008 at 3:17 PM, Dav Clark <davclark@xxxxxxxxxxxx
> <mailto:davclark@xxxxxxxxxxxx>> wrote:
>
> It would be trivial to take your texture as a numpy buffer or
> similar and flip it (in numpy) and create a second stimulus with
> that. There would be an OpenGL way to do it also, but I don't know
> off the top of my head...
>
> reversing in numpy:
>
> swapd = a[:,::-1]
>
> Cheers,
> Dav
>
>
> On Nov 18, 2008, at 11:26 AM, Gary Lupyan wrote:
>
> Hey everyone, is there a way to flip (i.e., mirror) a texture
> stimulus about the x or y axis?
>
> Thanks.
>
>
> ======================================
> The Vision Egg mailing list
> Archives: http://www.freelists.org/archives/visionegg
> Website: http://www.visionegg.org/mailinglist.html
>
>
--
Dr. Andrew D. Straw
California Institute of Technology
http://www.its.caltech.edu/~astraw/
======================================
The Vision Egg mailing list
Archives: http://www.freelists.org/archives/visionegg
Website: http://www.visionegg.org/mailinglist.html
Other related posts: