All materials in the database have been updated for the new data storage format.
The current version fixes the final transition to the new format. Please update the addon to the current version and no longer use the previous ones.
The base of materials with the previous format is saved in the archive. If you have any difficulties with your materials, it is always possible to restore the material from the previous backup version. To do that please contact the BIS administration.
The format of data storage in the library has been changed. Now the backward compatibility is fully supported, saved materials, and node groups for any previous versions can be loaded with the add-on version 1.9.0. In the future, it is planned to update all materials and node groups in the repository to version 1.9.0. After that, backward compatibility with older versions will be removed from the add-on. Users can update their materials themselves by downloading the material from the repository and updating it by clicking the “update” button. It is not necessary to do this; in the future, all non-updated materials will be updated to version 1.9.0. automatically.
A code refactoring was made, now more attributes are saved for each node. Getting of the attributes is now automatic.
The size of the saved data is reduced due to archiving on the fly, which should reduce the amount of traffic when working with the add-on.
To add an operator to the area header, we can use the “append” and “prepend” functions specifying in its parameters the drawing function of the operator call button.
For example, to add an operator of adding the default cube to the header of the viewport (3D View) area, we need to define the operator drawing function:
The operator button will appear in the header of the viewport window.
Now we can view a list of all the functions that add operators to the area header by the “_draw_funcs” property of the “draw” method.
Python
1
2
bpy.types.VIEW3D_HT_header.draw._draw_funcs
# [<function cube_add_fnc at 0x000000000FC8B8B8>, <function VIEW3D_HT_header.draw at 0x000000000F9C0678>, <function draw_pause at 0x0000000011633A68>]
Note that the “_draw_funcs” property would be defined only if custom operators have been added to the area header. If custom operators were not added to the header, an error will be thrown:
AttributeError: ‘function’ object has no attribute ‘_draw_funcs’