Marble: Difference between revisions

From KDE TechBase
(→‎Mac OS X: Document how to package Qt-only Marble)
mNo edit summary
(91 intermediate revisions by 14 users not shown)
Line 1: Line 1:
{{Template:I18n/Language Navigation Bar|Projects/Marble}}


__NOTOC__
 
[[Image:Marble_logo.png]]
[[Image:Marble_logo.png]]


== About Marble ==
== About Marble ==
;[[/Devices_and_Use_Cases|Devices and Use Cases]]
;[[/FAQ|Marble FAQ]]
;[[/FAQ|Marble FAQ]]


== Examples of Use ==
== Success Stories: 3rd party applications using the Marble Library==
;[[/MarbleUsedBy|Applications using the Marble library]]
;[[/MarbleUsedBy|Software that makes use of Marble]]


== Using the Marble Widget in other applications ==
== Tutorials: How to use the Marble Widget in your application ==
;[[/MarbleDesigner|with QtDesigner]]
;[[/MarbleDesigner|with Qt Designer]]
;[[/MarbleCPlusPlus|with C++]]
;[[/MarbleWindows|On Windows, with Qt Creator/Qt Designer]]
;[[/MarblePython|with Python]]


;[[/MarbleDBus|via a shell script]]
=== With C++ ===
==== Intro ====
;[[/MarbleCPlusPlus|Hello World]]
;[[/MarbleMarbleWidget|Changing basic map properties]]
;[[/MarbleSignalsSlots|Creating a window with controls]]


== How to become a Marble developer ("Marblehead") ==
==== GeoData ====
;[[/Runners/DisplayGeoDataPlacemark|Displaying GeoData Documents]]


=== So you are new to Marble development ... ===
==== Online Services ====
;[[/OnlineServices|Creating new Online Services]]


<b>Welcome!</b>
==== Routing ====
;[[/Routing/BasicRouting|Basic Routing]]


Here you'll get all the information you need to start Marble development:
==== Runners ====
;[[/Runners/Search|Searching for Points of Interest]]
;[[/Runners/ReverseGeocoding|Reverse Geocoding]]
;[[/Runners/Parse|Parsing Files]]


;[[/GoMarble|How to become a Marble Developer]]
==== GeoPainter ====
;[[/MarbleGeoPainter|Painting onto the map]]
;[[/LayerInterface|Drawing in Custom Layers]]
;[[/Runners/PaintingGeoDataLineString|Painting LineString]]


