cortex.dataset.Vertex2D.blend_curvature

Vertex2D.blend_curvature(alpha, threshold=0, brightness=0.5, contrast=0.25, smooth=20)

Blend the data with a curvature map depending on a transparency map.

Vertex objects cannot use transparency as Volume objects. This method is a hack to mimic the transparency of Volume objects, blending the Vertex data with a curvature map. This method returns a VertexRGB object, and the colormap parameters (vmin, vmax, cmap, …) of the original Vertex object cannot be changed later on.

Parameters:
alphaarray of shape (n_vertices, )

Transparency map.

thresholdfloat

Threshold for the curvature map.

brightnessfloat

Brightness of the curvature map.

contrastfloat

Contrast of the curvature map.

smoothfloat

Smoothness of the curvature map.

Returns:
blendedVertexRGB object

The original map blended with a curvature map.