3D effect display + tutorial implemented by Gnome3

Source: Internet
Author: User
I also had a week using Gnome3. The biggest headache is that Compiz before Ubuntu11.04 cannot be used in G3. You have to find a way to implement it in javascript. Press Alt + F2 and enter lg to open the js console and try to pull it down. Due to my serious js failure, I barely made several 3D effects, as shown in the figure. These images only implement transparent window and window rotation, and there is still a gap between the real compiz 3D desktop. Here I am just following the instructions on the console

Gnome 3 is also used for a week. The biggest headache for me is that Compiz before Ubuntu 11.04 cannot be used in G3. You have to find a way to implement it in javascript.

Press Alt + F2 and enter lg to open the js console and try to pull it down. Due to my serious js failure, I barely made several 3D effects, as shown in the figure.

These images only implement transparent window and window rotation, and there is still a gap between the real compiz 3D desktop. I just randomly typed several lines of code on the console for a test, the rotation_angle_x (and yz attributes) opacity attributes have been changed. extension can be added to 3D Systems. Here, we will only give you some suggestions ~

The following describes how to implement the 3D effect of gnome3 using javascript.

#1. First, press Alt + F2 and then enter lg to open the js console. You can directly debug the js Code and copy the following code directly.

Global. get_window_actors (). forEach (function (w) {w. rotation_angle_z = 0; w. rotation_angle_y = 0; w. rotation_angle_x = 0 })

Tip: assign values to x, y, and z of window rotation respectively to adjust the rotation angle. 0 is the default value.

#2. The following code implements the transparent window effect. 255 is the maximum value, that is, opacity.

Global. get_window_actors (). forEach (function (w) {w. set_opacity (255 )})

If the test is complete, you can use the ESC key to exit the JS console.

Because my js technology is really not very good, I would like to briefly introduce the two, the rest is to be explored together, and these are only for temporary debugging, after the change back to the default value is OK, to retain these effects permanently, you can create extension. In the last tag of the js console, the loaded extensions is displayed.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.