title: Looking for a way to make three sliders affect an image (as a teaching tool)
body: <p>I tried looking for this in search, but it is a lot of individual things packed together. What I am looking to make for my students is an interactive display of the triangle of exposure on a camera. </p>
  
  <p>It has three sliders that show what happens with different settings. One is ISO (controls dark and lightness), another is shutter speed (which controls background blur/depth of field), and aperture, which controls motion blur. I was able to make a slider that effectively changes the test image in darkness. I am currently working on the slider for shutter speed. </p>
  
  <p>I am wondering if the interaction between the sliders would be better accomplished through switching between PRE-PHOTOSHOPPED images by substitution, or using AS3 to accomplish changes on the fly. For instance, if they move the sliders for shutter speed and ISO at the same time, it gets dark AND has background blur. do I need to pre-photoshop every possible option, and switch symbols, or can I do it interactively with AS3?</p>
  
  <p>Here is my code:</p>
  
  <pre><code>import flash.utils.getDefinitionByName;
          import fl.motion.Color;
  
  import fl.events.SliderEvent;
  var myImageName1 = "blurback.jpg";
  var classRef:Class = getDefinitionByName(myImageName1) as Class;
  var instance:MovieClip = new classRef();
  
  
  
  
  var c:Color=new Color();
  var color = "#000000";
  
  
  ISO.addEventListener(SliderEvent.CHANGE, sliderChanged);
  aperture.addEventListener(SliderEvent.CHANGE, apertureChanged);
  
  
  
  function sliderChanged(evt:SliderEvent):void {
  
  tintClip();
  
  }
  
  
  
  /*
  The 'setTint' method of of the Color class takes two parameters: tint 
         multiplier, 
  (a number between 0 and 1), and a tint color.
  
  The tint multiplier, is determined by the positon of the slider, 'val'      
  and equals val/100.
  The tint color, 'color', is determined by the color selected
  in the picker. 
  */
  
  function tintClip():void {
  
  
  
  var val:Number=ISO.value;
  
  c.setTint(color,val/10);
  
  kitty.transform.colorTransform=c;
  
  
  
  }
  function apertureChanged(evt:SliderEvent):void {
  
  gotoAndPlay(2);
  
  
  /*kitty.addChild(instance);*/
  
  }
  </code></pre>
  
  <p>I am still experimenting with the second slider, so the gotoand play is a work in progress on substituting a pre-background-blurred image when the slider is slid.</p>
  
  <p>Here is a pic of the final image, with the sliders named appropriately.
  <a href="https://i.stack.imgur.com/pv7fx.jpg" rel="nofollow noreferrer">link: Final image</a></p>
  
  <p><img src="https://i.stack.imgur.com/pv7fx.jpg" /></p>