]> git.tdb.fi Git - r2c2.git/log
r2c2.git
14 years agoAllow negative counts for writing off tracks
Mikko Rasa [Tue, 26 Oct 2010 18:33:20 +0000 (18:33 +0000)]
Allow negative counts for writing off tracks

14 years agoLimit Z difference when linking tracks
Mikko Rasa [Tue, 26 Oct 2010 18:32:42 +0000 (18:32 +0000)]
Limit Z difference when linking tracks
Correctly set track Z positions when snapped
Eliminate a glitch with new tracks

14 years agoDon't give out a turnout ID that's already in use
Mikko Rasa [Tue, 26 Oct 2010 18:30:46 +0000 (18:30 +0000)]
Don't give out a turnout ID that's already in use

14 years agoDo not show path on new tracks
Mikko Rasa [Tue, 26 Oct 2010 08:39:37 +0000 (08:39 +0000)]
Do not show path on new tracks
Display errors from add_tracks_to_route in status bar
Adjust rendering pipeline to better support semi-transparent base objects

14 years agoSeparate track wrap to its own class
Mikko Rasa [Mon, 25 Oct 2010 18:12:23 +0000 (18:12 +0000)]
Separate track wrap to its own class

14 years agoMove Endpoint inside TrackType
Mikko Rasa [Mon, 25 Oct 2010 16:08:57 +0000 (16:08 +0000)]
Move Endpoint inside TrackType

14 years agoAdd TrackIter and BlockIter classes
Mikko Rasa [Mon, 25 Oct 2010 13:30:36 +0000 (13:30 +0000)]
Add TrackIter and BlockIter classes
Remove the traverse functions in favor of the iterators

14 years agoDisplay the total length of selected tracks in status bar
Mikko Rasa [Mon, 25 Oct 2010 11:41:51 +0000 (11:41 +0000)]
Display the total length of selected tracks in status bar
Reuse Shift+L to select blocks

14 years agoMaintain a Block pointer in Track
Mikko Rasa [Mon, 25 Oct 2010 11:40:33 +0000 (11:40 +0000)]
Maintain a Block pointer in Track
Drop Layout::get_block_by_track

14 years agoAdd Block::has_track and Route::has_track methods
Mikko Rasa [Fri, 22 Oct 2010 21:22:41 +0000 (21:22 +0000)]
Add Block::has_track and Route::has_track methods

14 years agoMake Route hold non-const Tracks to match Block
Mikko Rasa [Fri, 22 Oct 2010 21:08:17 +0000 (21:08 +0000)]
Make Route hold non-const Tracks to match Block
Make several functions take non-const parameters to avoid escaping constness:
- Track::get_endpoint_by_link
- Block::get_endpoint_by_link
- Layout3D::get_track

14 years agoUI tweaks
Mikko Rasa [Thu, 21 Oct 2010 12:56:28 +0000 (12:56 +0000)]
UI tweaks

14 years agoAdd a timetable row type to wait for another train
Mikko Rasa [Thu, 21 Oct 2010 10:56:16 +0000 (10:56 +0000)]
Add a timetable row type to wait for another train

14 years agoBetter lead route generation
Mikko Rasa [Thu, 21 Oct 2010 10:55:35 +0000 (10:55 +0000)]
Better lead route generation

14 years agoUse per-layout state files
Mikko Rasa [Tue, 19 Oct 2010 16:34:25 +0000 (16:34 +0000)]
Use per-layout state files
Add command line option to specify state file

14 years agoAdd a variant of Route::find that takes a set of tracks
Mikko Rasa [Tue, 19 Oct 2010 16:32:20 +0000 (16:32 +0000)]
Add a variant of Route::find that takes a set of tracks
Allow setting turnouts in a Route manually
Move Route::update_turnouts to its proper place
Add full route chaining to Train
Better logic for where to start pathfinding
Divert trains to an alternate route if possible when blocked

14 years agoReserve two ids for double-address turnouts
Mikko Rasa [Fri, 15 Oct 2010 19:15:10 +0000 (19:15 +0000)]
Reserve two ids for double-address turnouts
Report track z coordinate correctly for turnouts
Don't reserve more blocks when arriving at end of route
Add a small offset when placing a train after loading

