These were handled mostly completely outside of IDManagement code, yet
(ab)using the same ID management system in some cases, adding hacks to
address some issues, etc.
Also address a similar issue in the eevee lookdev `LookdevWorld` code.
Since initializing pre-allocated (or static) buffers as valid IDs is not
currently supported, and these use-cases do not seem common enough to be
worth supporting it currently, instead switch to storing allocated IDs
into static pointers.
This allows to use proper 'out-of-main' ID creation code API.
NOTE: There are still some remaining issues, especially in the GP
material BKE api. These are noted in comments for now, as it would be
out of scope to address them in this commit.
Pull Request: https://projects.blender.org/blender/blender/pulls/138263