Skip to content

writeAsync() does not respect direction of latitude/longitude #12

@orientalperil

Description

@orientalperil

I'm having an issue where GPSLongitudeRef is ignored. I read the metadata from a photo from a camera component and then write it to another file. The new file has the wrong GPSLongitudeRef. Developing on iOS.

GPSLongitudeRef in my photo is 'W' and GPSLongitude is a positive number. When I try to write this, GPSLongitudeRef changes into 'E'. I was able to work around this by changing GPSLongitude to a negative number if GPSLongitudeRef is 'W'.

import {readAsync, writeAsync} from '@lodev09/react-native-exify'

let exifData = await readAsync(photo.path)
let uri = `${FileSystem.documentDirectory}/file.jpg`
await writeAsync(uri, exifData)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions