BlendData(bpy_struct)

base class — bpy_struct

class bpy.types.BlendData(bpy_struct)

Main data structure representing a .blend file and all its data-blocks

actions

Action data-blocks

Type:BlendDataActions bpy_prop_collection of Action, (readonly)
armatures

Armature data-blocks

Type:BlendDataArmatures bpy_prop_collection of Armature, (readonly)
brushes

Brush data-blocks

Type:BlendDataBrushes bpy_prop_collection of Brush, (readonly)
cache_files

Cache Files data-blocks

Type:BlendDataCacheFiles bpy_prop_collection of CacheFile, (readonly)
cameras

Camera data-blocks

Type:BlendDataCameras bpy_prop_collection of Camera, (readonly)
curves

Curve data-blocks

Type:BlendDataCurves bpy_prop_collection of Curve, (readonly)
filepath

Path to the .blend file

Type:string, default “”, (readonly, never None)
fonts

Vector font data-blocks

Type:BlendDataFonts bpy_prop_collection of VectorFont, (readonly)
grease_pencil

Grease Pencil data-blocks

Type:BlendDataGreasePencils bpy_prop_collection of GreasePencil, (readonly)
groups

Group data-blocks

Type:BlendDataGroups bpy_prop_collection of Group, (readonly)
images

Image data-blocks

Type:BlendDataImages bpy_prop_collection of Image, (readonly)
is_dirty

Have recent edits been saved to disk

Type:boolean, default False, (readonly)
is_saved

Has the current session been saved to disk as a .blend file

Type:boolean, default False, (readonly)
lamps

Lamp data-blocks

Type:BlendDataLamps bpy_prop_collection of Lamp, (readonly)
lattices

Lattice data-blocks

Type:BlendDataLattices bpy_prop_collection of Lattice, (readonly)
libraries

Library data-blocks

Type:BlendDataLibraries bpy_prop_collection of Library, (readonly)
linestyles

Line Style data-blocks

Type:BlendDataLineStyles bpy_prop_collection of FreestyleLineStyle, (readonly)
masks

Masks data-blocks

Type:BlendDataMasks bpy_prop_collection of Mask, (readonly)
materials

Material data-blocks

Type:BlendDataMaterials bpy_prop_collection of Material, (readonly)
meshes

Mesh data-blocks

Type:BlendDataMeshes bpy_prop_collection of Mesh, (readonly)
metaballs

Metaball data-blocks

Type:BlendDataMetaBalls bpy_prop_collection of MetaBall, (readonly)
movieclips

Movie Clip data-blocks

Type:BlendDataMovieClips bpy_prop_collection of MovieClip, (readonly)
node_groups

Node group data-blocks

Type:BlendDataNodeTrees bpy_prop_collection of NodeTree, (readonly)
objects

Object data-blocks

Type:BlendDataObjects bpy_prop_collection of Object, (readonly)
paint_curves

Paint Curves data-blocks

Type:BlendDataPaintCurves bpy_prop_collection of PaintCurve, (readonly)
palettes

Palette data-blocks

Type:BlendDataPalettes bpy_prop_collection of Palette, (readonly)
particles

Particle data-blocks

Type:BlendDataParticles bpy_prop_collection of ParticleSettings, (readonly)
scenes

Scene data-blocks

Type:BlendDataScenes bpy_prop_collection of Scene, (readonly)
screens

Screen data-blocks

Type:BlendDataScreens bpy_prop_collection of Screen, (readonly)
shape_keys

Shape Key data-blocks

Type:bpy_prop_collection of Key, (readonly)
sounds

Sound data-blocks

Type:BlendDataSounds bpy_prop_collection of Sound, (readonly)
speakers

Speaker data-blocks

Type:BlendDataSpeakers bpy_prop_collection of Speaker, (readonly)
texts

Text data-blocks

Type:BlendDataTexts bpy_prop_collection of Text, (readonly)
textures

Texture data-blocks

Type:BlendDataTextures bpy_prop_collection of Texture, (readonly)
use_autopack

Automatically pack all external data into .blend file

Type:boolean, default False
version

Version of Blender the .blend was saved with

Type:int array of 3 items in [0, inf], default (0, 0, 0), (readonly)
window_managers

Window manager data-blocks

Type:BlendDataWindowManagers bpy_prop_collection of WindowManager, (readonly)
worlds

World data-blocks

Type:BlendDataWorlds bpy_prop_collection of World, (readonly)
user_map([subset=(id1, id2, ...), ]key_types={..}, value_types={..})

Returns a mapping of all ID datablocks in current bpy.data to a set of all datablocks using them.

For list of valid set members for key_types & value_types, see: bpy.types.KeyingSetPath.id_type.

Parameters:
  • subset (sequence) – When passed, only these data-blocks and their users will be included as keys/values in the map.
  • key_types (set of strings) – Filter the keys mapped by ID types.
  • value_types (set of strings) – Filter the values in the set by ID types.
Returns:

dictionary of bpy.types.ID instances, with sets of ID’s as their values.

Return type:

dict

Inherited Properties

Inherited Functions

References