# Poisson-Disc-Sampling
Matlab script for N-dimensional Poisson-Disc Sampling. This can also be used this to randomly sample k pts from N-dimensional space with minimum separation distance between the points.
###Download
[Download the latest version v1.0](https://github.com/mohakpatel/Poisson-Disc-Sampling/releases)
### Inputs:
* sizeI - [required] Size of volume from which points are to be sampled
* spacing - [required] Minimum sepration distance between points
* nPts - [Default is 0] if nPts = 0 For poisson disc sampling. nPts = k to sample k-pts from N-dimensional space with minimum separation distance
* showIter - [Default is 0] If showIter == 1, this option can be used to see how points are generated through each iteration. It can be useful when code is taking a long time to generate points.
### Output:
* pts - All eligible points
## Example:
* Poisson disc sampling in 2D space.
```matlab
sizeI = [512,512];
spacing = 30;
pts = poissonDisc(sizeI,spacing);
```
* Sample k-pts in 3D space.
```matlab
sizeI = [512,512,192];
spacing = 6;
nPts = 10000;
pts = poissonDisc(sizeI,spacing,nPts);
```
* Show iteration progress from poisson disc sampling in 2D
```matlab
sizeI = [512,512];
spacing = 6;
nPts = 0;
showIter = 1;
pts = poissonDisc(sizeI,spacing,nPts,showIter);
```
没有合适的资源?快使用搜索试试~ 我知道了~
Poisson-Disc-Sampling:用于N维Poisson-Disc采样的Matlab脚本。 这也可以用于从N维空间中随...
共3个文件
md:1个
license:1个
m:1个
需积分: 50 19 下载量 164 浏览量
2021-02-04
16:13:59
上传
评论 1
收藏 4KB ZIP 举报
温馨提示
Poisson-Disc-Sampling:用于N维Poisson-Disc采样的Matlab脚本。 这也可以用于从N维空间中随机采样k个点,且点之间的最小分隔距离
资源详情
资源评论
资源推荐
收起资源包目录
Poisson-Disc-Sampling-master.zip (3个子文件)
Poisson-Disc-Sampling-master
LICENSE 1KB
README.md 1KB
poissonDisc.m 5KB
共 3 条
- 1
kolten
- 粉丝: 45
- 资源: 4558
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功
评论0