当前时区为 UTC + 8 小时



发表新帖 回复这个主题  [ 5 篇帖子 ] 
作者 内容
1 楼 
 文章标题 : Drop shadows
帖子发表于 : 2006-11-07 1:35 

注册: 2005-10-14 9:38
帖子: 108
送出感谢: 0 次
接收感谢: 0 次
If you are using DapperDrake you should probably look at CompositeManager

如果你使用DapperDrake你可能要参考Composite Manager

What drop shadows are and why you might want them

什么是drop shadows和为什么你会需要它们

Drop shadows are shadows drawn behind windows and menus on the desktop, to give the effect of depth. They are the default on Apple's Mac OS X. They require alpha layer transparency so that you can see through them to what ever is underneath. This requires a lot of computer power, unless your graphics card can accelerate the rendering. Apples graphics system is written in openGL so it is easy for them to implement this. Until recently it has been very hard to make drop shadows in Linux without a large performance hit.

Drop shadows是桌面上的窗口软件和菜单的阴影加深,它提供深度效果.它们在苹果电脑Mac OS X是默认的.它们能使alpha外观透明,这样你就可以总能透视你眼前所见的.它要求一定的机器功率,除非你的显卡能加速透视.苹果的图形系统使用openGL编写所以它能简易的执行它们.直到现在在linux中没有大量的点击操作依然很难达到阴影加强的效果.

Some people feel that drop shadows are unnecessary eyecandy. I think that they are a useful way of subtly making windows distinct from each other. The human eye is good at picking up on depth cues like drop shadows.

许多人觉得阴影加深是不必要的把戏.我认为它们是能巧妙的使窗口软件彼此鲜明不同的有效途径.人眼适宜拮取深度信息比如阴影加深.

