ok, i'll explain it.
You need to be able to control the flow of current into the led, because the intensity of emitted light, is proportional to the current. so, to control the range, we need to control the current.
Next step: how to control current?
answer: PWM, or Pulse width modulation, where you send pulses to the LED, of FIXED FREQUENCY and fixed duty cycle (duty cycle is the ON time w.r.t the OFF time of each pulse) if the ON time is 1 ms and the off time is 10 ms, then the duty cycle is 10%.
Now, inject the maximum current in the led, which is equal to the maximum forward current of the LED divided by the duty cycle of the PWM. (if you'r clever with math and waves, you will notice that we are playing around with with the average current through the led). after you've figured out the max current (which can go as high as 2 A... as long as the average current does not exceed the maximum DC current specified in the datasheet) you then need to chose a switable resistor value for this current.
then to play with the range, you'll have to change the voltage that you send to the emitter block (LED + in series resistor). you can easily do that with an r/2r ladder network and an op-amp..
I know this might seem complicated, but that's as simple as it can get to acheive a project like yours.