Houdini 20.0 hapi

hapi.getHeightFieldData function

Get the height field data for a terrain volume as a flattened

Usage

getHeightFieldData(session: hapi.Session, node_id: int, part_id: int, start: int, length: int) → list of float

Get the height field data for a terrain volume as a flattened 2D array of float heights. Should call hapi.getVolumeInfo first to make sure the volume info is initialized.

session

The session of Houdini you are interacting with. See hapi.Session for more on sessions. Pass None to just use the default in-process session.

node_id

The node id.

part_id

The part id.

start

The start at least 0 and at most ( hapi.VolumeInfo.xLength * hapi.VolumeInfo.yLength )

  • length.

length

The length should be at least 1 or at most ( hapi.VolumeInfo.xLength * hapi.VolumeInfo.yLength )

  • start.

Returns values_array as a list of float.

hapi