Python Forum

Full Version: Fill a value in triangle shape in Matrix
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hey Guys!

Maybe someone of you know a Package to write in a given 2D numpy array a Triangle with 3 specified points of a matrix and a given value to replace it with.
The Triangle should be completly filled with the given value.
A Sqare with 4 points to select would do the job also.
The shape of the matrix sould not be changed.
Thanks!