ubuntu cli下screenshot测试

| No Comments | No TrackBacks

这几天需要在没有desktop的cli下做网站截图,google了一圈,

基本都是采用xvfb作为虚拟x-server来显示,

然后利用firefox/chrome或者qt-webkit类软件来实现截图

firefox/chrome类相对来说麻烦一下,但是通过安装flashplugin, 可以显示flash, 但是一般都需要imagemagick来实现边框移除

qt-webkit类的,比较方便,但是好像flash都无法正常显示, 这点在grab大陆站点的时候尤其郁闷

不过最方便的还是

apt-get install xvfb xfonts-wqy; fontconfig-voodoo -f -s zh_CN之后直接用python来截屏。

示例(ubuntu 8.04 LTS server x64上测试):

firefox with flash screenshot/thumb

webkit2png screenshot

参考链接:

一个python版的开源web截图工具:python-webkit2png

python-webkit2png

xvfb制作网页截图

screenshot server

在 Linux 上架設 Screenshot Service

linux下命令实现网络截图

How to run chrome browser windowless using xvfb

xvfb+firefox

linux命令行抓取网页快照-(xvfb+CutyCapt)

No TrackBacks

TrackBack URL: http://blog.suchasplus.com/mt/mt-tb.cgi/303

Leave a comment

About this Entry

This page contains a single entry by suchasplus published on June 9, 2011 2:25 AM.

linux kernel io scheduler memo was the previous entry in this blog.

mysql单表多timestamp的current_timestamp设置问题 is the next entry in this blog.

Find recent content on the main index or look in the archives to find all content.

Pages

OpenID accepted here Learn more about OpenID
Powered by Movable Type 5.2.7