C ++的简单动态图显示 [英] Simple Dynamic Graph Display for C++

查看:190
本文介绍了C ++的简单动态图显示的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在寻找一个简单的C ++图形布局库。我想将库嵌入到基于wxWidgets的可视化工具中。总之,我正在寻找类似 graphviz 的东西,但动态除外-即事件发生时,仅需要加载图形更改,而不是完整显示。有 dynagraph ,但这似乎是一个失败的项目。以前曾建议我使用VTK,但它是重量级的。

I am looking for a simple graph layout library for C++. I want to embed the library into our visualizer based on wxWidgets. In summary, I am looking for something like graphviz, except dynamic - that is when an event occurs, only the change in graph needs to be loaded, not the complete display. There is dynagraph, but it seems a dead project. I have previously been suggested to use VTK - but it is a heavyweight.

我正在寻找可用于商业用途的开源,非Copyleft类型的库(GPL是出,LGPL应该可以)。我愿意接受Google不会提出的建议。

I am looking for open source, non-copyleft kind of library available for commercial use (GPL is out, LGPL should be ok). I am open to suggestions that google won't give.

推荐答案

Graphviz生成的布局基于全局结构-任何单个添加项都可以显着改变输出(除非您是使用固定坐标,在这种情况下,您可能不会问这个问题)。基本上,如果要自动放置元素,则需要接受以下一种解决方案:

The layout that Graphviz generates is based on the global structure - any single addition can dramatically change the output (unless you're using fixed coordinates, in which case you probably wouldn't be asking this question). Basically, if you want automatic placement of elements, you need to accept one of these solutions:


  • 放置新元素时,物理学仿真是实时运行的,从而导致节点剧烈反弹,直到它们稳定到新位置为止。这会很慢,但是会显示令人愉悦的更改。

  • 放置新元素时,将重新绘制整个图形(物理/任何东西都被隐藏了,但是整个东西被修改)。由于不必重新绘制,因此速度更快,但是节点的相对位置可以完全不同。

  • 放置新元素时,不会修改现有元素。经过足够的动态更新后,由于自动放置是一个全局优化问题,您的图形将看起来像废话。

对不起,我可以不能帮助您解决问题,但这也许可以帮助您解释为什么您所寻找的东西可能根本不存在(或有任何好处)。

Sorry I can't help with your question, but maybe this helps to explain why what you're looking for may simply not exist (or be any good).

这篇关于C ++的简单动态图显示的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