如何制作在 Facebook 上看起来不错的 ASCII 文本?
我正在制作一个 .NET 应用程序,它将拍摄任何图片并吐出与图像一样的 ASCII 文本。
到目前为止,当字体是 Lucida Console 时效果很好。 Facebook 不使用这种字体,从而打破了艺术幻想。
关于如何解决这个问题有什么想法、想法和建议吗?这是一个非常漂亮的主意! :)
编辑:
Facebook 的默认字体是:
font-family: "lucida grande", "tahoma", "verdana", "arial", sans-serif;
How do you suggest I Solution this unique Problem。 :)
编辑 2: 添加了更多相关标签。
I'm making a .NET application that will take any picture and spit out ASCII text that will appear just like the image.
So far, it works well when the font is Lucida Console. Facebook doesn't use this font and thus break the art illusion.
Any thoughts, ideas and suggestions on how to tackle this problem? It's pretty a pretty neat idea! :)
EDIT:
Facebooks default font is:
font-family: "lucida grande", "tahoma", "verdana", "arial", sans-serif;
How do you suggest I solve this unique problem. :)
EDIT 2:
Added more relevant tags.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
这里有一个有趣的“弯曲”想法:
Unicode 中有一组“数学等宽”字符,它们总是使用等宽字体呈现。在我的计算机上,即使选择的字体是 DejaVu Sans,用于渲染这些字符的字体也会更改为 DejaVu Sans Mono。
范围为:
,尝试在计算机上查看这些
尝试
:作为字母和数字,并且采用等宽字体,您就可以开始了!我使用的是 Ubuntu 10.10,我的字体有这些字符。
以下是上述示例在 Ubuntu 上的屏幕截图:
http://i25.tinypic.com/30ijhjs.png< /a>
Here's an interesting "bended" idea:
There's a set of "Mathematical monospace" characters in Unicode, that always render using a monospace font. On my computer, even though the font chosen is DejaVu Sans, the font used to render these characters changes to DejaVu Sans Mono.
The ranges are:
Try and see if you can see these on your computer:
????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????
If you see these as letters and numbers, and in monospace, you're good to go! I'm on Ubuntu 10.10, and my fonts have these characters.
Here's a screenshot of the above example on Ubuntu:
http://i25.tinypic.com/30ijhjs.png
有一个可以使用可变宽度字体的生成器:
http://sourceforge.net/projects/ascgen2/< /a>
也许你可以看看它的来源以获得一些想法(但当然不能偷窃!)。或者,由于它是一个开源项目,您和作者可以合作并共同开发它?
There's a generator out there that works with variable width fonts:
http://sourceforge.net/projects/ascgen2/
Maybe you could peek at its source for some ideas (but no stealing, of course!). Or, since it's an open source project, you and the author could collaborate and work on it together?