简单C ++图形库 [英] Simple C++ Graphics Library

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

问题描述

对一个简单的C ++库的任何建议我可以使用创建一个指定大小的图像,使用固定的RGB颜色值或者理想的支持渐变。



需要在Windows上工作,理想情况下,但不需要在OS X上工作。



我找到了开罗,但只是想知道是否还有其他的东西,

Cairo 是这个任务的一个特殊的库。如果你认为这是过度的,我可以放心,它绝对不是一个。肿或大型图书馆。开罗是完全为你所需要的。注意,如果你需要在图像上设置文本的能力,你将需要一个排版库,如Pango(它很好地工作)。



这个类别中的大多数其他库都用于游戏(如Allegro),或仅限于位图操作(如libGd和ImageMagick)。 Cairo是为应用程序生成的矢量图像设计的。


Any suggestions for a simple C++ library I can use to create an image to a specified size, with either a fixed rgb colour value or ideally supporting gradients.

Needs to work on Windows and ideally but not required to work on OS X as well.

I've found Cairo, but just wondered if there was anything else as it seems quite simple what I require.

解决方案

Cairo is an exceptional library for this task. If you're thinking it's overkill, I can reassure you that it most definitely is not a bloated or large library. Cairo is meant exactly for what you need it. Note that if you need the ability to set text on the image, you'll need a typesetting library such as Pango (which works well with it).

That said, most of the other libraries in this category are intended for games (like Allegro), or are limited to bitmap manipulations (like libGd and ImageMagick). Cairo was designed for application-generated vector images.

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

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