A small warning
This may cause an instability on some (non-default install) programs. celestia-gnome and nethack-gnome seem to cause the x server to crash with these adjustments to the xorg.conf. (see bug https://bugzilla.ubuntu.com/show_bug.cgi?id=7406 )

小的警告
它可能引起一些(没有默认安装)程序的不稳定.celestia-gnome和nethack-gnome用这些来调整以适应xorg.conf时可能会引起X服务器崩溃.(参看错误 https://bugzilla.ubuntu.com/show_bug.cgi?id=7406 )


What you need
You will need to be running Xorg, rather than XFree86. Xorg is available in Hoary.

You will need the xcompmgr package (will also install libcomposite)

You will also need to have a good graphics card and a fast computer. I have a 64mb ATI Radeon Mobility 9000 in my 1Ghz G4 powerbook. A few years old, but good enough for this to work.
你需要什么
你需要正在运行Xorg,而不是XFree86.Xorg在Hoary下也有效.
你需要xcompmgr包(也需要安装libcomposite)
你也需要有一个好的显卡和快速的机器.我安装了64mb的 ATI Radeon Mobility 9000在我的1Ghz G4 powerbook上.过时好多年了,但是使drop shadows工作起来还非常的好.

You will need to enable graphics acceleration. Have a look at [[BinaryDriverHowto]] if you are running an x86 processor. I have a powerpc processor so I use the open source ati driver, which are already installed.

你也需要使图形加速,如果你正运行一个x86处理器参考一下[[Binary Driver How to]] .我有一台大功率的电脑处理器,所以我使用已经安装好的开源的ati驱动.

Now you need to edit your X configuration. You can get your system in a real mess if you damage this file. If have not edited configuration files before and don't know how to make a backup then you probably should not be attempting this.
The X configuration file is at /etc/X11/xorg.conf

现在你需要编辑你的X配置.如果破坏了这个文件会使您的系统十分杂乱.
不知道如何备份前,如果还没有编辑配置文件,最好不要轻易尝试.
X配置文件在/etc/X11/xorg.conf

These are the changes I made, it may be different on different card, if you try this please post your experience as a comment.

下面这些是我设定的改变,在不同的卡上它可能会不同,如果你做尝试请张贴自己的经验作为注解.
I changed


Section "Device"
Identifier "ATI Technologies, Inc. Radeon Mobility 9000 M9 (R250 Lf)"
Driver "ati"
BusID "PCI:0:16:0"
Option "UseFBDev" "true"
EndSection

To


Section "Device"
Identifier "ATI Technologies, Inc. Radeon Mobility 9000 M9 (R250 Lf)"
Driver "ati"
BusID "PCI:0:16:0"
Option "UseFBDev" "true"

Option "backingstore" "true"
Option "RenderAccel" "true"
EndSection

and added


Section "Extensions"
Option "Composite" "Enable"
Option "RENDER" "true"
Option "DAMAGE" "true"
EndSection

to the end.

These are lines that I have picked up from the wiki and the forums. They enable some of the new features in Xorg.

上面这些是我从wiki和论坛截取的命令行,它们可以使Xorg中的新特点发挥作用.

You will have to restart X for these to come into effect. The easiest way is to logout and press ctrl+alt+backspace at the login screen. (You can also reboot the whole computer, or logging out and running "sudo /etc/init.d/gdm restart" from a text terminal should do it)

为使这些发挥作用你需要重启X.最简单的方法是退出并且在登录界面按下ctrl+alt+backspace键.(你也可以重新启动整个机器,或者退出并且在一个文本编辑器运行"sudo /etc/init.d/gdm restart"也可以完成它)

How to enable drop shadows
The Gnome desktop does not have drop shadows built in, so you will need to use the xcompmgr utility to turn them on. Have a look at the man page for a full list of its options.

如何使drop shadows起作用
Gnome桌面没有收入drop shadows,所以你需要使用xcompmgr设备打开它们.
参照手册查看drop shadows所有选项的详细目录.

Open up a terminal and run

xcompmgr -c
Use Control + C to stop it.

打开一个终端并且运行
xcompmgr -c
使用Control + C可以停止它

Have a play with a few of the options in the man page. You can make the shadows bigger with

xcompmgr -c -r 30
or hard with

xcompmgr -s
If you get windows going on top of you gnome panels then run


killall gnome-panel
to put the panels back on the top layer.

用一些手册中的选项做些练习.你可以使用xcompmgr -c -r 30使阴影变大或者使用xcompmgr -s使阴影加深.
如果你的窗口软件在gnome面板上面运行,你可以运行kill all gnome-panel使所有的面板回到外观最上层.

Once you have found your perfect settings then you might want to make them run whenever you start Gnome. In the Preferences menu choose Sessions. Go to the Startup Programs tab. Click add and add your chosen xcompmgr command. Set the order to something small; you need it to load before gnome-panel.

一旦你搞定你的完美设置每当你打开Gnome你就会想运行它们.在参数菜单选择会话.打开开始程序下拉菜单,点击添加并且添加你选择的xcompmgr命令.设定命令给小的东西, 你需要在gnome面板加载.

Now log out and back in again.

现在退出然后再次登录.

Additional notes
If you find that this affects openGL performance, try adding the following to your /etc/X11/xorg.conf

附加说明
如果发现它影响openGL执行,尝试加入下面的东西到你的/etc/X11/xorg.conf

Option "AllowGLXWithComposite" "true"
From DanieleMedri Sat Mar 26 12:35:57 +0000 2005 From: Daniele Medri Date: Sat, 26 Mar 2005 12:35:57 +0000 Subject:

Option "AllowGLXWithComposite" Message-ID: <20050326123557+0000@https://www.ubuntulinux.org>
选择"AllowGLXWithComposite"
Message-ID:<20050326123557+0000@https://www.ubuntulinux.org>


I put this option in my device section (eg. Nvidia card) not in "Extensions".

From LucaDeRugeriis Thu May 12 03:28:09 +0100 2005 From: Luca De Rugeriis Date: Thu, 12 May 2005 03:28:09 +0100 Subject: Metacity Message-ID: <20050512032809+0100@https://www.ubuntulinux.org>

我设定了这些选项在我的设备层面(例如Nvidia card)而不是做为"延伸".
From LucaDeRugeriis Thu May 12 03:28:09 +0100 2005 From: Luca De Rugeriis Date: Thu, 12 May 2005 03:28:09 +0100 Subject: Metacity Message-ID: <20050512032809+0100@https://www.ubuntulinux.org>


If you kill gnome-panel, you lose icons in your notification area. Some applications will crash too. Then the panel will show up with drop shadows which is boring. Killing metacity is a much more effective way to restore your desktop margins.

如果你关闭gnome面板,你会在你的通知区域丢失画像.一些程序也会崩溃.
而且面板也伴随无聊的阴影加深出现.关闭metacity是恢复桌面边际相当有效的方法.


最后由 aidinggeer 编辑于 2006-11-07 4:36,总共编辑了 1 次

页首
 用户资料  
 
2 楼 
 文章标题 :
帖子发表于 : 2006-11-07 4:24 

注册: 2005-10-14 9:38
帖子: 108
送出感谢: 0 次
接收感谢: 0 次
水平很烂,有些术语我也看不动.

有的句子我心大体明白什么意思,翻译不出来.
有的干脆不明白,
比如
Set the order to something small; you need it to load before gnome-panel.

呵呵

刚才竟然把Hoary翻译成灰白状态了.

谢谢大家修改了.


页首
 用户资料  
 
3 楼 
 文章标题 :
帖子发表于 : 2006-11-10 17:57 
头像

注册: 2006-01-18 12:55
帖子: 1347
地址: 也许真的没有人理解
送出感谢: 0 次
接收感谢: 1
如果你对Linux不够了解,请尽量不要翻译这种关系系统关键部分或程序的文章,
如果是英文和语文的水平不够高尚可以原谅,但如果是在关键部分出错误,这就不可原谅了,毕竟翻译的文章是要给人看的,如果别人按照你的错误翻译进行操作,恐怕会出现不堪设想的后果……


以下是修改后的例文
(说是修改,其实差不多是完全重新翻译)
If you are using DapperDrake you should probably look at CompositeManager

如果你正在使用Dapper你可以参考Composite Manager。

What drop shadows are and why you might want them

什么是投射阴影?为什么你可能会需要它们?

Drop shadows are shadows drawn behind windows and menus on the desktop, to give the effect of depth. They are the default on Apple's Mac OS X. They require alpha layer transparency so that you can see through them to what ever is underneath. This requires a lot of computer power, unless your graphics card can accelerate the rendering. Apples graphics system is written in openGL so it is easy for them to implement this. Until recently it has been very hard to make drop shadows in Linux without a large performance hit.

投射阴影是指桌面上窗口和菜单的阴影,它能提供视觉深度特效。它们在苹果电脑Mac OS X是被默认开启的。它提供半透明外观,这样你就可以透视看到下面的显示内容。如果你的显卡不能对特效进行加速,那么它就会对计算机系统提出非常高的要求。苹果的图形系统使用OpenGL应用程序接口,所以实现这种特效就变得十分简单。目前在Linux使用阴影效果还是需要消耗大量的系统资源。

Some people feel that drop shadows are unnecessary eyecandy. I think that they are a useful way of subtly making windows distinct from each other. The human eye is good at picking up on depth cues like drop shadows.

有些人认为窗口阴影只是华而不实的视觉特效罢了,但我认为对于区分窗口来说,它还是一个很有用的工具。肉眼很善于从具有视觉深度的效果比如投射阴影中分辨物体。

A small warning
This may cause an instability on some (non-default install) programs. celestia-gnome and nethack-gnome seem to cause the x server to crash with these adjustments to the xorg.conf. (see bug https://bugzilla.ubuntu.com/show_bug.cgi?id=7406 )

一个小小的警告
它可能会使一些(非默认安装)程序变得不稳定。在修改了xorg.conf之后,celestia-gnome和nethack-gnome就可能会引起xserver的崩溃。

What you need
You will need to be running Xorg, rather than XFree86. Xorg is available in Hoary.

You will need the xcompmgr package (will also install libcomposite)

You will also need to have a good graphics card and a fast computer. I have a 64mb ATI Radeon Mobility 9000 in my 1Ghz G4 powerbook. A few years old, but good enough for this to work.

你需要什么?
你需要使用xorg,而不是XFree86。在Hoary下使用xorg也可以。
你需要xcompmgr软件包(会附带安装库libcomposite)。
你还需要一块比较好的显示卡和一台配置比较好的计算机。我有一台装有64MB ATi Radeon 9000显卡的1GHz的G4 Powerbook。使用有几年的时间了,不过还是可以胜任这项工作。

You will need to enable graphics acceleration. Have a look at [[BinaryDriverHowto]] if you are running an x86 processor. I have a powerpc processor so I use the open source ati driver, which are already installed.

你需要启用图形加速。如果你正在使用x86处理器,你可以参考[[BinaryDriverHowto]]。我的是PowerPC处理器,所以我适用源代码的ATi驱动,它已经安装好了。

Now you need to edit your X configuration. You can get your system in a real mess if you damage this file. If have not edited configuration files before and don't know how to make a backup then you probably should not be attempting this.
The X configuration file is at /etc/X11/xorg.conf

现在你需要编辑你的X设置。破坏这个文件会对你的系统造成致命损伤。如果你还不知道怎么修改并且也不知道如何备份它,那么请不要尝试这个操作。X的配置文件是/etc/X11/xorg.conf。

These are the changes I made, it may be different on different card, if you try this please post your experience as a comment.

下面是我所做的修改,不同的显示卡可能会有所不同。如果你尝试这种操作,你可以把自己的经历作为评论来供大家分享。

我改编的内容:


Section "Device"
Identifier "ATI Technologies, Inc. Radeon Mobility 9000 M9 (R250 Lf)"
Driver "ati"
BusID "PCI:0:16:0"
Option "UseFBDev" "true"
EndSection

改为


Section "Device"
Identifier "ATI Technologies, Inc. Radeon Mobility 9000 M9 (R250 Lf)"
Driver "ati"
BusID "PCI:0:16:0"
Option "UseFBDev" "true"

Option "backingstore" "true"
Option "RenderAccel" "true"
EndSection

又添加了


Section "Extensions"
Option "Composite" "Enable"
Option "RENDER" "true"
Option "DAMAGE" "true"
EndSection

完毕

These are lines that I have picked up from the wiki and the forums. They enable some of the new features in Xorg.

这些都是我从wiki和论坛上复制下来的代码。它们可以启用xorg的新功能。

You will have to restart X for these to come into effect. The easiest way is to logout and press ctrl+alt+backspace at the login screen. (You can also reboot the whole computer, or logging out and running "sudo /etc/init.d/gdm restart" from a text terminal should do it)

要是这些修改生效,你需要重新启动X系统。最简单的方法是登出,然后在登陆界面按下Ctrl+Alt+Backspace快捷键。(你当然也可以彻底重新启动,或者登出后在终端使用命令“sudo /etc/init.d/gdm restart”。)

How to enable drop shadows
The Gnome desktop does not have drop shadows built in, so you will need to use the xcompmgr utility to turn them on. Have a look at the man page for a full list of its options.

如何启用投射阴影
Gnome没有内建的阴影效果,所以你需要使用xcompmgr程序来使用该特效。使用man命令可以看到它的所有参数选项。

Open up a terminal and run

xcompmgr -c
Use Control + C to stop it.

打开一个终端,并运行:
xcompmgr -c
使用Ctrl+C就可以退出该程序。

Have a play with a few of the options in the man page. You can make the shadows bigger with

xcompmgr -c -r 30
or hard with

xcompmgr -s
If you get windows going on top of you gnome panels then run


killall gnome-panel
to put the panels back on the top layer.

你可以尝试一些man中提到的选项。你可以通过以下命令将阴影扩大:
xcompmgr -c -r 30
或使用
xcompmgr -s

如果一些窗口跑到了Gnome面板的上面,那就运行以下命令让面板重新置顶:
killall gnome-panel

Once you have found your perfect settings then you might want to make them run whenever you start Gnome. In the Preferences menu choose Sessions. Go to the Startup Programs tab. Click add and add your chosen xcompmgr command. Set the order to something small; you need it to load before gnome-panel.

调试到令你满意的程度,你可能希望每次Gnome启动时它都可以随Gnome一起运行。在系统菜单中选择会话,进入“启动程序”选项卡,单击新建并添加你希望运行的xcompmgr指令。把Order指数设置的小一些,你就可以让它在gnome-panel之前运行。

Now log out and back in again.

现在就可以登出,然后再次登录。

Additional notes
If you find that this affects openGL performance, try adding the following to your /etc/X11/xorg.conf

附加说明
如果你发现它影响了OpenGL API的工作,请尝试在/etc/X11/xorg.conf中加入以下内容。
Option "AllowGLXWithComposite" "true"
From DanieleMedri Sat Mar 26 12:35:57 +0000 2005 From: Daniele Medri Date: Sat, 26 Mar 2005 12:35:57 +0000 Subject:

Option "AllowGLXWithComposite" Message-ID: <20050326123557+0000@https://www.ubuntulinux.org>


I put this option in my device section (eg. Nvidia card) not in "Extensions".

From LucaDeRugeriis Thu May 12 03:28:09 +0100 2005 From: Luca De Rugeriis Date: Thu, 12 May 2005 03:28:09 +0100 Subject: Metacity Message-ID: <20050512032809+0100@https://www.ubuntulinux.org>

我把这些语句放在了Device区(eg. Nvidia card),而不是Extensions区。From LucaDeRugeriis Thu May 12 03:28:09 +0100 2005 From: Luca De Rugeriis Date: Thu, 12 May 2005 03:28:09 +0100 Subject: Metacity Message-ID: <20050512032809+0100@https://www.ubuntulinux.org>


If you kill gnome-panel, you lose icons in your notification area. Some applications will crash too. Then the panel will show up with drop shadows which is boring. Killing metacity is a much more effective way to restore your desktop margins.

如果你关闭gnome-panel,会丢失通知区的图标,一些程序也会随之崩溃,面板中只会留下无聊的阴影。要高效的恢复你的桌面,建议杀掉metacity进程。


_________________
MacBook Pro 15" User
Cocoa Programmer


页首
 用户资料  
 
4 楼 
 文章标题 :
帖子发表于 : 2006-11-12 0:03 

注册: 2005-10-14 9:38
帖子: 108
送出感谢: 0 次
接收感谢: 0 次
谢谢.这样看起来才象是计算机的文章.

呵呵


页首
 用户资料  
 
5 楼 
 文章标题 :
帖子发表于 : 2007-01-20 20:22 

注册: 2007-01-13 18:55
帖子: 151
送出感谢: 0 次
接收感谢: 0 次
那么,要实现这种效果,机子的配置大概要多少?


页首
 用户资料  
 
显示帖子 :  排序  
发表新帖 回复这个主题  [ 5 篇帖子 ] 

当前时区为 UTC + 8 小时


在线用户

正在浏览此版面的用户:没有注册用户 和 2 位游客


不能 在这个版面发表主题
不能 在这个版面回复主题
不能 在这个版面编辑帖子
不能 在这个版面删除帖子
不能 在这个版面提交附件

前往 :  
本站点为公益性站点,用于推广开源自由软件,由 DiaHosting VPSBudgetVM VPS 提供服务。
我们认为:软件应可免费取得,软件工具在各种语言环境下皆可使用,且不会有任何功能上的差异;
人们应有定制和修改软件的自由,且方式不受限制,只要他们自认为合适。

Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
简体中文语系由 王笑宇 翻译