[visionegg] bug in Text, and workaround
- From: "Smith, Mason" <masonrs@xxxxxxxxx>
- To: <visionegg@xxxxxxxxxxxxx>
- Date: Tue, 24 Jan 2006 10:11:18 -0500
Minor bug report... I have some code where I create a couple thousand Text
objects before the experiment starts (the idea is to create all the stimuli at
the beginning so that they can be instantly loaded during the experiment). I
found that VisionEgg crashes if you create too many Text objects; this is
because Pygame crashes if you create too many Font objects ("IOError: unable to
read font filename"). Perhaps there is a smarter way to code my experiment to
avoid creating as many Text objects, but I opted to do a simple workaround
where I keep a dictionary of Font objects, to avoid having to create duplicate
Font objects for every Text object with the same font. It might be good to
take this bug into account in future versions of VisionEgg.
---------------------------------------------------------------
Mason Smith
Research Associate, Rick Lewis Lab
University of Michigan, Department of Psychology
530 Church St., Ann Arbor, MI 48109-1043
Lab: East Hall, Room B380 Phone: (734) 764-6827
Fax: (734) 763-7480 Email: masonrs@xxxxxxxxx
- Follow-Ups:
- [visionegg] Re: bug in Text, and workaround
- From: Andrew Straw
Other related posts:
- » [visionegg] bug in Text, and workaround
- » [visionegg] Re: bug in Text, and workaround
- [visionegg] Re: bug in Text, and workaround
- From: Andrew Straw