Header image  
Point light displays the easy way  
line decor
  HOME >Tutorial Page  ::  
line decor
   
 
PointLightLab Tutorials

 

Tutorial - Using the "Bulk Set Pattern Layers" Tool Part 2

part 1 of this tutorial looked at using this tool to generate new pattern layers as a related group. This second part looks at applying this tool to modify existing pattern layers.

Finding the "Bulk Set Pattern Layers" Tool

The tool is located on the Script Tools Menu, within the sub menu under "Edit Pattern Layers". This menu will only be visible if a script file is currently open in the editor.

Overview

We will now work on the script that was created in the first part of the tutorial. You can download a copy of the script from Part 1 of the tutorial. Our intention is to modify a number of the stimuli properties to change the appearance of the stimuli. The stimuli currently has five star jumping bipeds all in lock step. Firstly we want to clone the existing script block so we have two blocks with the same stimuli. Then we want to change the stimuli in the second script block so that the biped on the right of the screen is slightly out of sync with the other four.We will then clone the script blocks again and finally we will use the "Bulk Set Pattern Layers" tool to modify the size of the biped dots in some of the blocks. The thesis is that the test subjects will not be able to detect the out of sync biped when other properties of the stimuli have changed.

Step 1 - Changing the size of the Model dots

Select the first script block by clicking on the node in the tree view. The background of the text will turn blue when the node is correctly selected. Open the "Bulk Set Pattern Layers" tool.

Set the number of pattern layers to affect. In this case we want to change the model dot size in all the pattern layers so set the number box to 5.

Set the Number of Layers to Affect

As we wish to change the property of Pattern layers that already exist, select the "Set Existing Layers" option.

Setting the Existing Layer Option

Now as we only wish to set the size property of the dots, we need to switch off all the other properties. Otherwise the existing values in the pattern layers will be over written. Uncheck the check box in the top left corner of each of the tab pages except the "General Values" Tab.

Uncheck the Model Dots Tab

Uncheck the Drift Region Tab

Uncheck the Freckle Effect Tab

Uncheck the Translation Effect Tab

This will leave only the properties on the General Values tab active. Now switch off all but the "Dot Size property.

Uncheck the other general values properties

Now set the size that you want the dots to be. We will set it to 1.

Set the size value

Now that everything is ready, press the "Set" button and verify that it has worked.

Verify that the dot size is now 1 in all five layers

Step 2 - Cloning the script blocks

Select the script block ( index 0), then from the "Script Tools" menu hover your mouse over the "Edit Script Blocks" until the sub-menu opens. Select the "Clone Script Block" option from the sub-menu. As there is only a single script block, it will be cloned automatically.

The new script block appears at the bottom of the list of script blocks. If you wished to move it upward in the list there are options on the "Edit Script Block" sub menu. However we do not need to do that now.

Step 2 - Changing the Sync of the star jumper

In the second script block, open the Pattern Layers node. Click on the "Animation Speed" property to put it into edit mode. You should see the property value appear in the numeric box on the right.

Edit the Animation Speed

Now adjust the value in the numeric box to 1.5. This should provide an obvious difference in the sync of the jumper. Press the "Update" Button when you have the number you are happy with. Now click the save on the file menu to save the file.

To test what you have created, open the script menu and select "Test Script in PLLPlayer" at the bottom. The stimuli should now play. Keep in mind that the first stimuli is all in sync while the second has the out of sync jumper. (You could change this by either changing the order of the stimuli or changing the script to a "Random" play order.

Wrap up

As you can see we have successfully edited a range of values using the tools to create two simple stimuli. This same technique could be used to clone and set the animation speed of the jumpers to a range of values to determine experimentally what the threshold for detecting syncing is.

 
      Copyright Duncan Blair 2006. All right reserved