== Packaging Marble ==
=== With Python ===
==== Intro ====
;[http://techbase.kde.org/Projects/Marble/MarblePythonInstructions Installing Marble's Python bindings]
;[[/MarblePythonHello|Hello World]]
;[[/MarblePythonMarbleWidget|Changing basic map properties]]
;[[/MarblePythonSignalsSlots|Creating a window with controls]]


Here is some advice about how packaging is supposed to happen on the various plattforms that are supported.
==== Loading Files ====
;[[/Runners/MarblePythonLoadingKML|Loading KML files into Marble]]
;[[/Runners/MarblePythonLoadingOSM|Loading OSM files into Marble]]


===General===
==== GeoData ====
;[[/Runners/MarblePythonDisplayGeoDataPlacemark|Display GeoData Placemark]]
;[[/Runners/MarblePythonVehicleTracking|Vehicle Tracking]]


===Linux===
==== Routing/Runners ====
This part of the Python API has not yet been ported and the tutorials could not be completed. [https://bugs.kde.org/show_bug.cgi?id=329364 see this bug for more info].


===Mac OS X===
==== GeoPainter ====
;[[/Routing/MarblePythonGeoPainter|Painting onto the map]]
;[[/MarblePythonLayerInterface|Drawing in Custom Layers]]


==== Qt-Only ====


Configure Marble with:
;[[/MarbleDBus|via a shell script]]
<pre>
cmake -DCMAKE_BUILD_TYPE=release -DQTONLY=ON -DCMAKE_INSTALL_PREFIX=/Applications/ ../marble
</pre>


To generate a Diskimage (.dmg) one can use this script (based on parts by Tim Sutton, thanks!):
== How to become a Marble developer ("Marblehead") ==


<code bash>
=== So you are new to Marble development ... ===
VERSION=0.7.1
APPNAME=Marble


VOLNAME=${APPNAME}-${VERSION}
<b>Welcome!</b>
DMGNAME=${VOLNAME}Uncompressed.dmg
COMPRESSEDDMGNAME=${VOLNAME}.dmg


function deploy_file() {
Here you'll get all the information you need to start Marble development:
for n in $(otool -L $1 | grep Qt); do
path=`echo $n | grep Qt`
    if [ $path ] ; then
    name=$(basename $path)
FRAMEWORKS="$FRAMEWORKS $name"
fi
done


for framework in $FRAMEWORKS ; do
;[[/GoMarble|How to become a Marble Developer]]
install_name_tool -change \
$framework.framework/Versions/4/$framework \
@executable_path/../Frameworks/$framework.framework/Versions/4/$framework \
$1
done
}


function deploy_plugins() {
== Compiling Marble ==
for plugin in $1/Contents/Resources/plugins/*; do
;[[/LinuxCompiling|Compiling on Linux]]
deploy_file $plugin
;[[/WindowsCompiling|Compiling on Windows]]
done
;[[/MaemoEnvironment|Compiling on Maemo]]
}
;[[/MeeGoEnvironment|Compiling on MeeGo]]
;[[/PlasmaActiveEnvironment|Compiling for Plasma Active]]
;[[/MacCompiling|Compiling on Mac OS]]
;[[/QtCreator|Setting up QtCreator for Marble Development]]


function set_bundle_display_options() {
== Packaging Marble ==
osascript <<-EOF
    tell application "Finder"
        set f to POSIX file ("${1}" as string) as alias
        tell folder f
            open
            tell container window
                set toolbar visible to false
                set statusbar visible to false
                set current view to icon view
                delay 1 -- sync
                set the bounds to {20, 50, 300, 400}
            end tell
            delay 1 -- sync
            set icon size of the icon view options of container window to 64
            set arrangement of the icon view options of container window to not arranged
            set position of item "Marble.app" to {100,150}
            set position of item "Applications" to {280, 150}
            set background picture of the icon view options of container window to file "background.png" of folder "Pictures"
            set the bounds of the container window to {0, 0, 300, 400}
            update without registering applications
            delay 5 -- sync
            close
        end tell
        delay 5 -- sync
    end tell
EOF


}
;[[/NewMarbleMoldules|New Marble Modules]] (future packaging advice)


function create_symlinks() {
Here is some advice about how packaging is supposed to happen on the various platforms that are supported.
cd "$1/Contents/Resources"
ln -s "../MacOS/resources/data/"    "data"
ln -s "../MacOS/resources/plugins/" "plugins"
cd -
}


;[[/LinuxPackaging|Packaging for Linux]]
;[[/WindowsPackaging|Packaging for Windows]]
;[[/MaemoPackaging|Packaging for Maemo]]
;[[/MeeGoPackaging|Packaging for MeeGo]]
;[[/MacPackaging|Packaging for Mac]]


== Tools for Marble ==


Here are some tools and checks that are performed on marble code:
;[https://bugs.kde.org/buglist.cgi?query_format=advanced&short_desc_type=allwordssubstr&short_desc=&product=marble&bug_status=UNCONFIRMED&bug_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED&cmdtype=doit&order=Importance Marble Open Bugs]
;[http://reviewboard.kde.org/groups/marble/ Review Board]
;[http://api.kde.org/4.x-api/kdeedu-apidocs/marble/html/index.html API Docs (KDE Trunk)]
;[http://www.englishbreakfastnetwork.org/apidocs/apidox-kde-4.x/kdeedu-marble.html APIDOX reports]
;[http://www.englishbreakfastnetwork.org/krazy/reports/kde-4.x/kdeedu/marble/index.html Krazy reports]


rm ~/Desktop/${DMGNAME}
== Programming Coordination ==
rm ~/Desktop/${COMPRESSEDDMGNAME}
hdiutil create -size 150m -fs HFS+ -volname ${VOLNAME} ~/Desktop/${DMGNAME}


# Mount the disk image
Here are a few links to various issues we are working on:
hdiutil attach ~/Desktop/${DMGNAME}
;[[Marble 2.0]]
;[[/TODO|TODO list]]
;[[/MaemoTODO|Maemo specific TODO list]]


# Obtain device information
=== Google Summer of Code / ESA SoCIS ===
DEVS=$(hdiutil attach ~/Desktop/${DMGNAME} | cut -f 1)
;[[/Gsoc2010| Gsoc Students projects 2010]]
DEV=$(echo $DEVS | cut -f 1 -d ' ')
;[[/GsocGit| Use of git(orious) for GSOC]]
VOLUME=$(mount |grep ${DEV} | cut -f 3 -d ' ')
;[[/GSoC2011| GSoC Students' projects 2011]]
;[http://community.kde.org/SoCiS/2011/Ideas#Marble_Virtual_Globe ESA SoCIS 2011 ideas]
;[[/GSoC2012| GSoC Students' projects 2012]]


# copy in the application bundle
=== Translation ===
cp -Rp /Applications/${APPNAME}.app ${VOLUME}/${APPNAME}.app
;[[/MapTranslation|Map Translation]]
 
;[[/UiTranslation|UI Translation]]
# fix the libs
;[[/GeoDataCoordinatesTranslation|GeoDataCoordinates Translation]]
macdeployqt ${VOLUME}/${APPNAME}.app
create_symlinks ${VOLUME}/${APPNAME}.app
deploy_file "${VOLUME}/${APPNAME}.app/Contents/MacOS/lib/libmarblewidget.7.dylib"
deploy_plugins ${VOLUME}/${APPNAME}.app
 
# copy in background image
mkdir -p ${VOLUME}/Pictures
# fixme: path
cp ~/Desktop/marble-dmg-background.png ${VOLUME}/Pictures/background.png
# symlink applications
ln -s /Applications/ ${VOLUME}/Applications
set_bundle_display_options ${VOLUME}
mv ${VOLUME}/Pictures ${VOLUME}/.Pictures
 
# Unmount the disk image
hdiutil detach $DEV
# Convert the disk image to read-only
hdiutil convert ~/Desktop/${DMGNAME} -format UDBZ -o ~/Desktop/${COMPRESSEDDMGNAME}
</code>
 
 
It uses the macdeployqt tool which copies Qt and its plugins into the App Bundle.
macdeployqt also tells the main application to link against the libs contained in the bundle, instead of the system libs.
This does not happen to the libmarblewidget and the Marble plugins, so it has to be done by the script.
The script also sets a background Image for the dmg. (Place it at ~/Desktop/marble-dmg-background.png or change the path in the script)
 
After that you should have Marble-version.dmg on you Desktop.
 
===Windows===
 
== Programming Coordination ==
 
Here are a few links to various issues we are working on:


=== User Interface ===
=== User Interface ===
;[[/Mockups|Mockups]]
;[[/Mockups|Mockups]]
;[[/IconStatus|Icon Status]]


=== Texture Mapping ===
=== Texture Mapping ===
Line 175: Line 131:


=== GeoData Library / KML ===
=== GeoData Library / KML ===
;[[/LibGeoData|GeoData Library]]
The base classes to manipulate geographic data
;[[/GeoData|GeoData Presentation]]
;[[/GeoData/GeoDataUse|Use cases for GeoData classes]]
;[http://websvn.kde.org/*checkout*/trunk/KDE/kdeedu/marble/src/lib/geodata/data/README.html GeoData API Description]
;[[/GeoData/GeoDataParsing|Parsing GeoData]]
;[[/GeoData/GeoDataWriter|Writing GeoData]]
;[[/GeoData/PointerVsImplicitShare|Pointer vs. Implicit Share]]
 
 
;[[/KMLStatus|KML Status]]
;[[/KMLStatus|KML Status]]
;[[/GPXStatus|GPX Status]]
;[[/GPXStatus|GPX Status]]
Using GeoData:
;[[/Placemark|Placemarks Management]]
;[[/ModelView|Review of Model-View use in marble]]
=== Geo Graphics View ===
;[[/GeoGraphicsViewOverview|Overview of the GeoGraphicsView]]
;[[/GraphicsViewGeoParser| Interaction between GeoData and GeoGraphicsView]]


=== GeoPainter / DGML ===
=== GeoPainter / DGML ===
;[[/GeoPainter|GeoPainter]]
;[[/GeoPainter|GeoPainter]]
;[[/Dgml|DGML]]
;[[/Dgml|DGML]]
=== Plugin Interfaces ===
;[[/Plugins|Plugin interfaces]]


=== Marble Runner ===
=== Marble Runner ===
Line 187: Line 162:
;[[/OsmNameFinderRunner|OSM Runner]]
;[[/OsmNameFinderRunner|OSM Runner]]
;[[/RunnerHOWTO|Runner HOWTO]]
;[[/RunnerHOWTO|Runner HOWTO]]
=== Online Services ===
;[[/ListOfPossibleOnlineServices|List of possible Online Services]]


=== Projections ===
=== Projections ===
;[[/WinkelIii|Winkel III]]
;[[/WinkelIii|Winkel III]]
;[[/RobinsonProjection|Robinson projection]]
[http://www.radicalcartography.net/?projectionref A little overview of map projections]


=== Tile Download ===
=== Tile Download ===
;[[/VectorTilingProposal|Vector Tiling Proposal]]
;[[/TileDownload|Tile Download]]
;[[/TileDownload|Tile Download]]


=== Documentation ===
=== Documentation ===
;[[/ApiDocs|API Docs]]
;[[/CustomMaps|How to customize maps]]
;[[/CustomMaps|How to customize maps]]
;[[/PNTFiles|How to change the PNT files used by Marble]]
;[[/MarblesSecrets|Marble's Secrets]]
;[[/MarblesSecrets|Marble's Secrets]]
;[[/ProxyConnection|How to use the Proxy]]
;[[/ProxyConnection|How to use the Proxy]]
Line 202: Line 183:
=== GeoClue / GPS ===
=== GeoClue / GPS ===
;[[/GeoClue|GeoClue support in Marble]]
;[[/GeoClue|GeoClue support in Marble]]
=== XDG Base Directory Specification ===
;[[/xdg|XDG Base Directory Specification]]


== Mapping Coordination ==
== Mapping Coordination ==
Possible maps we could use:
* [http://pelagios.dme.ait.ac.at/maps/greco-roman/ Tiled map of the classical world] see the [http://pelagios-project.blogspot.co.uk/2012/09/a-digital-map-of-roman-empire.html authors blog] for details
* [http://www.unearthedoutdoors.net/global_data/true_marble/download TrueMarble Global 250m images]
* [http://onearth.jpl.nasa.gov/ OnEarth NASA satellite images]
* [http://worldwindcentral.com/wiki/Add-on:ZoomIt! ZoomIt! (in parts proprietary)]
* [http://sos.noaa.gov/datasets/ NOAA Science on a Sphere]
* [http://efele.net/maps/tz/world/ Olsen Time Zone map in Shapefile format].  Public Domain.  Scripted to generate from current tz file.
=== Natural Earth Vector Map ===
;[[/NaturalEarth|A proposal to use the Natural Earth vector map]]
=== Documentation ===
=== Documentation ===
;[[/HistoricalMaps|How to create Historical Maps]]
;[[/HistoricalMaps|How to create Historical Maps]]
;[[/CustomMaps|How to create Custom Maps]]


;[[/PalaeoMaps|Global Palaeogeography]]
;[[/PalaeoMaps|Global Palaeogeography]]


== Routing ==
== Routing ==
;[[/RoutingIdeas|General ideas about routing]]
;[[/OnlineRoutingImplementation|Implementation of Online-Routing]]
;[[/MaemoOfflineRouting|Installation of Marble and Gosmore on Maemo]]
;[[/RoutingRoadmap|Routing Roadmap]]
;[[/RoutingInstructions|Routing Instructions]]
 
== valgrind  ==
if you want to fix memory leaks, you can run valgrind with:
 
valgrind --leak-check=full --track-origins=yes --num-callers=30 marble 2>&1 | tee MARBLE_MEMCHECK


== Meetings ==
== Meetings ==
Summaries and logs of scheduled Marble meetings can be found on the following pages:
Summaries and logs of scheduled Marble meetings can be found on the following pages:
;[[/MarbleMeeting20081029|Wednesday Nov. 10th, 2008]]
;[[/MarbleMeeting20081029|Wednesday Nov. 10th, 2008]]
;[[/MarbleMeeting20101107|Marble Weekend Sprint, Nov. 5-7]]

Revision as of 17:18, 19 May 2014


About Marble

Devices and Use Cases
Marble FAQ

Success Stories: 3rd party applications using the Marble Library

Software that makes use of Marble

Tutorials: How to use the Marble Widget in your application

with Qt Designer
On Windows, with Qt Creator/Qt Designer

With C++

Intro

Hello World
Changing basic map properties
Creating a window with controls

GeoData

Displaying GeoData Documents

Online Services

Creating new Online Services

Routing

Basic Routing

Runners

Searching for Points of Interest
Reverse Geocoding
Parsing Files

GeoPainter

Painting onto the map
Drawing in Custom Layers
Painting LineString

With Python

Intro

Installing Marble's Python bindings
Hello World
Changing basic map properties
Creating a window with controls

Loading Files

Loading KML files into Marble
Loading OSM files into Marble

GeoData

Display GeoData Placemark
Vehicle Tracking

Routing/Runners

This part of the Python API has not yet been ported and the tutorials could not be completed. see this bug for more info.

GeoPainter

Painting onto the map
Drawing in Custom Layers


via a shell script

How to become a Marble developer ("Marblehead")

So you are new to Marble development ...

Welcome!

Here you'll get all the information you need to start Marble development:

How to become a Marble Developer

Compiling Marble

Compiling on Linux
Compiling on Windows
Compiling on Maemo
Compiling on MeeGo
Compiling for Plasma Active
Compiling on Mac OS
Setting up QtCreator for Marble Development

Packaging Marble

New Marble Modules (future packaging advice)

Here is some advice about how packaging is supposed to happen on the various platforms that are supported.

Packaging for Linux
Packaging for Windows
Packaging for Maemo
Packaging for MeeGo
Packaging for Mac

Tools for Marble

Here are some tools and checks that are performed on marble code:

Marble Open Bugs
Review Board
API Docs (KDE Trunk)
APIDOX reports
Krazy reports

Programming Coordination

Here are a few links to various issues we are working on:

Marble 2.0
TODO list
Maemo specific TODO list

Google Summer of Code / ESA SoCIS

Gsoc Students projects 2010
Use of git(orious) for GSOC
GSoC Students' projects 2011
ESA SoCIS 2011 ideas
GSoC Students' projects 2012

Translation

Map Translation
UI Translation
GeoDataCoordinates Translation

User Interface

Mockups
Icon Status

Texture Mapping

Texture Mapping

GeoData Library / KML

The base classes to manipulate geographic data

GeoData Presentation
Use cases for GeoData classes
GeoData API Description
Parsing GeoData
Writing GeoData
Pointer vs. Implicit Share


KML Status
GPX Status

Using GeoData:

Placemarks Management
Review of Model-View use in marble

Geo Graphics View

Overview of the GeoGraphicsView
Interaction between GeoData and GeoGraphicsView

GeoPainter / DGML

GeoPainter
DGML

Plugin Interfaces

Plugin interfaces

Marble Runner

Coordinate Runner
OSM Runner
Runner HOWTO

Online Services

List of possible Online Services

Projections

Winkel III
Robinson projection

A little overview of map projections

Tile Download

Vector Tiling Proposal
Tile Download

Documentation

How to customize maps
How to change the PNT files used by Marble
Marble's Secrets
How to use the Proxy

GeoClue / GPS

GeoClue support in Marble

XDG Base Directory Specification

XDG Base Directory Specification

Mapping Coordination

Possible maps we could use:

Natural Earth Vector Map

A proposal to use the Natural Earth vector map


Documentation

How to create Historical Maps
How to create Custom Maps
Global Palaeogeography

Routing

Implementation of Online-Routing
Installation of Marble and Gosmore on Maemo
Routing Roadmap
Routing Instructions

valgrind

if you want to fix memory leaks, you can run valgrind with:

valgrind --leak-check=full --track-origins=yes --num-callers=30 marble 2>&1 | tee MARBLE_MEMCHECK

Meetings

Summaries and logs of scheduled Marble meetings can be found on the following pages:

Wednesday Nov. 10th, 2008
Marble Weekend Sprint, Nov. 5-7