This commit is contained in:
Askill 2019-10-13 16:49:20 +02:00
parent 528590c03b
commit b7c3c308cc
3 changed files with 31 additions and 0 deletions

BIN
Figure_1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 44 KiB

31
main.py Normal file
View File

@ -0,0 +1,31 @@
from mpl_toolkits import mplot3d
import cv2
import numpy as np
import matplotlib.pyplot as plt
import multiprocessing
src="./mkbhd.png"
detail = 60
img = cv2.imread(src)
gray = cv2.cvtColor(img, cv2.COLOR_BGR2GRAY)
fig = plt.figure()
ax = plt.axes(projection="3d")
ax.axis('off')
ax.view_init(50, 90)
ax.set_facecolor('xkcd:dark grey')
for y in range(0, len(img)):
if y%detail == 0:
yArray = [y]*len(img)
xArray = range(0, len(yArray))
zArray = gray[y][0:len(yArray)]
ax.plot3D(xArray,yArray, zArray, c="grey")
print(y)
plt.show()

BIN
mkbhd.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 MiB