Get the App
SLTechnology News&Howtos  ›  Internet Technology  › 

How to implement different lines in UGL

Shulou Source: shulou.com Published: 2022-06-01 09:50:15 09月26日 Update

This article mainly introduces how to achieve different lines of UGL, has a certain reference value, interested friends can refer to, I hope you can learn a lot after reading this article, the following let the editor take you to understand it.

Look in different directions first. The last four parameters of uglLine () are used to specify the horizontal and vertical coordinates of the starting point of the line. When you can see some angles, the straight line is jagged. Because WindML is directly pixel coloring. To reduce aliasing (it is impossible to remove it completely), you can improve the resolution, or use anti-aliasing algorithm to do visual deception, but the rendering efficiency will be greatly reduced.

Try different colors again. This is also simple. The straight line has only the foreground color. Use uglForegroundColorSet () to set the foreground color of GC.

Different thickness

UglLineWidthSet () is used to specify the thickness of the line, at least 1. As you can see, after the straight line becomes thicker, the length increases slightly. Because the thick line is equivalent to a rectangle, the two ends become two sides, and this edge also has a thickness.

Different proportion of deficiency and reality

A dotted line, which means that each bit bit uses 1 or 0 to indicate whether or not to draw a solid line.

Different raster effects

Refers to the superposition relationship between the color of the image to be drawn and the background color. There are four types: copy, and, or, and xor.

Thank you for reading this article carefully. I hope the article "how to achieve different lines of UGL" shared by the editor will be helpful to everyone. At the same time, I also hope that you will support us and pay attention to the industry information channel. More related knowledge is waiting for you to learn!

Tags: Different straight lines articles jagged that is scenery thickness color two value pixels raster interest resolution thickness parameters only at the same time images solid lines Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Linux Shulou Information OPPO Reno macOS Shulou Technology