Blender Git Loki
Git Commits -> Revision 3f87200
Revision 3f87200 by Sergey Sharybin (cycles-x) July 6, 2021, 10:38 (GMT) |
Cycles X: Make pass definition more robust to changes Previously adding, removing, or even changing order of passes in the kernel_types.h would likely to break display pass enum. This was because the python enum was relying on an exact match of enum item values. Now we do an identifier-based lookup via `Pass::get_type_enum`, which allows to more safely change passes in kernel without risk of breaking display passes. Additionally, conversion of pass to string now also happens via the `Pass::get_type_enum`. All in all, it is the pass type enum which s the source of truth with this change. Differential Revision: https://developer.blender.org/D11823 |
Commit Details:
Full Hash: 3f8720031e66c7c05dfeba426a9edb5fad48109d
Parent Commit: 87a9f08
Lines Changed: +83, -129
6 Modified Paths:
/intern/cycles/blender/addon/properties.py (+24, -23) (Diff)
/intern/cycles/blender/blender_viewport.cpp (+18, -1) (Diff)
/intern/cycles/kernel/kernel_types.h (+1, -0) (Diff)
/intern/cycles/render/pass.cpp (+29, -105) (Diff)
/intern/cycles/util/util_string.cpp (+10, -0) (Diff)
/intern/cycles/util/util_string.h (+1, -0) (Diff)
/intern/cycles/blender/blender_viewport.cpp (+18, -1) (Diff)
/intern/cycles/kernel/kernel_types.h (+1, -0) (Diff)
/intern/cycles/render/pass.cpp (+29, -105) (Diff)
/intern/cycles/util/util_string.cpp (+10, -0) (Diff)
/intern/cycles/util/util_string.h (+1, -0) (Diff)