Can anyone point to generic algorithm or library for buffer zones if the source data is in WGS84 degrees? The buffer width should be in meters, as buffer in degrees it generally does not make much sense.
I'm aware of popular geometry libraries like JTS, PostGIS, ESRI etc, but none of these seem to work for lat/long case. I can of course convert latlon to some cartesian projection and then use these libraries, but this is usable only in small scale, limited specific area and/or with sacrificing precision. Also for some cases you may "convert" meter distance to degree distance, but this is ugly and heavily dependent on latitude. Some libs have first algorithms for proper lat-long, e.g. PostGIS can do Haversine distance, but no Buffers.
So basically I would need a Buffer polygon which would be created using Haversine distance from given line.
Now if you really do not know such algorithm/tool, which would work without limitations (globally, with any coordinates and buffer size, giving still high mathematical precision), then you can suggest "second class" alternatives with limited input area and buffer sizes, keeping precision to <1m scale and assuming that the area is somewhere in inhabited regions (i.e. not in Antarctica or ocean), and total size is below say 500km. For most cases it would do the job also.
p.s. tools and code samples in Java would be preferred. Specific target would be a mobile app (Android) which is used for technical underground infrastructure checks (digging safety) in cities anywhere in the world. It requires high precision regardless of latitude, but in sane range (<80 deg).