14 years agoDo not require unique names for routes
Mikko Rasa [Fri, 15 Oct 2010 17:32:53 +0000 (17:32 +0000)]
Do not require unique names for routes
Support renaming routes
Add delete and rename buttons for routes in designer's toolbar

14 years agoGenerate IDs for new turnouts
Mikko Rasa [Thu, 14 Oct 2010 19:25:50 +0000 (19:25 +0000)]
Generate IDs for new turnouts
Update routes when a turnout ID is changed
Properly support non-loop routes
Link tracks as they are loaded
Don't move tracks when linking if one of them is flexible
Move route rebuilding to the Route class

14 years agoAdd new vehicles:
Mikko Rasa [Thu, 14 Oct 2010 19:11:27 +0000 (19:11 +0000)]
Add new vehicles:
BR E 41
B4nzb 64
Sgns 691
Fals-u 176

14 years agoBugfixes
Mikko Rasa [Thu, 14 Oct 2010 19:03:05 +0000 (19:03 +0000)]
Bugfixes

14 years agoRendering improvements
Mikko Rasa [Sun, 10 Oct 2010 18:26:19 +0000 (18:26 +0000)]
Rendering improvements

14 years agoAdd TrainView for viewing the layout from the train's perspective
Mikko Rasa [Sun, 10 Oct 2010 10:18:00 +0000 (10:18 +0000)]
Add TrainView for viewing the layout from the train's perspective
Make TrainPanel collapsible to save space
Add button for taking train off the track

14 years agoSupport taking trains off the tracks
Mikko Rasa [Sun, 10 Oct 2010 09:21:07 +0000 (09:21 +0000)]
Support taking trains off the tracks
Don't give up a block that still has vehicles on it
Fix get_reserved_distance after placing a long train
Don't use speed steps more than 3 above the last known one

14 years agoSet correct Z coordinate to vehicle position
Mikko Rasa [Sat, 9 Oct 2010 10:40:50 +0000 (10:40 +0000)]
Set correct Z coordinate to vehicle position
Render vehicle axles

14 years agoRework the UI elements for a smoother and more uniform look
Mikko Rasa [Wed, 6 Oct 2010 13:07:01 +0000 (13:07 +0000)]
Rework the UI elements for a smoother and more uniform look
Add styles for vsliders and multiline entries
Add selection indicator to lists

14 years agoCreate a more generic version of Train::get_reserved_distance
Mikko Rasa [Mon, 4 Oct 2010 19:59:30 +0000 (19:59 +0000)]
Create a more generic version of Train::get_reserved_distance
Use it to determine if a trailing non-sensor block can be freed
Don't release blocks if there's not enough distance for stopping
Reserve enough blocks to maintain speed

14 years agoAdd an overload of Block::traverse that takes a Route
Mikko Rasa [Sun, 3 Oct 2010 18:56:38 +0000 (18:56 +0000)]
Add an overload of Block::traverse that takes a Route
Improved handling of taking blocks from another train
Add yield system for trains of equal priority

14 years agoUse RAII for setting the anti-recursion flags
Mikko Rasa [Sun, 3 Oct 2010 18:31:48 +0000 (18:31 +0000)]
Use RAII for setting the anti-recursion flags
Fix some crashes with empty cur_blocks
Refuse to give up the last of cur_blocks

14 years agoPrevent some undesirable recursive calls
Mikko Rasa [Sun, 3 Oct 2010 13:27:54 +0000 (13:27 +0000)]
Prevent some undesirable recursive calls

14 years agoAdd error reporting to the Intellibox driver
Mikko Rasa [Sat, 2 Oct 2010 11:48:08 +0000 (11:48 +0000)]
Add error reporting to the Intellibox driver

14 years agoAdd reverse and arrival row types to Timetable
Mikko Rasa [Sat, 2 Oct 2010 11:47:33 +0000 (11:47 +0000)]
Add reverse and arrival row types to Timetable
Change "go to" into "set route to"
More flexible row parameters
Add Row::save method

14 years agoFix vacated distance calculation when moving backwards
Mikko Rasa [Sat, 2 Oct 2010 11:41:44 +0000 (11:41 +0000)]
Fix vacated distance calculation when moving backwards
Be consistent with vehicle placement when placing a train

