边缘检测是图像分割的另一种重要方法,利用图像灰度级在边缘处的突变,找到目标物体的边缘,图像中边缘处像素的灰度值不连续,这种不连续性可通过求导数来检测到。对于阶跃状边缘,其位置对应一阶导数的极值点,对应二阶导数的过零点(零交叉点)。因此常用微分算子进行边缘检测。常用的一阶微分算子有Roberts算子、 ...
分类:
其他好文 时间:
2016-12-10 19:02:40
阅读次数:
940
本来打算做三角形填充多边形,但需要用到耳切法正在看。所以先研究了这个 要注意如果是XY坐标轴的2D空间,要取差乘分量z而不是y。 实现原理是,将三角形ABC三个边(AB,BC,CA)分别与比较点判断差乘,如果这3个差乘结果表示的方向一致,说明就在三角形内。 效果: 代码(Unity3D): 为了加误 ...
分类:
其他好文 时间:
2016-11-29 07:12:46
阅读次数:
203
Given an index k, return the kth row of the Pascal's triangle. (Easy) For example, given k = 3,Return [1,3,3,1]. Note:Could you optimize your algorith ...
分类:
其他好文 时间:
2016-11-22 22:56:22
阅读次数:
216
Given numRows, generate the first numRows of Pascal's triangle. For example, given numRows = 5, (Easy)Return 分析: 求解杨辉三角形,按照其定义以此求解即可,注意优化写法使其能够更简洁(比如对 ...
分类:
其他好文 时间:
2016-11-22 22:54:19
阅读次数:
192
Given a triangle, find the minimum path sum from top to bottom. Each step you may move to adjacent numbers on the row below.(Medium) For example, give ...
分类:
其他好文 时间:
2016-11-22 22:28:04
阅读次数:
166
Given a triangle, find the minimum path sum from top to bottom. Each step you may move to adjacent numbers on the row below. For example, given the fo ...
分类:
其他好文 时间:
2016-11-22 12:43:50
阅读次数:
207
Given numRows, generate the first numRows of Pascal's triangle. For example, given numRows = 5,Return solution: ...
分类:
其他好文 时间:
2016-11-14 11:59:56
阅读次数:
224
在写网页的过程中,有时我们需要用到一些简单的图片但是手头又没有合适的,我们其实可以自己来写,下面我就简单的介绍几个例子: 1.上三角 Triangle Up #triangle-up { width: 0; height: 0; border-left: 50px solid transparent ...
分类:
Web程序 时间:
2016-11-13 02:07:49
阅读次数:
187
本来打算用四个圆角GL_TRIANGLE_FANS+两个矩形来填充, 后来经无情公子的提醒, 突然发现:"尼玛就是一压扁了的圆啊!" 于是全部用GL_TRIANGLE_FANS, 整个当成一个压扁了的圆形。 线框模式如下: ...
分类:
其他好文 时间:
2016-11-06 02:29:25
阅读次数:
209