jerrrrycho
71b338f30e
refactor(sonar): remove unused variables, captures and private fields (cpp:S1481, cpp:S1068)
2026-10-10 20:44:41 +02:00
jerrrrycho
413009e59e
refactor(sonar): use auto where the type is spelled out on the right (cpp:S5827)
2026-10-10 20:44:39 +02:00
jerrrrycho
6fce71af36
refactor(sonar): scope single-use variables in if init-statements (cpp:S6004)
2026-10-10 20:44:38 +02:00
jerrrrycho
0d886e65ec
refactor(sonar): merge collapsible nested if statements (cpp:S1066)
...
Comments that preceded the inner if are kept above the merged statement.
2026-10-10 20:44:37 +02:00
jerrrrycho
8042953b95
refactor(sonar): declare non-mutating member functions const (cpp:S5817)
...
Virtual functions are left untouched so overrides keep matching.
2026-10-10 20:44:37 +02:00
jerrrrycho
01d2b9bf82
refactor(sonar): mark unused parameters (cpp:S1172)
...
Unused names are commented out; parameters used only on some platforms
are marked [[maybe_unused]].
2026-10-10 20:44:36 +02:00
jerrrrycho
ad32f1f840
refactor(sonar): make narrowing conversions explicit (cpp:S5276)
2026-10-10 20:44:35 +02:00
jerrrrycho
6b0617cc97
refactor(sonar): drop redundant lambda return types (cpp:S3574)
2026-10-10 20:44:31 +02:00
jerrrrycho
c4738dbc87
refactor(sonar): remove empty statements, one declaration per statement (cpp:S1116, cpp:S1659)
2026-10-10 20:44:31 +02:00
7d331ee65a
Editor: brace ImGui clipper loops, rename scenery wizard file name field
2026-10-10 19:55:50 +02:00
dab227d16d
Editor: keep the terrain palette rotation/repeat values when the slider is released
2026-10-10 18:19:10 +02:00
7b9eaf1ccb
Editor terrain: area fill with blurred or sharp edge, texture rotation
2026-10-10 17:35:52 +02:00
63302c1ace
Editor terrain: soft stitching to tracks, chunk resolution conversion, water materials
2026-10-10 16:08:12 +02:00
243ce636a7
Editor terrain: level brush with height picker, faster orthophoto fit
2026-10-10 01:27:48 +02:00
8cd0bab27b
Editor terrain: texture browser, undo, conversion from terrain files
...
- Terrain work mode shows a browser of the textures folder in place of the
node bank; textures/materials can be dragged onto the palette entries
(replacing the material), the material field and the water material field
- Ctrl+Z/Ctrl+Y for heightmap terrain changes: a brush stroke or an
operation is one step of the editor history
- Ground conversion reads only the files of the terrain directives
(.txtf with origin/rotate, or .btf without text), paints the chunks with
the materials of the triangles, drops only the shapes of those files
- Fix: ground grids converted out-of-range floats to int, so whole-scene
queries returned the triangles of a single cell (shifted chunks)
- Fix: terrain layers copied from textures already uploaded without their
data stayed grey
- Fix: ImGui ID conflict between terrain tool radios and section headers
- Fix: layers of terrain .txtf files named with the scenery/ prefix and
could not be saved
- Editor selftest commands for the terrain
2026-10-09 23:39:26 +02:00
35bda3778c
Heightmap terrain: .tch chunk packs, streaming with LOD, terrain painting, water and modifiers - terrain/<name>/terrain.yaml + <px>_<pz>.tch packs of 16x16 chunks (250 m, 0.5/1/2/5 m spacing), slices with crc-32 and optional zstd (vendored zstd 1.5.6 in ref/zstd) - heightmap_terrain [name] endheightmap_terrain directive replaces editorterrain - streamer: worker threads, camera + look-ahead loading, geomipmap LOD with skirts, pooled geometry - mat_terrain shader: up to 8 painted layer materials per chunk via texture arrays (opengl33); other renderers fall back to the dominant material - water bodies (outline + level), terrain modifiers (vertical profile shaping kept non-destructive) - F11 Terrain work mode rebuilt: chunks, sculpt, smooth, paint, point spacing, water tools
2026-10-09 21:02:25 +02:00
bbccce0e29
Merge branch 'feat/modern-editor' of https://github.com/MaSzyna-EU07/maszyna into feat/modern-editor
2026-10-09 18:40:51 +02:00
9935257783
Add nosonar tags
2026-10-09 18:40:31 +02:00
maj00r
e910615bf6
removed draw limit in track editor
2026-10-09 15:37:23 +02:00
1c28809dd7
Sonar fixes
2026-10-09 14:42:55 +02:00
5160ffb87d
Windows macro fixes
2026-10-09 13:30:21 +02:00
ff25e71e90
Merge branch 'feat/modern-editor' into feat/mini-generation
2026-10-09 13:13:33 +02:00
3e3317d26f
feat(editor): the toolbar as buttons with icons and names, the chosen tool standing out as the chosen field of work does, the names left out when the row is too narrow for them; the fields of work with icons of their own (surroundings, tracks, roads, terrain) and both rows captioned at their left end (work modes, tools); the tools of the toolbar and of the left edge of the 3d view from one list; Polish translation
2026-10-09 12:49:45 +02:00
1bf687b4c9
feat(editor): the node bank in two panes, as the assets of unity: its groups on the left with the scenery templates, the entries of the chosen one on the right, as cards or a list, a search going through all of them; the models dragged from the node bank onto a model set, the templates of a set or the list of the brush or the area fill; the templates of the model sets shown with their previews; the model sets docked by the node bank by default; Polish translation
2026-10-09 12:01:00 +02:00
645a54a739
feat(editor): icons over the 3d view: the tools of the field of work along its left edge (the edit modes of the surroundings, the track tools, the road tools with the lanes, the terrain tools with the orthophoto), the modes of the gizmo at its top, the axes of the world as the camera sees them in its top right corner, a click on one looking along it, with the top view under them; the icons drawn by editor/icons/editor_icons.py into a png which CMake writes out as an array built into the executable; the gizmo modes and the top view left out of the toolbar; Polish translation
2026-10-09 11:54:47 +02:00
f2e73812d9
feat(editor): View menu with the top view, the lanes of the roads, the structure gauge and a window of the weather and time (time of day, day of the year, visibility, clouds, air temperature, seen in the editor only); the orthophoto settings in a window of their own again; the tracks and roads menus left out, their tools being in the row of the field of work; End drops the models onto the same ground the insert puts them on, the terrain tile models and the terrain patches of the editor included; the loading screen kept in the main window; Polish translation
2026-10-09 11:46:42 +02:00
f94100ffe7
feat(editor): more models selected at once (Shift+LMB), moved and turned by the gizmo together, undone in one step; Ctrl+C / Ctrl+V copy the selected models with their groups and paste them at the cursor; Ctrl+G groups the selection, Ctrl+Shift+G takes a group apart, groups written to the scenery as group ... endgroup and loaded as groups of their own; End drops each model of the selection and of their groups onto the ground; menu of the selection at the cursor on Ctrl+RMB; Edit menu with undo, redo, the clipboard, grouping, deleting; Help > Keyboard shortcuts (F1) with the keys of every field of work, F2-F5 choose the fields of work, the tracks menu lists the track tools with their keys, the keys and descriptions in the menus and tooltips; self-test commands for the selection; Polish translation
2026-10-09 01:12:46 +02:00
791d5d052c
feat(editor): fields of work in a row of their own over the toolbar (surroundings, tracks, roads, terrain), twice as high, with bigger bold text, and the tools of the one chosen in the toolbar under it: the edit modes of the node bank, the track tools in groups with the vehicle and the structure gauge, the road tools with what the place tool puts, the terrain tools (sculpt, smooth, chunks, orthophoto); the tool options window keeps the settings of the tool; the node bank shows a big preview of the entry pointed at for a moment, with its model and skin; the green colours by default again; Polish translation
2026-10-09 00:42:17 +02:00
f184ce7a6a
feat(editor): colours of the editor: amber accents on grey panels as in the design of the layout, the rest of the simulator stays green (colours of the ui chosen by the ui of the mode drawn; Editor Settings > General, kept in eu07_editor.ini), docking preview in the accent colour in both; keys 1-5 choose the edit modes in the order of the toolbar, shown in its tooltips; Mode windows merged into Windows: the windows of the editor, model sets among them, window layout reset and unpinning of the docks; Polish translation
2026-10-09 00:15:14 +02:00
9b0e88db7a
feat(editor): node bank shows the entries as cards with the previews of their models (Previews, size of the cards 48-256 px, kept in eu07_editor.ini), in the groups and with the search as the list; images found by the names the preview generator gives them, worked out by the same code now (editor/editorPreviews: path of the model and skin, numbers of entries with the same ones in the order of nodebank.txt), read and scaled down in a thread of their own, uploaded a few in a frame, at most 512 kept, read anew on Reload node bank; images of the user interface made by the gl renderers (Create_Image/Release_Image of the imgui renderer, srgb in the modern one); Polish translation
2026-10-08 23:55:56 +02:00
4b451622de
feat(editor): pins of the docks: an unpinned dock hides its windows in a strip at the edge of the main window, a tab of the strip shows its window over the 3d view when pointed at for a moment or clicked, and it goes back when the cursor leaves it or on a click elsewhere, but not while it's in use (button held, popup open, typing, drag); pin in the tab bar of each dock, or Unpin in its window menu where the tabs leave no room; pin in the title of the shown window, or docking it by hand, puts the dock back next to the docks at that edge; Ctrl+Space (also in Mode windows) unpins all docks for the most of the view, or pins them back the way they were; unpinned docks kept in imgui.ini, cleared by Reset window layout; Polish translation
2026-10-08 23:27:17 +02:00
maj00r
aa03cb3235
move bended model alongside track
2026-10-08 22:44:41 +02:00
4e69d8f86c
feat(editor): fields of work chosen in the toolbar, one at a time: edit modes, tracks, signals, vehicle, roads, terrain; Toolset split into Tool options (tools of the field of work and the gizmo), Inspector (what it has selected: node with array and bend, path, road) and Node bank (list only); Scene window with the models of the scenery by layer and group, filtered by name or uuid, a click selects, a double click flies the camera to it; track window replaced by a palette of the track tools in groups (build, by the track, checks) with the tools under it, the selected path in the inspector, results of the speed, joints and infrastructure checks in a docked window; road window split into the tools in tool options and the selection in the inspector; terrain tools moved out of the editor settings into tool options together with the orthophoto settings (map menu opens them), leaving the terrain puts sculpting and chunk editing away; default layout: tool options and scene on the left, inspector on the right, node bank and checks at the bottom; Polish translation
2026-10-08 22:41:51 +02:00
maj00r
c3dc7511e1
widen parallel snap and show 4 / 4.5 / 4.75 m
2026-10-08 22:17:48 +02:00
maj00r
5d075e75fe
show compass in ortho view
2026-10-08 22:00:19 +02:00
maj00r
95d4581da2
pan ortho view with middle mouse
2026-10-08 22:00:04 +02:00
maj00r
7618dcda59
hint parallel snap while shifting a straight
2026-10-08 21:59:36 +02:00
maj00r
4d7f5f0f0c
move parallel track to lay and selection
2026-10-08 21:56:28 +02:00
60c7250683
feat(editor): docked layout: windows of the editor docked around the 3d view (dockspace over the main window, default layout built when there's none or on Mode windows > Reset window layout), menu shown all the time, toolbar with the edit modes, track and road windows, gizmo operations and the top view, status bar with the outcome of the last operation and the selected node; dockspace submitted also when the frame was started by the ui of another mode, so docked windows don't come undocked on the change of mode; stable ids of the editor windows, no auto resize of the dockable ones; hints of the track and road tools placed in the part of the window the 3d view is seen in; Polish translation
2026-10-08 21:39:31 +02:00
maj00r
c186b82e5a
lay track - better visual info about curvature
2026-10-08 21:05:16 +02:00
476f3bf1b7
feat(ui): panels can be docked together and dragged out of the simulator window into windows of their own (imgui multi-viewports, ui.viewports yes by default, off where the renderer or the platform can't do it, e.g. wayland); imgui coordinates kept relative to the main window by the glfw backend, so the overlays, picking and gizmo of the editor work unchanged; overlays of the 3d view drawn on the main viewport; keys pressed in the separate windows passed on to the simulator, so the shortcuts of the editor work there too
2026-10-08 21:04:58 +02:00
344034ec70
feat(ui): imgui 1.91.9b-docking in place of 1.73: local changes of the backends carried over (glad as the gl loader, srgb and gamma of the ui, gles glsl string), BufferingBar/Spinner kept, imgui_tables in cmake; cursor position, cursor enter and focus of the main window passed to the glfw backend, which works with events now; code adapted to the api: ImGuiListClipper::Begin, BeginListBox, ImTextureID as an integer, ImageButton with an id, ImGuiKey without GetKeyIndex, logarithmic sliders in place of the removed power argument; ImGuizmo with the math operators defined before imgui.h and SetNextFrameWantCaptureMouse
2026-10-08 20:38:13 +02:00
maj00r
c11480ce2e
fix flipped ortophot + clear cache
2026-10-08 20:20:12 +02:00
maj00r
14e916e81f
prevent collecting all switches from scenery at start of tool
2026-10-08 19:35:28 +02:00
917c8f7285
Merge branch 'master' into feat/modern-editor
2026-10-08 17:44:58 +02:00
28b4e57133
feat(loading): optional background loading: sound files decoded by worker threads (sound.asyncload), data of dds textures read by worker threads (gfx.textures.streaming), gl textures of vehicles farther than a multiple of the draw range released (gfx.textures.releasedistance); all off by default
2026-10-08 16:17:46 +02:00
maj00r
b02fe0ac2b
feat(editor): Signals mode of the Tracks window (H): semaphores, block, warning, shunting, stop, substitute signals and repeaters placed by the track from the templates of the scenery, described by //$e signal: (kind, mount, lamps, lean, the event the train reads them by) which tools/editor/signal_headers.py writes into them; a click by a track puts the signal on that side 2.25 m from the axis at the rail heads, facing the trains which have it on their right, a drag along turns it to the trains going the way of the drag; its (p1)_sem_info goes to event1 or event2 of the path, warning signals and repeaters, which the train doesn't read, get none; a head leaning away from the track swapped for its counterpart; the plate named like the signal; signals dragged along the track with their event, removed with it, renamed in the node properties with it, each a single step of the undo history; Polish translation
2026-10-08 03:12:16 +02:00
maj00r
4a7d839e5d
feat(launcher): new scenery made by the wizard starts at noon with no fog and no clouds
2026-10-08 02:17:06 +02:00
maj00r
01949425ac
feat(editor): track laid on past the diverging end of a switch keeps the cant of its end along with its radius and grade
2026-10-08 01:54:29 +02:00
maj00r
898b4fcaf7
feat(editor): switch drive placed with a switch leans with the grade and the cant of the track at the points, raised as the simulation raises a canted track
2026-10-08 01:53:34 +02:00