14 years agoPlace vehicles on the track when attached
Mikko Rasa [Fri, 1 Oct 2010 12:20:14 +0000 (12:20 +0000)]
Place vehicles on the track when attached
Fix Vehicle::attach_front to actually attach to the front
Initialize VehicleType::locomotive

14 years agoMake vehicles trigger sensors as they pass over them, allowing full simulation
Mikko Rasa [Tue, 28 Sep 2010 14:03:45 +0000 (14:03 +0000)]
Make vehicles trigger sensors as they pass over them, allowing full simulation

14 years agoMove the TrainControl inside the Controller class
Mikko Rasa [Mon, 27 Sep 2010 20:34:00 +0000 (20:34 +0000)]
Move the TrainControl inside the Controller class
Rename a field in AIControl

14 years agoRename ControlModel to Controller
Mikko Rasa [Mon, 27 Sep 2010 20:27:45 +0000 (20:27 +0000)]
Rename ControlModel to Controller
Rename SimplePhysics to SimpleController

14 years agoChange the control system to separate speed and reverse
Mikko Rasa [Sun, 26 Sep 2010 19:53:02 +0000 (19:53 +0000)]
Change the control system to separate speed and reverse
Don't emit signal_arrived until the train has stopped
Slow down for the last stretch at the end of reserved track

14 years agoAvoid various problems associated with dead end blocks
Mikko Rasa [Sun, 26 Sep 2010 11:26:23 +0000 (11:26 +0000)]
Avoid various problems associated with dead end blocks
Deal with nonexistent blocks while loading trains

14 years agoFull vehicle unification
Mikko Rasa [Sun, 26 Sep 2010 09:28:16 +0000 (09:28 +0000)]
Full vehicle unification
Add controls for adding vehicles to TrainProperties

14 years agoAdd some utility functions for interfacing with hardware
Mikko Rasa [Sat, 25 Sep 2010 08:46:20 +0000 (08:46 +0000)]
Add some utility functions for interfacing with hardware
Improve makefile to support uploading to Arduino Mini
Expand s88w protocol to support multiple transmitters
Add lcd output to s88w-r for debugging

14 years agoMake better use of GL::Pipeline
Mikko Rasa [Thu, 16 Sep 2010 19:42:27 +0000 (19:42 +0000)]
Make better use of GL::Pipeline
Double the amount of segments in curved tracks
Adapt to mspgl changes

14 years agoCopy position and rotation when duplicating tracks
Mikko Rasa [Thu, 16 Sep 2010 19:41:21 +0000 (19:41 +0000)]
Copy position and rotation when duplicating tracks

14 years agoAdd some new vehicles
Mikko Rasa [Sat, 1 May 2010 13:29:16 +0000 (13:29 +0000)]
Add some new vehicles
Give proper type codes for the tank wagons

14 years agoAdd wireless s88 firmware and schematic
Mikko Rasa [Fri, 30 Apr 2010 20:47:18 +0000 (20:47 +0000)]
Add wireless s88 firmware and schematic

14 years agoDon't clear timetable before all rows are successfully parsed
Mikko Rasa [Mon, 26 Apr 2010 09:09:21 +0000 (09:09 +0000)]
Don't clear timetable before all rows are successfully parsed
Do a more complete reset of timetable state when clearing
Also reset timetable state when toggling enabled state

14 years agoAdd a UI for editing train timetables
Mikko Rasa [Sat, 24 Apr 2010 21:01:15 +0000 (21:01 +0000)]
Add a UI for editing train timetables
Add an enabled flag to Timetable
Display turnout and sensor ids when clicked

14 years agoFix a compile error
Mikko Rasa [Sat, 24 Apr 2010 18:04:08 +0000 (18:04 +0000)]
Fix a compile error
Handle a null train properly in TrainProperties constructor
Print emergencies to stdout
Report sensor number in unreserved sensor triggers
Never update real_speed[0]
Return a nonzero value if no speeds are recorded yet

14 years agoDon't reserve blocks when not active
Mikko Rasa [Fri, 23 Apr 2010 19:29:58 +0000 (19:29 +0000)]
Don't reserve blocks when not active

14 years agoImplement train priority system
Mikko Rasa [Fri, 23 Apr 2010 19:28:39 +0000 (19:28 +0000)]
Implement train priority system

