Skip to content

[ENH]: Add additive blending using plot alpha attribute #23240

@kushaangupta

Description

@kushaangupta

Problem

While using line plots, the alpha attribute is unable to use the transparency for visualizing the density of lines along the line of sight.
Consider the following sample code:

import numpy as np
import matplotlib.pyplot as plt

ax = plt.axes(projection='3d')
x = np.arange(0, np.pi*20, .1)
ax.plot(np.sin(x), np.cos(x), x, c=[.8, .8, .8], linewidth=4, alpha=.5)
plt.show()

Which currently gives this:
image

Whereas on MATLAB, we get this (notice the additive blending of colors in intersections):
image

Proposed solution

Maybe add additive blending in the same group.

Metadata

Metadata

Assignees

No one assigned

    Labels

    New featurekeepItems to be ignored by the “Stale” Github Action

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions