README - code example to use Python syntax highlighting (#92894)
Added explicit code block for Python syntax highlighting. Reviewed-on: https://projects.blender.org/blender/blender-asset-tracer/pulls/92894
This commit is contained in:
parent
08b37a35f8
commit
899f361fcf
@ -75,6 +75,7 @@ Mypy likes to see the return type of `__init__` methods explicitly declared as `
|
||||
BAT can be used as a Python library to inspect the contents of blend files, without having to
|
||||
open Blender itself. Here is an example showing how to determine the render engine used:
|
||||
|
||||
```python
|
||||
#!/usr/bin/env python3.7
|
||||
import json
|
||||
import sys
|
||||
@ -118,6 +119,7 @@ open Blender itself. Here is an example showing how to determine the render engi
|
||||
|
||||
json.dump(render_info, sys.stdout, indent=4, sort_keys=True)
|
||||
print()
|
||||
```
|
||||
|
||||
To understand the naming of the properties, look at Blender's `DNA_xxxx.h` files with struct
|
||||
definitions. It is those names that are accessed via `blender_asset_tracer.blendfile`. The
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user