code: function processSampler(map) {
        if (!outputJSON.samplers) {
          outputJSON.samplers = [];
        }
  
        var gltfSampler = {
          magFilter: THREE_TO_WEBGL[map.magFilter],
          minFilter: THREE_TO_WEBGL[map.minFilter],
          wrapS: THREE_TO_WEBGL[map.wrapS],
          wrapT: THREE_TO_WEBGL[map.wrapT]
        };
  
        outputJSON.samplers.push(gltfSampler);
  
        return outputJSON.samplers.length - 1;
      }
docs: Process sampler
  @param  {Texture} map Texture to process
  @return {Integer}     Index of the processed texture in the "samplers" array