Skip to content

Instantly share code, notes, and snippets.

View TrevCan's full-sized avatar
🖖

Hector Canizales TrevCan

🖖
View GitHub Profile
@TrevCan
TrevCan / ImageTransformer.py
Created November 18, 2025 02:30
Create dearpygui raw image texture (RGBA), show it, and resize it at will.
import numpy as np
import cv2
import typing
from typing import Optional
from typing import Tuple
class ImageTransformer:
@staticmethod
def frame_resize(frame, dimensions: Tuple[int, int]):
"""
#include <stdio.h>
#include <time.h>
#include <stdlib.h>
#include <ctype.h>
#include <string.h>
void mostrarTabla(char[30][30],int[30][12]);
float kgBajados(char[30][30],int [30][12],int[]);
void funcionY(char[30][30], int[30][12],float,int[]);
void funcionZ(char[30][30],int [30][12],int[]);

Keybase proof

I hereby claim:

  • I am trevcan on github.
  • I am trevcan (https://keybase.io/trevcan) on keybase.
  • I have a public key ASBohQT7PL3jqgAp-nFieaftfxaYH4GSc80JL1aSnt5F3go

To claim this, I am signing this object:

#!/bin/python3
# programa del dia siguiente
# debera verificar fechas y mostrar
# la fecha del dia siguiente.
dia=int ( input("Indicar dia:\t") )
while dia < 1 or dia > 31:
print("Fecha Incorrecta.\nError, dia no esta en rango correcto...")
@TrevCan
TrevCan / bash.sh
Created October 5, 2021 00:25
GPG keypair generation with ed25519/cv25519
(
echo "" && \
read -r -s -p 'Passphrase to set for private key: ' PASSPHRASE && \
echo "" && \
read -r -s -p 'Please, repeat the passphrase: ' PASSPHRASE_REPEAT && \
[ "${PASSPHRASE}" != "${PASSPHRASE_REPEAT}" ] && \
echo -e "\nPassphrases don't match! Aborting...\n" || (
echo -e "\n" && \
read -r -p 'Name and e-mail (e.g. "Max Mustermann <[email protected]>"): ' CONTACT && \
echo "" && \
@TrevCan
TrevCan / yt.rss.md
Created September 23, 2021 14:22
getting rss feeds for youtube channels and playlists
/*
* Descripción del problema:
*
* un arquitecto quiere diseñar un programa que realice cotizaciones para impermeabilización de losas,
*
* el programa debe solicitar el largo y ancho de la losa.
*
* Sabiendo que 1 cubeta de 19 litros de impermeabilizante cuesta $920 pesos y rinde 19 m^2
* , el costo de mano de obra por metro cuadrado es de $20 pesos, el sistema deberá
* darnos lo siguiente
@TrevCan
TrevCan / keyboard.yaml
Last active October 9, 2021 06:15
udevmon sample 'catch-all' keyboard conf
# lives under /etc/interception/dual-function-keys/keyboard.yaml
#
TIMING:
TAP_MILLISEC: 200
DOUBLE_TAP_MILLISEC: 150
MAPPINGS:
- KEY: KEY_CAPSLOCK