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
8a17495566
commit
95165a0330
@ -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
|
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:
|
open Blender itself. Here is an example showing how to determine the render engine used:
|
||||||
|
|
||||||
|
```python
|
||||||
#!/usr/bin/env python3.7
|
#!/usr/bin/env python3.7
|
||||||
import json
|
import json
|
||||||
import sys
|
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)
|
json.dump(render_info, sys.stdout, indent=4, sort_keys=True)
|
||||||
print()
|
print()
|
||||||
|
```
|
||||||
|
|
||||||
To understand the naming of the properties, look at Blender's `DNA_xxxx.h` files with struct
|
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
|
definitions. It is those names that are accessed via `blender_asset_tracer.blendfile`. The
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user