Skip to content

Instantly share code, notes, and snippets.

@sambler
sambler / blender_dng.diff
Created July 5, 2016 12:59
blender patch to add DNG/CR2 image support - basic change for proof of concept, could use adding clear support for DNG/CR2 files - oiio returns the image data as file_type=='JPEG'
diff --git a/source/blender/imbuf/intern/oiio/openimageio_api.cpp b/source/blender/imbuf/intern/oiio/openimageio_api.cpp
index 11bf454..a68da9a 100644
--- a/source/blender/imbuf/intern/oiio/openimageio_api.cpp
+++ b/source/blender/imbuf/intern/oiio/openimageio_api.cpp
@@ -176,6 +176,8 @@ int imb_is_a_photoshop(const char *filename)
".psd",
".pdd",
".psb",
+ ".dng",
+ ".cr2",
@sambler
sambler / __init__.py
Created June 28, 2016 13:14
Dynamically create operators that can add custom objects
# for http://blender.stackexchange.com/q/56741/935
bl_info = {
'version': (1, 0),
'blender': (2, 75, 0),
'author': 'sambler',
'name': 'Custom Object Factory',
'location': 'blender',
'description': 'Create multiple custom operators that create objects' ,
# made in response to
# http://blender.stackexchange.com/q/49552/935
bl_info = {
"version": (1, 0),
"blender": (2, 75, 0),
"author": "sambler",
"name": "testing addon",
"location": "blender",
"description": "test showing material nodes in toolshelf" ,
# made in response to
# http://blender.stackexchange.com/q/46496/935
bl_info = {
"version": (1, 0),
"blender": (2, 75, 0),
"author": "sambler",
"name": "Demo Menus",
"description": "Demo showing use of different menus" ,
@sambler
sambler / timed_edit_mode.py
Created February 7, 2016 08:57
Proof of concept, needs more work to be usable. Issue comes from mouse positions in event are from previous modal call but the position during initial execute should be considered.
# made in response to
# http://blender.stackexchange.com/q/46461/935
bl_info = {
"version": (1, 0),
"blender": (2, 75, 0),
"author": "sambler",
"name": "Timed edit mode",
"description": "Use tab to go into edit mode, if tab is held and mouse is moved then show the mode pie menu." ,
# made in response to
# http://blender.stackexchange.com/q/44983/935
bl_info = {
"version": (1, 0),
"blender": (2, 75, 0),
"name": "testing play pause",
"description": """testing addon""" ,
"category": "test",
# made in response to
# http://blender.stackexchange.com/q/44721/935
# render frame ranges for each nla strip with only the one strip active
output_dir = '//renders/'
scene = bpy.context.scene
# make a list of strips used in the NLA
# strips are found in -
# made in response to
# http://blender.stackexchange.com/q/44427/935
bl_info = {
"version": (1, 0),
"blender": (2, 75, 0),
"author": "sambler",
"name": "testing split view",
"description": """testing split view""" ,
@sambler
sambler / MacbookOptions.py
Created January 4, 2016 03:57
blender addon to add some macbook specific options
# from
# http://blender.stackexchange.com/q/44014/935
bl_info = {
"version": (1, 0),
"blender": (2, 75, 0),
"name": "Macbook Options",
"description": """Some user settings to assist macbook users.""" ,
# made in response to
# http://blender.stackexchange.com/q/44022/935
import bpy
from bl_ui.properties_data_modifier import DATA_PT_modifiers
class myModifiersPanel(bpy.types.Panel):
bl_label = "Object Modifiers"
bl_idname = "OBJECT_PT_mymodifiers"