Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Lesson 38 of AGG some uncommonly used coordinate conversion pipes

2025-03-26 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/03 Report--

5 agg::conv_smooth_poly1_curve

Vertices of smooth transition polygons (Bessel)

Header file: # include "agg/include/agg_conv_smooth_poly1.h"

Basic definition:

Template

Struct conv_smooth_poly1_curve:

Publicconv_curve

The construction parameter is the VertexSource,smooth_value attribute that determines the smoothness (default is 1)

Simple application examples:

Agg::path_storage ps

Ps.move_to (100200)

Ps.line_to (300500)

Ps.line_to (400400)

Ps.close_polygon (true)

Agg::conv_smooth_poly1_curve cspc (ps)

Ras.add_path (cspc)

6 agg::conv_bspline

Vertices of the smooth transition Polyline (Bessel)

Here you need to declare the concept of polylines:

It is commonly referred to as a Polyline, which is just a combination of segments. For example, if a Z-shaped line is drawn with a line segment, then there are three line segments. In fact, a polygon is a kind of polysemous line, a kind of polysemous line.

Header file: # include "agg/include/agg_conv_bspline.h"

Basic definition:

Template

Structconv_bspline: public conv_adaptor_vcgen

Constructor determines the step size for the VertexSource,interpolation_step attribute

Example:

Agg::path_storage ps

Ps.move_to (100200)

Ps.line_to (300500)

Ps.line_to (400400)

/ / ps.close_polygon (true); / / A very strange pattern

Agg::conv_strokestroke (ps)

Agg::conv_bsplinecbsp (stroke)

Ras.add_path (cbsp)

6 agg::conv_marker Establishment Marker

Detailed reference arrow

7 agg::conv_curve

It is based on the recognizable VertexSource that the construction parameter of curve information is VertexSource,conv_smooth_poly1_curve. The vertex in the routine has no curve information, so she will be used in the text output.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report