A structured light system comprising: a light source (124, 1302, 1402) configured to emit light; and a diffractive element (800, 900, 950, 1116, 1216, 1304, 1404), comprising: a first diffractive optical element (802, 902, 1108, 1208, 1310, 1410) having a first refractive index, the first diffractive optical element configured to project a first distribution of light from a received light point from the emitted light, the first distribution of light having multiple light points; a second diffractive optical element (804, 904, 1110, 1210, 1312, 1412) having a second refractive index, the second diffractive optical element configured to project a second distribution of light from a received light point from the emitted light based on a refractive material between the first diffractive optical element and the second diffractive optical element, the second distribution of light having multiple light points; and a refractive material (806, 906, 1118, 1218, 1314, 1424) located between the first diffractive optical element and the second diffractive optical element, wherein the refractive material is adjustable between a first mode and a second mode, wherein the refractive material has the second refractive index in the first mode, and wherein the refractive material has a third refractive index in the second mode, wherein the light source comprises one or more lasers configured to emit unpolarized infrared light, the apparatus further comprising an infrared receiver configured to receive reflections of the infrared light, and one or more processors configured to: determine one or more depths in a scene from the received reflections by the infrared receiver; control operation of the light projector; and generate a depth map from the one or more depths. a light source (124, 1302, 1402) configured to emit light; and a diffractive element (800, 900, 950, 1116, 1216, 1304, 1404), comprising: a first diffractive optical element (802, 902, 1108, 1208, 1310, 1410) having a first refractive index, the first diffractive optical element configured to project a first distribution of light from a received light point from the emitted light, the first distribution of light having multiple light points; a second diffractive optical element (804, 904, 1110, 1210, 1312, 1412) having a second refractive index, the second diffractive optical element configured to project a second distribution of light from a received light point from the emitted light based on a refractive material between the first diffractive optical element and the second diffractive optical element, the second distribution of light having multiple light points; and a refractive material (806, 906, 1118, 1218, 1314, 1424) located between the first diffractive optical element and the second diffractive optical element, wherein the refractive material is adjustable between a first mode and a second mode, wherein the refractive material has the second refractive index in the first mode, and wherein the refractive material has a third refractive index in the second mode, a first diffractive optical element (802, 902, 1108, 1208, 1310, 1410) having a first refractive index, the first diffractive optical element configured to project a first distribution of light from a received light point from the emitted light, the first distribution of light having multiple light points; a second diffractive optical element (804, 904, 1110, 1210, 1312, 1412) having a second refractive index, the second diffractive optical element configured to project a second distribution of light from a received light point from the emitted light based on a refractive material between the first diffractive optical element and the second diffractive optical element, the second distribution of light having multiple light points; and a refractive material (806, 906, 1118, 1218, 1314, 1424) located between the first diffractive optical element and the second diffractive optical element, wherein the refractive material is adjustable between a first mode and a second mode, wherein the refractive material has the second refractive index in the first mode, and wherein the refractive material has a third refractive index in the second mode, wherein the light source comprises one or more lasers configured to emit unpolarized infrared light, the apparatus further comprising an infrared receiver configured to receive reflections of the infrared light, and one or more processors configured to: determine one or more depths in a scene from the received reflections by the infrared receiver; control operation of the light projector; and generate a depth map from the one or more depths. determine one or more depths in a scene from the received reflections by the infrared receiver; control operation of the light projector; and generate a depth map from the one or more depths.