Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: SFML to control cognitive psychology experiments  (Read 3299 times)

0 Members and 1 Guest are viewing this topic.

SvenB

  • Newbie
  • *
  • Posts: 28
    • View Profile
    • http://www.psych.uni-halle.de/sven/
SFML to control cognitive psychology experiments
« on: July 08, 2008, 05:09:50 pm »
Hi,

we are currently looking for a new programming environment/libraries
to program experiments for cognitive psychology. Until today we are
working with DOS (full hardware control), but a transition to windows
is unavoidable ...

Okay, we need high precision timing, access to the parallel port
AND good control of the display/screen. I would like to ask especially
for the display issue some questions. Maybe someone can give
use the necessary information to opt for or against sfml.

We always need more than one graphics display, one visible, the
others virtual screens, sometimes called double buffering or page
flipping. All screens are fully prepared (rendered) before the presentation
starts to avoid any latencies due to time consuming graphics commands
or file access to load pictures or whatelse.

A typical instruction sequence looks like this (pseudo-code)

for ( trial=1; trial < maxtrials; trial++ ) {
   prepare_all_screens() ;
   show_screen_1_for_some_time();
   show_screen_2_for_some_time();
   show_screen_3();
   start_timer();
   wait_for_participant_response();
   stop_timer();
}

Is it possible to have multiple virtual screens with sfml,
rendering to invisible screens, switching beween screens,
switching synchronized with the vertical retrace?

Thanx in advance - Sven

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
SFML to control cognitive psychology experiments
« Reply #1 on: July 08, 2008, 05:43:49 pm »
Quote
Is it possible to have multiple virtual screens with sfml,
rendering to invisible screens, switching beween screens

Very soon, I already started working on it.

Quote
switching synchronized with the vertical retrace?

Yes.
Laurent Gomila - SFML developer

quasius

  • Full Member
  • ***
  • Posts: 166
    • View Profile
SFML to control cognitive psychology experiments
« Reply #2 on: July 08, 2008, 06:33:07 pm »
I'm not sure SFML interfaces to the parallel port...
(Although I'm sure you could add that with winAPI-specific stuff)

SvenB

  • Newbie
  • *
  • Posts: 28
    • View Profile
    • http://www.psych.uni-halle.de/sven/
SFML to control cognitive psychology experiments
« Reply #3 on: July 08, 2008, 08:13:32 pm »
Quote
I'm not sure SFML interfaces to the parallel port...


We already have a hint to a solution for this problem,
independent from sfml.

By the way:
how precise is the sfml-timer?

Thanks in advance - Sven

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
SFML to control cognitive psychology experiments
« Reply #4 on: July 09, 2008, 02:44:24 am »
Quote
how precise is the sfml-timer?

The best it can be. The timer resolution depends on each OS.
Laurent Gomila - SFML developer