1
웹 브라우저에 파일을로드하는 순간이지만 실제로 업로드하기 전에 이미지 파일 (JPG, JPEG, PNG 등)에서 위치 정보 데이터를 읽는 방법 (클라이언트 측에서).자바에서 이미지 파일 데이터에서 지리적 위치를 읽는 방법
var ExifImage = require('exif').ExifImage;
try {
new ExifImage({ image : 'myImage.jpg' }, function (error, exifData) {
if (error)
console.log('Error: '+error.message);
else
console.log(exifData); // Do something with your data!
});
} catch (error) {
console.log('Error: ' + error.message);
}
브라우저에서 사용이 NPM 모듈을 변환 Browserify을 사용할 수 있습니다 :이처럼 사용할 수있는 'EXIF'라는 모듈이 있습니다
다음 중 하나를 사용할 수 있습니다. https://github.com/exif-js/exif-js – Phil