Language
Edit

MathExtensions.CubicToLinearIndex(Vector3Int, Vector3Int) Method

Definition

Convert a 3D texture's cubic index to its linear representation.

public static int CubicToLinearIndex(UnityEngine.Vector3Int cubicIndex, UnityEngine.Vector3Int size);
static member CubicToLinearIndex : UnityEngine.Vector3Int * UnityEngine.Vector3Int -> int
Public Function CubicToLinearIndex (cubicIndex As Vector3Int, size As Vector3Int) As Integer

Parameters

cubicIndex
UnityEngine.Vector3Int

A cubic index into a 3D texture.

size
UnityEngine.Vector3Int

The 3D texture's dimensions or size.

Returns

The linear index for the given cubic index and size.

Applies to