14 years agoHandle reversing in a way that allows backing out of a dead end
Mikko Rasa [Fri, 23 Apr 2010 18:21:12 +0000 (18:21 +0000)]
Handle reversing in a way that allows backing out of a dead end

14 years agoDo not render unplaced vehicles
Mikko Rasa [Fri, 23 Apr 2010 18:05:44 +0000 (18:05 +0000)]
Do not render unplaced vehicles

14 years agoRelease non-sensor blocks when the tail end of the train has passed far enough
Mikko Rasa [Fri, 23 Apr 2010 17:21:00 +0000 (17:21 +0000)]
Release non-sensor blocks when the tail end of the train has passed far enough

14 years agoMark train positions as inaccurate on halt
Mikko Rasa [Fri, 23 Apr 2010 17:11:35 +0000 (17:11 +0000)]
Mark train positions as inaccurate on halt

14 years agoFix problems with turnouts
Mikko Rasa [Fri, 23 Apr 2010 17:11:04 +0000 (17:11 +0000)]
Fix problems with turnouts

14 years agoMark generated routes as temporary and don't show or save them
Mikko Rasa [Fri, 23 Apr 2010 17:05:18 +0000 (17:05 +0000)]
Mark generated routes as temporary and don't show or save them
Fix a segfault with unplaced trains
Handle end-of-line gracefully in various places

14 years agoOnly pick once per rendered frame
Mikko Rasa [Fri, 23 Apr 2010 16:31:59 +0000 (16:31 +0000)]
Only pick once per rendered frame
Don't add new routes to layout manually

14 years agoAdd a separate double_address flag to TrackType
Mikko Rasa [Wed, 21 Apr 2010 23:08:10 +0000 (23:08 +0000)]
Add a separate double_address flag to TrackType

14 years agoHalt all trains in various unexpected situations
Mikko Rasa [Wed, 21 Apr 2010 19:20:46 +0000 (19:20 +0000)]
Halt all trains in various unexpected situations
Turnouts no longer get stuck if a switching attempt fails
Save the vehicles of trains in state file
It's better to put trains too far back rather than forward

14 years agoAdd some more wagons
Mikko Rasa [Mon, 19 Apr 2010 04:38:00 +0000 (04:38 +0000)]
Add some more wagons
Add 3D models for nearly all vehicles

14 years agoPlug memory leaks
Mikko Rasa [Sun, 18 Apr 2010 11:28:17 +0000 (11:28 +0000)]
Plug memory leaks
Set correct aspect ratio to camera
Add serial to svn:ignore

14 years agoRender vehicles with real 3D models
Mikko Rasa [Sun, 18 Apr 2010 11:16:37 +0000 (11:16 +0000)]
Render vehicles with real 3D models

14 years agoSupport trains with multiple vehicles
Mikko Rasa [Sat, 17 Apr 2010 11:00:55 +0000 (11:00 +0000)]
Support trains with multiple vehicles
Correct positioning of vehicles with bogies

14 years agoEmit signal for control changes initiated by the control model itself
Mikko Rasa [Fri, 16 Apr 2010 19:42:44 +0000 (19:42 +0000)]
Emit signal for control changes initiated by the control model itself
Fix the speed display format in train panel

14 years agoAdd timetable-based operation
Mikko Rasa [Fri, 16 Apr 2010 18:26:06 +0000 (18:26 +0000)]
Add timetable-based operation

14 years agoFix pathfinder to not block itself in some situations
Mikko Rasa [Wed, 14 Apr 2010 21:06:34 +0000 (21:06 +0000)]
Fix pathfinder to not block itself in some situations
Better handling of routes at the beginning of Train::reserve_more
Delay clearing route until stopping

14 years agoFoundations of using physics simulation for trains
Mikko Rasa [Mon, 12 Apr 2010 20:49:54 +0000 (20:49 +0000)]
Foundations of using physics simulation for trains

14 years agoHandle vehicle positioning while going backwards
Mikko Rasa [Mon, 12 Apr 2010 09:56:02 +0000 (09:56 +0000)]
Handle vehicle positioning while going backwards
More sensible initial vehicle placement
Activate occupied sensors while loading trains

