expose common extensions for image/movie/audio types, since python scripts had to do this internally.
- bpy.path.extensions_image
- bpy.path.extensions_movie
- bpy.path.extensions_audio
eg:
if os.path.splitext(filename)[1].lower() in bpy.path.extensions_image:
... we have an image ...
This commit is contained in:
@@ -56,6 +56,7 @@ set(SRC
|
||||
bpy_library.c
|
||||
bpy_operator.c
|
||||
bpy_operator_wrap.c
|
||||
bpy_path.c
|
||||
bpy_props.c
|
||||
bpy_rna.c
|
||||
bpy_rna_anim.c
|
||||
@@ -76,6 +77,7 @@ set(SRC
|
||||
bpy_library.h
|
||||
bpy_operator.h
|
||||
bpy_operator_wrap.h
|
||||
bpy_path.h
|
||||
bpy_props.h
|
||||
bpy_rna.h
|
||||
bpy_rna_anim.h
|
||||
|
||||
@@ -44,6 +44,7 @@
|
||||
#include "bpy.h"
|
||||
#include "gpu.h"
|
||||
#include "bpy_rna.h"
|
||||
#include "bpy_path.h"
|
||||
#include "bpy_util.h"
|
||||
#include "bpy_traceback.h"
|
||||
#include "bpy_intern_string.h"
|
||||
@@ -212,6 +213,7 @@ static struct _inittab bpy_internal_modules[] = {
|
||||
{(char *)"mathutils", PyInit_mathutils},
|
||||
// {(char *)"mathutils.geometry", PyInit_mathutils_geometry},
|
||||
// {(char *)"mathutils.noise", PyInit_mathutils_noise},
|
||||
{(char *)"_bpy_path", BPyInit__bpy_path},
|
||||
{(char *)"bgl", BPyInit_bgl},
|
||||
{(char *)"blf", BPyInit_blf},
|
||||
{(char *)"bmesh", BPyInit_bmesh},
|
||||
|
||||
Reference in New Issue
Block a user