Menu

BLT Graph limit?

Help
Michele
2007-09-19
2013-04-30
  • Michele

    Michele - 2007-09-19

    I'm using BLT 2.4 with tcl8.4 to graph various amounts of data. I'm using BLT vectors to graph the data on a graph widget. When I attempt to graph many points simultaneously (vector size > ~200,000) points, the whole script crashes with the error: "X connection to :0.0 broken (explicit kill or server shutdown)
    I'm running the script on linux.
    BTW, the vector size limit varies.

    Any help would be greatly appreciated.
    Michele

     
    • Carl Goode

      Carl Goode - 2007-10-23

      Turn your symbol off for your element.  BLT is asking Xwindows for 200000 little windows and it can not accommodate.  Besides, I can't imagine seeing the symbol would benefit anyone viewing the graph with 200,000 points.  I was able to display this super line with 500000 points (note: it also blew up like yours did with the symbol):

      #!/usw/tcl8.4.6lx/bin/wish

      package require BLT

      pack [set g [blt::graph .graph -height 500 -width 500 -plotbackground white]] -fill both -expand yes

      $g xaxis bind <Button-3> "puts hello_world"

      blt::vector create v1
      blt::vector create v2

      v1 length 500000
      v2 length 500000

      v1 variable v1_array
      v2 variable v2_array

      for { set i 0 } {$i < 500000} {incr i} {
          set v1_array($i) $i
          set v2_array($i) $i
      }

      $g element create line -xdata v1 -ydata v2 -symbol ""

       
      • Michele

        Michele - 2007-10-23

        Actually found that this was a bug in the linux xserver. Thanks for responding.

         

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.