Author Topic: [3.1.0.3] Crash when changing map_image_ options  (Read 723 times)

JudgeDeadd

[3.1.0.3] Crash when changing map_image_ options
« on: June 17, 2015, 10:30:17 am »
If you change any of the map_image_ options (map_image_height, map_image_thickness, map_image_width), SLADE tends to crash. This seems to happen, most of the time, in two situations:

- If you change the option while a map is being displayed (the MAPXX lump is highlighted), the program crashes once you click "OK".
- If you change the option while a map isn't being displayed, and then display a map, then the program will crash once you close the WAD's tab in SLADE.

I've also had different situations - e.g. changing the option made SLADE crash the next time a map was displayed.

Usually, I get this sort of a long error log:

Code: [Select]
Version: 3.1.0.3
Current action: main_preferences
Stack Trace:
0: [unknown location] [unknown:0]
1: (c:\dev\slade3\src\maprenderer2d.cpp:2749) MapRenderer2D::updateVerticesVBO
2: (c:\dev\slade3\src\maprenderer2d.cpp:2952) MapRenderer2D::forceUpdate
3: (c:\dev\slade3\src\mapcanvas.cpp:2288) MapCanvas::forceRefreshRenderer
4: (c:\dev\slade3\src\mapeditorwindow.cpp:933) MapEditorWindow::forceRefresh
5: (c:\dev\slade3\src\dialogs\preferences\colourprefspanel.cpp:205) ColourPrefsPanel::applyPreferences
6: (c:\dev\slade3\src\dialogs\preferences\preferencesdialog.cpp:221) PreferencesDialog::applyPreferences
7: (c:\dev\slade3\src\dialogs\preferences\preferencesdialog.cpp:275) PreferencesDialog::openPreferences
8: (c:\dev\slade3\src\mainwindow.cpp:814) MainWindow::handleAction
9: (c:\dev\slade3\src\mainapp.cpp:1095) MainApp::doAction
10: (c:\dev\slade3\src\mainapp.cpp:1167) MainApp::onMenu
11: (f:\programming\libs\wxwidgets-3.0.2\src\common\appbase.cpp:612) wxAppConsoleBase::HandleEvent
12: (f:\programming\libs\wxwidgets-3.0.2\src\common\appbase.cpp:623) wxAppConsoleBase::CallEventHandler
13: (f:\programming\libs\wxwidgets-3.0.2\src\common\event.cpp:1751) wxEvtHandler::SearchDynamicEventTable
14: (f:\programming\libs\wxwidgets-3.0.2\src\common\event.cpp:1585) wxEvtHandler::TryHereOnly
15: (f:\programming\libs\wxwidgets-3.0.2\src\common\event.cpp:1495) wxEvtHandler::ProcessEvent
16: (f:\programming\libs\wxwidgets-3.0.2\src\common\event.cpp:1416) wxEvtHandler::DoTryApp
17: (f:\programming\libs\wxwidgets-3.0.2\src\common\wincmn.cpp:3433) wxWindowBase::TryAfter
18: (f:\programming\libs\wxwidgets-3.0.2\src\common\event.cpp:1508) wxEvtHandler::ProcessEvent
19: (f:\programming\libs\wxwidgets-3.0.2\src\common\wincmn.cpp:3427) wxWindowBase::TryAfter
20: (f:\programming\libs\wxwidgets-3.0.2\src\common\event.cpp:1508) wxEvtHandler::ProcessEvent
21: (f:\programming\libs\wxwidgets-3.0.2\src\common\event.cpp:1647) wxEvtHandler::SafelyProcessEvent
22: (f:\programming\libs\wxwidgets-3.0.2\src\common\menucmn.cpp:666) wxMenuBase::SendEvent
23: (f:\programming\libs\wxwidgets-3.0.2\src\common\framecmn.cpp:298) wxFrameBase::ProcessCommand
24: (f:\programming\libs\wxwidgets-3.0.2\src\msw\frame.cpp:826) wxFrame::HandleCommand
25: (f:\programming\libs\wxwidgets-3.0.2\src\msw\frame.cpp:889) wxFrame::MSWWindowProc
26: (f:\programming\libs\wxwidgets-3.0.2\src\msw\window.cpp:2711) wxWndProc
27: [unknown location] GetDC
28: [unknown location] GetDC
29: [unknown location] GetWindowLongW
30: [unknown location] DispatchMessageW
31: (f:\programming\libs\wxwidgets-3.0.2\src\msw\evtloop.cpp:170) wxGUIEventLoop::ProcessMessage
32: (f:\programming\libs\wxwidgets-3.0.2\src\msw\evtloop.cpp:232) wxGUIEventLoop::Dispatch
33: (f:\programming\libs\wxwidgets-3.0.2\src\common\evtloopcmn.cpp:206) wxEventLoopManual::DoRun
34: (f:\programming\libs\wxwidgets-3.0.2\src\common\evtloopcmn.cpp:78) wxEventLoopBase::Run
35: (f:\programming\libs\wxwidgets-3.0.2\src\common\appbase.cpp:334) wxAppConsoleBase::MainLoop
36: (f:\programming\libs\wxwidgets-3.0.2\src\common\init.cpp:495) wxEntryReal
37: (f:\programming\libs\wxwidgets-3.0.2\src\msw\main.cpp:188) wxEntry
38: (f:\programming\libs\wxwidgets-3.0.2\src\msw\main.cpp:415) wxEntry
39: (c:\dev\slade3\src\mainapp.cpp:306) WinMain
40: (f:\dd\vctools\crt\crtw32\dllstuff\crtexe.c:618) __tmainCRTStartup
41: [unknown location] RegisterWaitForInputIdle

