Skip to content

Instantly share code, notes, and snippets.

View Naxela's full-sized avatar

Alexander Kleemann Naxela

View GitHub Profile
@Naxela
Naxela / gist:e9493314254cb33a536f58e775bc4fc8
Last active August 31, 2022 21:04
Make quick release notes for A3D from github
import bpy, json
from urllib.request import urlopen
def decapitalize(s, upper_rest = False):
return ''.join([s[:1].lower(), (s[1:].upper() if upper_rest else s[1:])])
def cap(s):
return ' '.join(w[:1].upper() + w[1:] for w in s.split(' '))
Changes = []
@Naxela
Naxela / gist:77ffc4e381d7eafeaf7202f514c03e64
Created September 27, 2021 16:21
Remove temporary materials
import bpy
for mat in bpy.data.materials:
if "temp" in mat.name:
print("The material will be removed: " + mat.name)
bpy.data.materials.remove(mat)
@Naxela
Naxela / gist:4a3a5e9172cade23e0e1f663c155490e
Created May 6, 2021 11:53
The Lightmapper - Batch denoising
import bpy, thelightmapper, os
from os import listdir
from os.path import isfile, join
baked_image_array = []
#1. UNCOMMENT THIS IF YOU WANT TO POINT TO IT MANUALLY
#bpy.context.scene.TLM_EngineProperties.tlm_lightmap_savedir = "C:/PATH/TO/DENOISER/BINARY"
dirpath = os.path.join(os.path.dirname(bpy.data.filepath), bpy.context.scene.TLM_EngineProperties.tlm_lightmap_savedir)