14 years agoDon't send redundant loco commands
Mikko Rasa [Mon, 12 Apr 2010 04:55:33 +0000 (04:55 +0000)]
Don't send redundant loco commands
Avoid confusing the IntelliBox by sending multiple commands at once in flush

14 years agoAdd vehicles
Mikko Rasa [Tue, 6 Apr 2010 08:08:54 +0000 (08:08 +0000)]
Add vehicles
Fix direction in Track::get_point
Add overload of Track::get_point that uses the current path

14 years agoAdd a set_sensor function to the Driver interface
Mikko Rasa [Mon, 5 Apr 2010 13:35:46 +0000 (13:35 +0000)]
Add a set_sensor function to the Driver interface
Bring back the simulation mode in Engineer

14 years agoAdd a program for serial port control and associated Arduino firmware
Mikko Rasa [Sat, 3 Apr 2010 09:49:02 +0000 (09:49 +0000)]
Add a program for serial port control and associated Arduino firmware
Make network client handle error packets
Add function to get all trains from the client

14 years agoGenerate loco events from the Dummy driver
Mikko Rasa [Tue, 30 Mar 2010 11:26:02 +0000 (11:26 +0000)]
Generate loco events from the Dummy driver
Don't emit a turnout event if the turnout was already in the correct setting

14 years agoAdd both addresses of a double-address turnout
Mikko Rasa [Tue, 23 Mar 2010 21:14:38 +0000 (21:14 +0000)]
Add both addresses of a double-address turnout
Fix get_point to accept a distance exactly equal to the path length

14 years agoIf a train is not on the specified route, find a route to it
Mikko Rasa [Tue, 23 Mar 2010 21:14:25 +0000 (21:14 +0000)]
If a train is not on the specified route, find a route to it

14 years agoAdd a pathfinder function to Route
Mikko Rasa [Sat, 20 Mar 2010 11:42:43 +0000 (11:42 +0000)]
Add a pathfinder function to Route
Implement train go-to functionality
Stop train when arriving at the end of its route
Fix a bug with multi-address turnouts
Add a Z offset to Path3D
Rewrite track picking in Engineer

14 years agoShow each train's blocks in a unique color
Mikko Rasa [Tue, 16 Mar 2010 17:26:49 +0000 (17:26 +0000)]
Show each train's blocks in a unique color

14 years agoReimplement path display
Mikko Rasa [Sun, 14 Mar 2010 20:16:37 +0000 (20:16 +0000)]
Reimplement path display
Make it possible to fill Profiles from code
Initialize Track::active_path to a valid value

14 years agoBugfixes
Mikko Rasa [Fri, 12 Mar 2010 09:37:40 +0000 (09:37 +0000)]
Bugfixes

14 years agoTurn TrackPart into a proper class
Mikko Rasa [Fri, 12 Mar 2010 09:29:16 +0000 (09:29 +0000)]
Turn TrackPart into a proper class
Link TrackParts to each other for better efficiency in get_point
Move most of get_point to TrackType
Return direction and grade from get_point in addition to position

14 years agoMajor architecture rework
Mikko Rasa [Mon, 8 Mar 2010 21:53:29 +0000 (21:53 +0000)]
Major architecture rework
Create a Driver abstraction to hide the code that talks to the physical equipment
Remove TrafficManager and put Blocks and Trains in Layout
Dynamically update Blocks as the layout changes
Remove Locomotive, Turnout and Sensor classes
Tracks now have an active_path property
Trains now allows setting functions
Move option parsing in Engineer to a separate class
Many minor changes

14 years agoForgot to add the new files
Mikko Rasa [Sun, 7 Mar 2010 10:33:15 +0000 (10:33 +0000)]
Forgot to add the new files

14 years agoEmit various signals from Train when it's loaded
Mikko Rasa [Wed, 3 Mar 2010 21:56:51 +0000 (21:56 +0000)]
Emit various signals from Train when it's loaded
Add Train3D class
Add Object3D class as base for Track3D and Train3D
Make Overlay3D use Object3Ds
Overhaul Engineer code

14 years agoAdd accessors adding things to a Catalogue from the outside
Mikko Rasa [Mon, 1 Mar 2010 20:35:46 +0000 (20:35 +0000)]
Add accessors adding things to a Catalogue from the outside
Emit signals from Catalogue as things are added
Make Catalogue3D listen to the signals and create appropriate things
Remove the track color and quality interfaces

