Get the App
SLTechnology News&Howtos  ›  Servers  › 

How to realize picture clipping of UGUI genie pictures

Shulou Source: shulou.com Published: 2022-06-01 03:37:44 10月01日 Update

UGUI genie picture how to achieve picture cutting, many novices are not very clear about this, in order to help you solve this problem, the following editor will explain in detail for you, people with this need can come to learn, I hope you can gain something.

The genie image in NGUI can cut out the useless parts of the picture, and then the image will be stretched to avoid the problem of the edge of the picture being stretched.

As shown in the picture, before cutting

We can see that as the button image stretches, the white edge of the picture gets bigger and bigger, and we don't want to see it. After the use of cutting treatment. After cutting as shown in the picture

Next, let's take a look at the specific implementation method.

First select the picture in the project panel, then change its type (Texture Type) to sprite (2 D and UI) in the inspector panel.

Then select Sprite Mode (there are three types, namely, Single single (cannot be cropped), Multipe multiple (can be cropped), Polygon polygons (can be cropped, the first two are quadrilateral), and set to Multipe. There is no need to change the parameters inside. As shown in the picture

Click Sprite Editor directly, and then click Apply App.

Enter the wizard editing window as shown in the figure

Click the Slice menu bar and click slice directly.

Then crop the picture by dragging the blue line on the edge of the picture with the mouse

As shown in the picture

Then directly click on the top Apply. In this way, the wizard image in the UI button becomes the shape we finally cut.

If you need to adjust the parameters (directly constrain the image size by numerical values), you can adjust them directly.

Is it helpful for you to read the above content? If you want to know more about the relevant knowledge or read more related articles, please follow the industry information channel, thank you for your support.

Tags: Pictures such as figure wizard cut edge parameter type part panel help adjust clear next no content quadrilateral quadrilateral multiple polygon size Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno vpn OPPO Reno Huawei Redmi Shulou Information