DMSwarmDataFieldGetEntries — PETSc 3.25.4 documentation

Skip to main content
`Ctrl`+`K`

# DMSwarmDataFieldGetEntries

Return a pointer to the raw contiguous storage backing a `DMSwarmDataField`.

## Synopsis

    PetscErrorCode DMSwarmDataFieldGetEntries(const DMSwarmDataField gfield, void **data)

Not Collective

## Input Parameter

- gfield - the `DMSwarmDataField`

## Output Parameter

- data - pointer to the raw entries; must be released with `DMSwarmDataFieldRestoreEntries()`

## Note

The array has `L * bs` entries of `atomic_size` bytes, where `L` is the number of particles and `bs` is the block size of the field.

## See Also

`DMSwarmDataField`, `DMSwarmDataFieldRestoreEntries()`, `DMSwarmDataFieldGetNumEntries()`, `DMSwarmDataFieldGetAtomicSize()`

## Level

developer

## Location

src/dm/impls/swarm/data_bucket.c

Index of all DMSwarm routines
Table of Contents for all manual pages
Index of all manual pages