# How can I programmatically set individual voxels?

**URL:** https://discourse.vtk.org/t/how-can-i-programmatically-set-individual-voxels/3988
**Category:** Support
**Created:** [August 16, 2020, 4:36pm UTC](https://discourse.vtk.org/t/how-can-i-programmatically-set-individual-voxels/3988 "2020-08-16T16:36:53Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![inhahe](https://discourse.vtk.org/user_avatar/discourse.vtk.org/inhahe/32/2193_2.png) [@inhahe](https://discourse.vtk.org/u/inhahe)
#### Post date: [August 16, 2020, 4:36pm UTC](https://discourse.vtk.org/t/how-can-i-programmatically-set-individual-voxels/3988/1 "2020-08-16T16:36:53Z")

</div>

I want to do some volumetric rendering of a volume I create by setting individual points, not from loading a file and not from using primitives like the cylinder, cone, sphere, etc. How can I do this?

Also, is it bad if there’s millions of voxels and the vast majority of them are the insides of solid shapes? Should I clear them out somehow and store only the surfaces? How should I do that?

Thanks.
