I thought I would start a new thread for this topic. I have a large image which is presented using the picture element at full size and centrally (hposition = 50%) for the first half of the block. It is then reduced to 35% of its size and shown along with another picture side by side (at hposition = 25% or hposition = 75%) for the last half of the block. This all works great. However, at the start of the next block, despite the size being returned to 100% and the hposition = 50%, the images are shown off centre and not full sized (they are nearly full sized but not quite). I'm tearing my hair out.
<item Fractals>
/ 1 = "fractal1.jpg"
/ 2 = "fractal2.jpg"
/..
</item>
<picture fractalPicLoseCake>
/items = Fractals
/ select = values.fractalbalance
/size = (values.fractalsize,values.fractalsize)
/h_position = values.fractal1_x
</picture>
<picture fractalPicWinCake>
/items = Fractals
/ select = expressions.fractal2
/size = (values.fractalsize,values.fractalsize)
/h_position = values.fractal1_x
</picture>
<trial Pavlovian>
/ ontrialbegin = [
trial.Pavlovian.insertstimulustime(shape.eraser, parameters.fixationduration);
values.trialType = list.pavTrialType.nextvalue;
if (list.pavTrialType.nextvalue==1){
trial.Pavlovian.insertstimulustime(picture.fractalPicWinCake, parameters.fixationduration);
values.pavPicName = picture.fractalPicWinCake.currentitem}
else if (list.pavTrialType.nextvalue==2){
trial.Pavlovian.insertstimulustime(picture.fractalPicLoseCake, parameters.fixationduration);
values.pavPicName = picture.fractalPicLoseCake.currentitem;}]
..
</trial>
<trial pavChoiceTrial>
/ inputdevice=keyboard
/ ontrialbegin = [
values.fractalsize=35%;
values.trialType = list.pavChoiceTrialSelector.nextvalue;
values.fractalpositions = list.fractal_positions.nextvalue;
if (values.fractalpositions == 1) {
values.fractal1_x=25%;
values.fractal2_x=75%;
} else if (values.fractalpositions == 2) {
values.fractal1_x=75%;
values.fractal2_x=25%;
};
trial.pavChoiceTrial.insertstimulustime(shape.eraser, parameters.fixationduration);
if (values.trialType==1){
trial.pavChoiceTrial.insertstimulustime(picture.fractalPicWinCake, parameters.fixationduration);
picture.fractalPicWinCake.hposition=values.fractal1_x;
values.PavChoice1 = picture.fractalPicWinCake.currentitem;
trial.pavChoiceTrial.insertstimulustime(picture.fractalPicLoseCake, parameters.fixationduration);
picture.fractalPicLoseCake.hposition=values.fractal2_x;
values.PavChoice2 = picture.fractalPicLoseCake.currentitem;
]
...
</trial>
<block pavlovianTrials>
/ onblockbegin = [ values.fractalsize=100%; values.fractal1_x=50%; values.fractal2_x=50%;]
/ trials = [1-8 = Pavlovian; 9-15 = pavChoiceTrial]
..
</block>
Is it something to do with what it thinks the size of the canvas is? Currently the only default setting is / canvasaspectratio = (4,3). I'll be testing this over the internet so don't want to constrain the window too much as people's monitors will change so much?
Please help, thank you!