summaryrefslogtreecommitdiff
path: root/app/bin/compound.h
diff options
context:
space:
mode:
authorJörg Frings-Fürst <debian@jff-webhosting.net>2020-08-08 11:53:12 +0200
committerJörg Frings-Fürst <debian@jff-webhosting.net>2020-08-08 11:53:12 +0200
commite50482f994b6ebcce864a412111d376e99205cdb (patch)
treeff3192c6aaf213c4922521bed988e4ed4147f537 /app/bin/compound.h
parentd3897ce090dbeb220ed2c782f095597e417cf3cc (diff)
parentb623f5953691b2a0614e6f1f4def86bdbb9a4113 (diff)
Update upstream source from tag 'upstream/5.2.0Beta2.1'
Update to upstream version '5.2.0Beta2.1' with Debian dir 1576f25f4c1496abfed44af31ead67d32c7be650
Diffstat (limited to 'app/bin/compound.h')
-rw-r--r--app/bin/compound.h24
1 files changed, 19 insertions, 5 deletions
diff --git a/app/bin/compound.h b/app/bin/compound.h
index 4845f78..b4c63ca 100644
--- a/app/bin/compound.h
+++ b/app/bin/compound.h
@@ -26,7 +26,7 @@
#include "common.h"
#include "track.h"
-typedef enum { TOnormal, TOadjustable, TOpierInfo, TOpier, TOcarDesc, TOlast } TOspecial_e;
+typedef enum { TOnormal, TOadjustable, TOpierInfo, TOpier, TOcarDesc, TOlast, TOcurved } TOspecial_e;
typedef struct {
char * name;
@@ -44,6 +44,9 @@ typedef union {
FLOAT_T height;
char * name;
} pier;
+ struct {
+ dynArr_t radii;
+ } curved;
} turnoutInfo_u;
typedef struct turnoutInfo_t{
@@ -91,6 +94,8 @@ struct extraData {
PATHPTR_T pathCurr;
wIndex_t segCnt;
trkSeg_t * segs;
+ DIST_T * radii;
+ drawLineType_e lineType;
};
#endif
@@ -111,6 +116,7 @@ extern turnoutInfo_t * curStructure;
#define ADJUSTABLE "adjustable"
#define PIER "pier"
+#define CURVED "curvedends"
/* compound.c */
#define FIND_TURNOUT (1<<11)
@@ -129,14 +135,15 @@ void DrawCompoundDescription( track_p, drawCmd_p, wDrawColor );
DIST_T DistanceCompound( track_p, coOrd * );
void DescribeCompound( track_p, char *, CSIZE_T );
void DeleteCompound( track_p );
-track_p NewCompound( TRKTYP_T, TRKINX_T, coOrd, ANGLE_T, char *, EPINX_T, trkEndPt_t *, int, char *, wIndex_t, trkSeg_p );
+track_p NewCompound( TRKTYP_T, TRKINX_T, coOrd, ANGLE_T, char *, EPINX_T, trkEndPt_t *, DIST_T *, int, char *, wIndex_t, trkSeg_p );
BOOL_T WriteCompound( track_p, FILE * );
-void ReadCompound( char *, TRKTYP_T );
+BOOL_T ReadCompound( char *, TRKTYP_T );
void MoveCompound( track_p, coOrd );
void RotateCompound( track_p, coOrd, ANGLE_T );
void RescaleCompound( track_p, FLOAT_T );
void FlipCompound( track_p, coOrd, ANGLE_T );
BOOL_T EnumerateCompound( track_p );
+void SetCompoundLineType( track_p trk, int width );
/* cgroup.c */
void UngroupCompound( track_p );
@@ -147,27 +154,34 @@ void DoGroup( void );
void UpdateTitleMark( char *, SCALEINX_T );
void DoUpdateTitles( void );
BOOL_T RefreshCompound( track_p, BOOL_T );
+wIndex_t FindListItemByContext( wList_p, void *);
+
/* cturnout.c */
EPINX_T TurnoutPickEndPt( coOrd p, track_p );
+BOOL_T SplitTurnoutCheck(track_p,coOrd,EPINX_T ep,track_p *,EPINX_T *,EPINX_T *,BOOL_T check, coOrd *, ANGLE_T *);
void GetSegInxEP( signed char, int *, EPINX_T * );
+void SetSegInxEP( signed char *, int, EPINX_T) ;
wIndex_t CheckPaths( wIndex_t, trkSeg_p, PATHPTR_T );
-turnoutInfo_t * CreateNewTurnout( char *, char *, wIndex_t, trkSeg_p, wIndex_t, PATHPTR_T, EPINX_T, trkEndPt_t *, wBool_t );
+turnoutInfo_t * CreateNewTurnout( char *, char *, wIndex_t, trkSeg_p, wIndex_t, PATHPTR_T, EPINX_T, trkEndPt_t *, DIST_T *, wBool_t );
+void DeleteTurnoutParams(int fileInx);
turnoutInfo_t * TurnoutAdd( long, SCALEINX_T, wList_p, coOrd *, EPINX_T );
STATUS_T CmdTurnoutAction( wAction_t, coOrd );
BOOL_T ConnectAdjustableTracks( track_p trk1, EPINX_T ep1, track_p trk2, EPINX_T ep2 );
track_p NewHandLaidTurnout( coOrd, ANGLE_T, coOrd, ANGLE_T, coOrd, ANGLE_T, ANGLE_T );
void NextTurnoutPosition( track_p trk );
-
+enum paramFileState GetTrackCompatibility(int paramFileIndex, SCALEINX_T scaleIndex);
/* ctodesgn.c */
void EditCustomTurnout( turnoutInfo_t *, turnoutInfo_t * );
long ComputeTurnoutRoadbedSide( trkSeg_p, int, int, ANGLE_T, DIST_T );
/* cstruct.c */
turnoutInfo_t * CreateNewStructure( char *, char *, wIndex_t, trkSeg_p, BOOL_T );
+enum paramFileState GetStructureCompatibility(int paramFileIndex, SCALEINX_T scaleIndex);
turnoutInfo_t * StructAdd( long, SCALEINX_T, wList_p, coOrd * );
STATUS_T CmdStructureAction( wAction_t, coOrd );
BOOL_T StructLoadCarDescList( wList_p );
+void DeleteStructures(int fileIndex);
/* cstrdsgn.c */
void EditCustomStructure( turnoutInfo_t * );