1. Anuncie Aqui ! Entre em contato fdantas@4each.com.br

[Flutter] problem to transform from gcm_magna to lat, long in dart-flutter

Discussão em 'Mobile' iniciado por Stack, Setembro 27, 2024 às 18:23.

  1. Stack

    Stack Membro Participativo

    I was trying to convert from gcm_magna to lat and long using the lib but the outputs were inaccurate. Can some one explain me or correct me?


    var destProjection = Projection.get('EPSG:4326')!; // WGS84 (EPSG:4326)

    // Definir las coordenadas en EPSG:3116
    var point = Point(x: 846358.4308, y: 1639765.33);

    // Convertir las coordenadas de EPSG:3116 a EPSG:4326
    var transformedPoint = srcProjection.transform(destProjection, point);

    print('Latitud: ${transformedPoint.y}, Longitud: ${transformedPoint.x}');```

    my inputs were: (x: 846358.4308, y: 1639765.33) and the expected outputs are Lat: 10.377944565887024, Long: -75.48036335262766. But I have Lat: 14.809695868343415, Long: -71.7825948906633

    Continue reading...

Compartilhe esta Página