This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def draw_str(dst, target, s): | |
x, y = target | |
cv.putText(dst, s, (x+1, y+1), cv.FONT_HERSHEY_PLAIN, 1.0, (0, 0, 0), thickness = 2, lineType=cv.LINE_AA) | |
cv.putText(dst, s, (x, y), cv.FONT_HERSHEY_PLAIN, 1.0, (255, 255, 255), lineType=cv.LINE_AA) | |
draw_str(res, (20, 20), "threaded : " + str(threaded_mode)) | |
draw_str(res, (20, 40), "latency : %.1f ms" % (latency.value*1000)) | |
draw_str(res, (20, 60), "frame interval : %.1f ms" % (frame_interval.value*1000)) | |
draw_str(res, (20, 80), "fps : %.1f" % (1/frame_interval.value)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import warnings | |
from argparse import ArgumentParser | |
import threading | |
import concurrent.futures | |
from typing import Match | |
import numpy as np | |
from PIL import Image | |
import shutil | |
import os |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
sudo apt-get install -y devilspie | |
mkdir -p ~/.devilspie | |
echo ' | |
(if (contains (window_class) "Code") | |
(begin | |
(spawn_async (str "xprop -id " (window_xid) " -f _KDE_NET_WM_BLUR_BEHIND_REGION 32c -set _KDE_NET_WM_BLUR_BEHIND_REGION 0 ")) | |
(spawn_async (str "xprop -id " (window_xid) " -f _NET_WM_WINDOW_OPACITY 32c -set _NET_WM_WINDOW_OPACITY 0xD8000000")) |