Millisecond Forums

Trouble presenting picture stimuli

https://forums.millisecond.com/Topic18473.aspx

By Marcel - 3/2/2016

Hi,

I'm trying to understand the behaviour of the code below, the resultant display (I get two img2.png's on screen as opposed to one of each) is not as I expect.. When viewing the debug window however, everything appears as it should. What am I doing wrong? 

I'm also wondering if someone could point me in the right direction on information regarding correct usage of the function removeitem().


<item distractors>
/1 = "img1.png"
/2 = "img2.png"
</item>

<item one>
</item>

<item two>
</item>

<trial displaysomething>
/ontrialbegin = [item.one.item = item.distractors.item(1);
item.two.item = item.distractors.item(2)]
/stimulusframes = [1=s1,s2]
/validresponse = (57)
</trial>

<picture s1>
/items = one
/position = (25%, 25%)
</picture>

<picture s2>
/items = two
/position = (25%, 50%)
</picture>


Thanks

Marcel

By Marcel - 3/2/2016


This problem seemed ultra strange so I ran the same script on another computer and it worked as expected. 
By Dave - 3/2/2016

> I get two img2.png's on screen as opposed to one of each

paired with

>
This problem seemed ultra strange so I ran the same script on another computer and it worked as expected.                                

points to a buggy graphics card driver on the 1st system. We have seen a few (~10) instances of similar problems over the years, and in every case a malfunctioning driver was responsible and updating it to the latest one available resolved the issue.

Beyond that, I would recommend changing the code somewhat for better performance:

<item distractors>
/1 = "img1.png"
/2 = "img2.png"
</item>

<values>
/ s1item = 1
/ s2item = 1
</values>

<trial displaysomething>
/ontrialbegin = [values.s1item = 1; values.s2item = 2; ]
/stimulusframes = [1=s1,s2]
/validresponse = (57)
</trial>

<picture s1>
/items = distractors
/ select = values.s1item
/position = (25%, 25%)
</picture>

<picture s2>
/items = distractors
/ select = values.s2item
/position = (25%, 50%)
</picture>