]>
Commit | Line | Data |
---|---|---|
1 | Naming: | |
2 | A "module" is a .c file. | |
3 | ||
4 | Functions starting with "vik_" operate on an object/structure with the module name (see layer.c for an example). | |
5 | Functions starting with "a_" do not, these modules may have static variables. | |
6 | Both are followed by the module name. Unless of course the function is static, in which case it may be called anything. | |
7 | ||
8 | All (well, practically all) global constants and macros start with "VIK_" and then the module name. | |
9 | ||
10 | ---- | |
11 | ||
12 | The layers panel holds all the layers. Layers connect to the layers panel via what I call "interfaces" which are really just a | |
13 | structure of function pointers and pointers to other bits such as icons. viklayer.c switches between the layers like | |
14 | polymorhpism. Anything specific to the layer should (in theory) be found solely in that layer's source file. | |
15 | ||
16 | There are some ugly hacks in here, like the layers panel holding the viewport and each layer holding the viewport and a | |
17 | GtkTreeIter. Unfortunately it was the only way I could figure out to do some things. It would be _much_ easier with a | |
18 | object-oriented language. | |
19 | ||
20 | --- | |
21 | ||
22 | "xmpp" and "ympp" are really misnomers, as they only represent the Meters Per Pixel in UTM mode. Otherwise they are an artificial | |
23 | zooming system. In expedia mode it represents the "Alti", in Google mode it represents 2^(scale), e.g. 2^0 = 1, 2^8 = 256. |