14 years agoRename Input to InputDialog to avoid the conflict with the Msp::Input namespace
Mikko Rasa [Sun, 28 Feb 2010 12:56:24 +0000 (12:56 +0000)]
Rename Input to InputDialog to avoid the conflict with the Msp::Input namespace
Derive InputDialog from GLtk::Dialog
Get events from the Root widget rather than the Window
No need for the input pointer or state in Designer anymore
Add tooltips to the Toolbar
Implement a few more of the Toolbar buttons

14 years agoUse the Root widget for tooltips
Mikko Rasa [Fri, 26 Feb 2010 10:54:32 +0000 (10:54 +0000)]
Use the Root widget for tooltips
Add a status bar for non-tooltip-like status messages

14 years agoFix memory leaks and other bad stuff
Mikko Rasa [Thu, 25 Feb 2010 20:56:20 +0000 (20:56 +0000)]
Fix memory leaks and other bad stuff

14 years agoAdd an overlay to display aspects of tracks
Mikko Rasa [Thu, 25 Feb 2010 18:03:21 +0000 (18:03 +0000)]
Add an overlay to display aspects of tracks

14 years agoUse a GL::Camera
Mikko Rasa [Wed, 24 Feb 2010 21:56:28 +0000 (21:56 +0000)]
Use a GL::Camera
Move camera controls to a separate class

14 years agoAdd an internal layout to Catalogue for selecting tracks
Mikko Rasa [Sun, 21 Feb 2010 22:00:50 +0000 (22:00 +0000)]
Add an internal layout to Catalogue for selecting tracks
Restructure Designer init/deinit code
Add tracks to Layout3D when it's created

14 years agoUse GL::Renderables and a Pipeline for rendering
Mikko Rasa [Sun, 21 Feb 2010 20:01:37 +0000 (20:01 +0000)]
Use GL::Renderables and a Pipeline for rendering
Add lighting to designer

14 years agoSplit mesh generation from Track3D to TrackType3D
Mikko Rasa [Fri, 19 Feb 2010 15:44:09 +0000 (15:44 +0000)]
Split mesh generation from Track3D to TrackType3D
Add a Catalogue3D to hold the TrackType3D objects
Better parametrization of track profile
Make track profile loadable from the catalogue file
Track colors and path rendering is non-funtional at the moment

14 years agoFix some problems with loading routes
Mikko Rasa [Wed, 27 Jan 2010 21:17:22 +0000 (21:17 +0000)]
Fix some problems with loading routes
Document some algorithms with comments
Add paths to the double-slip turnout

14 years agoImprove the block allocation algorithm
Mikko Rasa [Wed, 30 Dec 2009 18:32:26 +0000 (18:32 +0000)]
Improve the block allocation algorithm

14 years agoStop all trains when Engineer exits
Mikko Rasa [Sun, 27 Dec 2009 07:51:03 +0000 (07:51 +0000)]
Stop all trains when Engineer exits
Handle some abnormal termination conditions as well

14 years agoGet rid of Train::try_reserve and listen to signal_block_reserved instead
Mikko Rasa [Sat, 26 Dec 2009 20:35:30 +0000 (20:35 +0000)]
Get rid of Train::try_reserve and listen to signal_block_reserved instead
Fix release_blocks so it doesn't cause discrepancies in state

14 years agoStore routes in a map by name rather than a set
Mikko Rasa [Sat, 26 Dec 2009 19:36:38 +0000 (19:36 +0000)]
Store routes in a map by name rather than a set

14 years agoImprove the handling of sensor events in Train
Mikko Rasa [Sat, 26 Dec 2009 19:26:00 +0000 (19:26 +0000)]
Improve the handling of sensor events in Train

14 years agoCompute deterministic IDs for blocks
Mikko Rasa [Sat, 26 Dec 2009 09:29:23 +0000 (09:29 +0000)]
Compute deterministic IDs for blocks
Save train route and block information

14 years agoDon't advance the estimated train position outside current blocks
Mikko Rasa [Tue, 22 Dec 2009 18:54:28 +0000 (18:54 +0000)]
Don't advance the estimated train position outside current blocks