Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Qt hangs when re-scaling Y axis
Forum Updated to NodeBB v4.3 + New Features

Qt hangs when re-scaling Y axis

Scheduled Pinned Locked Moved Unsolved General and Desktop
2 Posts 2 Posters 196 Views 2 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • richferraraR Offline
    richferraraR Offline
    richferrara
    wrote on last edited by
    #1

    I am a software engineer developing a test tool that receives real-time data from a radar system and plots it on a chart. This is a Qt Creator port of an existing tool that was originally written for LabWindows/CVI.

    Because the data updates in real time, I need to be able to re-scale both the chart's X-axis (time) and Y-axis (data values) as the tool runs. I am finding that in certain circumstances, changing the maximum value of the Y-axis while the chart is active causes the application to hang. It doesn't give a typical "ended forcefully" or any other error message, it just stalls and shows the wait cursor until I go into Task Manager and end the application manually. I tried stepping through the application with the debugger but it doesn't give me any additional information.

    It doesn't happen every time -- only when the user selects certain data fields to be plotted. And I've never had an issue with re-scaling the X-axis. That works fine.

    I've tried this using both Qt 5 and 6. The same error happens in both versions. I'm running on Windows 10 but I've also seen it happen on Windows 7.

    For now, I have a workaround where I keep the Y-axis min/max at 0-1 and re-scale the data as needed, but I'd like to know what could be causing this problem.

    Pl45m4P 1 Reply Last reply
    0
    • richferraraR richferrara

      I am a software engineer developing a test tool that receives real-time data from a radar system and plots it on a chart. This is a Qt Creator port of an existing tool that was originally written for LabWindows/CVI.

      Because the data updates in real time, I need to be able to re-scale both the chart's X-axis (time) and Y-axis (data values) as the tool runs. I am finding that in certain circumstances, changing the maximum value of the Y-axis while the chart is active causes the application to hang. It doesn't give a typical "ended forcefully" or any other error message, it just stalls and shows the wait cursor until I go into Task Manager and end the application manually. I tried stepping through the application with the debugger but it doesn't give me any additional information.

      It doesn't happen every time -- only when the user selects certain data fields to be plotted. And I've never had an issue with re-scaling the X-axis. That works fine.

      I've tried this using both Qt 5 and 6. The same error happens in both versions. I'm running on Windows 10 but I've also seen it happen on Windows 7.

      For now, I have a workaround where I keep the Y-axis min/max at 0-1 and re-scale the data as needed, but I'd like to know what could be causing this problem.

      Pl45m4P Offline
      Pl45m4P Offline
      Pl45m4
      wrote on last edited by
      #2

      @richferrara said in Qt hangs when re-scaling Y axis:

      It doesn't happen every time -- only when the user selects certain data fields to be plotted.

      But then every time?!
      How do you update the x-axis? Via setRange?
      What else is happening while the axes are getting updated?

      Does the behavior change if you remove the axis and add a new one with updated scale? You could try that just to make sure that it's the axis and not some unwanted stuff happening with the data


      If debugging is the process of removing software bugs, then programming must be the process of putting them in.

      ~E. W. Dijkstra

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved