1 Features
- 3D WGS84 ellipsoid
- Rotation of earth, selectable speed
- Relief with exaggerated elevations
- Data tip in geographic coordinates and elevations in meter
- Example to plot on earth
- Example to plot on texture
2 Method
Out of geographic coordinates in one degree steps a geocentric x, y, z mesh grid is created by sin and cos functions. This mesh grid is placed to form a WGS84 ellipsoid. The texture within the meshes is overlaid by Matlab’s surface function.
3 Syntax
plot3Dearth % default texture, flat relief
plot3Dearth(0,50) % default texture, elevations exaggerated by factor 50
plot3Dearth('land_ocean_ice_8192.png', 100) % Texture out of folder 'texture', elevations exaggerated by factor 100
plot3Dearth('c:/myFolder/myTexture.jpg') % Texture out of other folder, flat relief
See also the included pdf file.
Cite As
Peter Seibold (2025). 3D WGS84 Earth (https://www.mathworks.com/matlabcentral/fileexchange/174345-3d-wgs84-earth), MATLAB Central File Exchange. Retrieved .
MATLAB Release Compatibility
Created with
R2020a
Compatible with any release
Platform Compatibility
Windows macOS LinuxTags
Acknowledgements
Inspired by: 3D Earth Example, geographiclib
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Discover Live Editor
Create scripts with code, output, and formatted text in a single executable document.