In one instance, I got a shorter log instead: (this was where I opened SLADE, opened a WAD, clicked on a MAPxx lump, exported a map image, closed the WAD, then tried changing the options - the program crashed immediately after I clicked OK)
Code: [Select]
Version: 3.1.0.3
Current action: main_preferences
Stack Trace:
0: [unknown location] [unknown:0]
1: (c:\dev\slade3\src\maprenderer2d.cpp:2749) MapRenderer2D::updateVerticesVBO
« Last Edit: June 17, 2015, 10:41:04 am by JudgeDeadd »

Gez

Re: [3.1.0.3] Crash when changing map_image_ options
« Reply #1 on: June 22, 2015, 06:38:52 pm »
The location of the crash doesn't make much sense with your description, since it happens in the map editor which is completely different code from the map image render.

camaxide

Re: [3.1.0.3] Crash when changing map_image_ options
« Reply #2 on: May 23, 2016, 07:19:42 pm »
This is an old post, yet only number 5 on the list - so considered 'new' - so I'll wake it up as I have the same problem I think.
I don't use the map editor in Slade - only the archive part.
I open my wad and click the Mapxx to see the map, then save my map with 'Save Map Image' - this has always worked fine as long as 'map_image_height' and 'map_image_width' has been left at default (-5)
However, as soon as I change this value to -1, -2, -3 or even -4 the program can't save any images.

I get an error message with the header: Unhandled exception
And the error message is: 'An unhandeled exception occurred. Press "Abort" to terminate the program, "Retry" to exit the program normally and "Ignore" to try to continue.'
If I click 'Ignore' the program keeps working as normal, but does not save the image. I can then revert the settings to -5, and then the image will save as soon as I click 'Save Map Image' - just like normal.

Just in addition I'd like to say I'd also love to be able to see flats on the image exported - but that is an idea/request best fit for the other forum-part although related.

edit: I forgot: I use Slade 3.1.1.1

edit2: It seem that on very small maps a value of -1 works.. I suspect there is a pixel-size limit of some sorts that causes large maps with low values to crash - which is likely why -5 is set as a default. If true I'd like to be able to export larger pixel-files without a crash - to produce high quality exports also for large maps
« Last Edit: May 23, 2016, 07:27:53 pm by camaxide »