Routino SVN Repository Browser

Check out the latest version of Routino: svn co http://routino.org/svn/trunk routino

ViewVC logotype

Annotation of /trunk/src/fakes.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1078 - (hide annotations) (download) (as text)
Fri Sep 28 16:34:20 2012 UTC (12 years, 6 months ago) by amb
File MIME type: text/x-chdr
File size: 1898 byte(s)
Rename some variables so that pointers to nodes, segments, ways and relations
use the Hungarian notation "p" suffix (only applies to the router, not
planetsplitter).

1 amb 533 /***************************************
2     Header file for fake node and segment function prototypes
3    
4     Part of the Routino routing software.
5     ******************/ /******************
6 amb 955 This file Copyright 2008-2012 Andrew M. Bishop
7 amb 533
8     This program is free software: you can redistribute it and/or modify
9     it under the terms of the GNU Affero General Public License as published by
10     the Free Software Foundation, either version 3 of the License, or
11     (at your option) any later version.
12    
13     This program is distributed in the hope that it will be useful,
14     but WITHOUT ANY WARRANTY; without even the implied warranty of
15     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16     GNU Affero General Public License for more details.
17    
18     You should have received a copy of the GNU Affero General Public License
19     along with this program. If not, see <http://www.gnu.org/licenses/>.
20     ***************************************/
21    
22    
23     #ifndef FAKES_H
24     #define FAKES_H /*+ To stop multiple inclusions. +*/
25    
26     #include "types.h"
27    
28    
29 amb 680 /* Macros */
30 amb 533
31     /*+ Return true if this is a fake node. +*/
32 amb 637 #define IsFakeNode(xxx) ((xxx)>=NODE_FAKE && (xxx)!=NO_NODE)
33 amb 533
34     /*+ Return true if this is a fake segment. +*/
35 amb 637 #define IsFakeSegment(xxx) ((xxx)>=SEGMENT_FAKE && (xxx)!=NO_SEGMENT)
36 amb 533
37 amb 680
38 amb 955 /* Functions in fakes.c */
39 amb 680
40 amb 1078 index_t CreateFakes(Nodes *nodes,Segments *segments,int point,Segment *segmentp,index_t node1,index_t node2,distance_t dist1,distance_t dist2);
41 amb 533
42 amb 608 void GetFakeLatLong(index_t fakenode, double *latitude,double *longitude);
43 amb 533
44 amb 608 Segment *FirstFakeSegment(index_t fakenode);
45 amb 1078 Segment *NextFakeSegment(Segment *fakesegmentp,index_t fakenode);
46 amb 608 Segment *ExtraFakeSegment(index_t realnode,index_t fakenode);
47 amb 533
48     Segment *LookupFakeSegment(index_t index);
49 amb 1078 index_t IndexFakeSegment(Segment *fakesegmentp);
50 amb 608 index_t IndexRealSegment(index_t fakesegment);
51 amb 533
52 amb 727 int IsFakeUTurn(index_t fakesegment1,index_t fakesegment2);
53 amb 533
54     #endif /* FAKES_H */