文件名称:jisuanjituxing
- 所属分类:
- 绘图程序
- 资源属性:
- [Windows] [Visual C] [源码]
- 上传时间:
- 2012-11-26
- 文件大小:
- 89kb
- 下载次数:
- 0次
- 提 供 者:
- 周*
- 相关连接:
- 无
- 下载说明:
- 别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容均来自于网络,请自行研究使用
根据多边形区域的填充原理可以推广到圆域的填充,由于圆的特殊属性,即可根据任何欲填充的像素点与圆心的距离是否大于或小于半径来判断是否在圆内或圆外,具体实现程序如下;
利用中点画圆算法实现边界程序:
void CArea_FillData::MidpointCircle(int xc, int yc, int r, int color)
{//画八分之一的圆
int x,y,d
x=0 y=r d=1-r
WholeCircle(xc,yc,x,y,color)
while(x<y)
-According to the regional polygon filling principle can be extended to the domain filled round, a round of special attributes, can be filled under any wishes to the central pixel and the distance is greater than or less than the radius to determine whether the circle or round, realize the procedure is as follows; Midpoint Circle Algorithm border procedures : void CArea_FillData : : MidpointCircle (int xc. yc int, int r, int color) (//painting of the eighth round int x, y, d x = 0 y = r d = 1-r WholeCircle (xc, yc, x, y, color) while (x
利用中点画圆算法实现边界程序:
void CArea_FillData::MidpointCircle(int xc, int yc, int r, int color)
{//画八分之一的圆
int x,y,d
x=0 y=r d=1-r
WholeCircle(xc,yc,x,y,color)
while(x<y)
-According to the regional polygon filling principle can be extended to the domain filled round, a round of special attributes, can be filled under any wishes to the central pixel and the distance is greater than or less than the radius to determine whether the circle or round, realize the procedure is as follows; Midpoint Circle Algorithm border procedures : void CArea_FillData : : MidpointCircle (int xc. yc int, int r, int color) (//painting of the eighth round int x, y, d x = 0 y = r d = 1-r WholeCircle (xc, yc, x, y, color) while (x
(系统自动生成,下载前可以参看下载内容)
下载文件列表
四向种子填充对圆的填充
......................\Area_Fill
......................\.........\Area_Fill.aps
......................\.........\Area_Fill.clw
......................\.........\Area_Fill.cpp
......................\.........\Area_Fill.dsp
......................\.........\Area_Fill.dsw
......................\.........\Area_Fill.h
......................\.........\Area_Fill.ncb
......................\.........\Area_Fill.opt
......................\.........\Area_Fill.plg
......................\.........\Area_Fill.rc
......................\.........\Area_FillData.cpp
......................\.........\Area_FillData.h
......................\.........\Area_FillDoc.cpp
......................\.........\Area_FillDoc.h
......................\.........\Area_FillView.cpp
......................\.........\Area_FillView.h
......................\.........\ChildFrm.cpp
......................\.........\ChildFrm.h
......................\.........\Debug
......................\.........\MainFrm.cpp
......................\.........\MainFrm.h
......................\.........\ReadMe.txt
......................\.........\res
......................\.........\...\Area_Fill.rc2
......................\.........\Resource.h
......................\.........\StdAfx.cpp
......................\.........\StdAfx.h
......................\实验四.doc
......................\Area_Fill
......................\.........\Area_Fill.aps
......................\.........\Area_Fill.clw
......................\.........\Area_Fill.cpp
......................\.........\Area_Fill.dsp
......................\.........\Area_Fill.dsw
......................\.........\Area_Fill.h
......................\.........\Area_Fill.ncb
......................\.........\Area_Fill.opt
......................\.........\Area_Fill.plg
......................\.........\Area_Fill.rc
......................\.........\Area_FillData.cpp
......................\.........\Area_FillData.h
......................\.........\Area_FillDoc.cpp
......................\.........\Area_FillDoc.h
......................\.........\Area_FillView.cpp
......................\.........\Area_FillView.h
......................\.........\ChildFrm.cpp
......................\.........\ChildFrm.h
......................\.........\Debug
......................\.........\MainFrm.cpp
......................\.........\MainFrm.h
......................\.........\ReadMe.txt
......................\.........\res
......................\.........\...\Area_Fill.rc2
......................\.........\Resource.h
......................\.........\StdAfx.cpp
......................\.........\StdAfx.h
......................\实验四.doc