UnityClassRegistration.cpp
17.6 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
extern "C" void RegisterStaticallyLinkedModulesGranular()
{
void RegisterModule_SharedInternals();
RegisterModule_SharedInternals();
void RegisterModule_Core();
RegisterModule_Core();
void RegisterModule_Animation();
RegisterModule_Animation();
void RegisterModule_Audio();
RegisterModule_Audio();
void RegisterModule_ImageConversion();
RegisterModule_ImageConversion();
void RegisterModule_GameCenter();
RegisterModule_GameCenter();
void RegisterModule_IMGUI();
RegisterModule_IMGUI();
void RegisterModule_Input();
RegisterModule_Input();
void RegisterModule_InputLegacy();
RegisterModule_InputLegacy();
void RegisterModule_JSONSerialize();
RegisterModule_JSONSerialize();
void RegisterModule_ParticleSystem();
RegisterModule_ParticleSystem();
void RegisterModule_Physics();
RegisterModule_Physics();
void RegisterModule_Subsystems();
RegisterModule_Subsystems();
void RegisterModule_TextRendering();
RegisterModule_TextRendering();
void RegisterModule_UI();
RegisterModule_UI();
void RegisterModule_XR();
RegisterModule_XR();
}
template <typename T> void RegisterUnityClass(const char*);
template <typename T> void RegisterStrippedType(int, const char*, const char*);
void InvokeRegisterStaticallyLinkedModuleClasses()
{
// Do nothing (we're in stripping mode)
}
namespace ObjectProduceTestTypes { class Derived; }
namespace ObjectProduceTestTypes { class SubDerived; }
class EditorExtension; template <> void RegisterUnityClass<EditorExtension>(const char*);
namespace Unity { class Component; } template <> void RegisterUnityClass<Unity::Component>(const char*);
class Behaviour; template <> void RegisterUnityClass<Behaviour>(const char*);
class Animation; template <> void RegisterUnityClass<Animation>(const char*);
class Animator; template <> void RegisterUnityClass<Animator>(const char*);
class AudioBehaviour; template <> void RegisterUnityClass<AudioBehaviour>(const char*);
class AudioListener; template <> void RegisterUnityClass<AudioListener>(const char*);
class AudioSource; template <> void RegisterUnityClass<AudioSource>(const char*);
class AudioFilter;
class AudioChorusFilter;
class AudioDistortionFilter;
class AudioEchoFilter;
class AudioHighPassFilter;
class AudioLowPassFilter;
class AudioReverbFilter;
class AudioReverbZone; template <> void RegisterUnityClass<AudioReverbZone>(const char*);
class Camera; template <> void RegisterUnityClass<Camera>(const char*);
namespace UI { class Canvas; } template <> void RegisterUnityClass<UI::Canvas>(const char*);
namespace UI { class CanvasGroup; } template <> void RegisterUnityClass<UI::CanvasGroup>(const char*);
namespace Unity { class Cloth; }
class Collider2D;
class BoxCollider2D;
class CapsuleCollider2D;
class CircleCollider2D;
class CompositeCollider2D;
class EdgeCollider2D;
class PolygonCollider2D;
class TilemapCollider2D;
class ConstantForce;
class Effector2D;
class AreaEffector2D;
class BuoyancyEffector2D;
class PlatformEffector2D;
class PointEffector2D;
class SurfaceEffector2D;
class FlareLayer; template <> void RegisterUnityClass<FlareLayer>(const char*);
class GridLayout;
class Grid;
class Tilemap;
class Halo;
class HaloLayer;
class IConstraint;
class AimConstraint;
class LookAtConstraint;
class ParentConstraint;
class PositionConstraint;
class RotationConstraint;
class ScaleConstraint;
class Joint2D;
class AnchoredJoint2D;
class DistanceJoint2D;
class FixedJoint2D;
class FrictionJoint2D;
class HingeJoint2D;
class SliderJoint2D;
class SpringJoint2D;
class WheelJoint2D;
class RelativeJoint2D;
class TargetJoint2D;
class LensFlare;
class Light; template <> void RegisterUnityClass<Light>(const char*);
class LightProbeGroup;
class LightProbeProxyVolume;
class MonoBehaviour; template <> void RegisterUnityClass<MonoBehaviour>(const char*);
class NavMeshAgent;
class NavMeshObstacle;
class OffMeshLink;
class ParticleSystemForceField;
class PhysicsUpdateBehaviour2D;
class ConstantForce2D;
class PlayableDirector;
class Projector;
class ReflectionProbe; template <> void RegisterUnityClass<ReflectionProbe>(const char*);
class Skybox;
class SortingGroup;
class StreamingController;
class Terrain;
class VideoPlayer;
class VisualEffect;
class WindZone;
namespace UI { class CanvasRenderer; } template <> void RegisterUnityClass<UI::CanvasRenderer>(const char*);
class Collider; template <> void RegisterUnityClass<Collider>(const char*);
class BoxCollider; template <> void RegisterUnityClass<BoxCollider>(const char*);
class CapsuleCollider; template <> void RegisterUnityClass<CapsuleCollider>(const char*);
class CharacterController;
class MeshCollider; template <> void RegisterUnityClass<MeshCollider>(const char*);
class SphereCollider; template <> void RegisterUnityClass<SphereCollider>(const char*);
class TerrainCollider;
class WheelCollider;
class FakeComponent;
namespace Unity { class Joint; }
namespace Unity { class CharacterJoint; }
namespace Unity { class ConfigurableJoint; }
namespace Unity { class FixedJoint; }
namespace Unity { class HingeJoint; }
namespace Unity { class SpringJoint; }
class LODGroup;
class MeshFilter; template <> void RegisterUnityClass<MeshFilter>(const char*);
class OcclusionArea;
class OcclusionPortal;
class ParticleSystem; template <> void RegisterUnityClass<ParticleSystem>(const char*);
class Renderer; template <> void RegisterUnityClass<Renderer>(const char*);
class BillboardRenderer;
class LineRenderer; template <> void RegisterUnityClass<LineRenderer>(const char*);
class RendererFake;
class MeshRenderer; template <> void RegisterUnityClass<MeshRenderer>(const char*);
class ParticleSystemRenderer; template <> void RegisterUnityClass<ParticleSystemRenderer>(const char*);
class SkinnedMeshRenderer; template <> void RegisterUnityClass<SkinnedMeshRenderer>(const char*);
class SpriteMask;
class SpriteRenderer; template <> void RegisterUnityClass<SpriteRenderer>(const char*);
class SpriteShapeRenderer;
class TilemapRenderer;
class TrailRenderer; template <> void RegisterUnityClass<TrailRenderer>(const char*);
class VFXRenderer;
class Rigidbody; template <> void RegisterUnityClass<Rigidbody>(const char*);
class Rigidbody2D;
namespace TextRenderingPrivate { class TextMesh; } template <> void RegisterUnityClass<TextRenderingPrivate::TextMesh>(const char*);
class Transform; template <> void RegisterUnityClass<Transform>(const char*);
namespace UI { class RectTransform; } template <> void RegisterUnityClass<UI::RectTransform>(const char*);
class Tree;
class WorldAnchor;
class GameObject; template <> void RegisterUnityClass<GameObject>(const char*);
class NamedObject; template <> void RegisterUnityClass<NamedObject>(const char*);
class AssetBundle;
class AssetBundleManifest;
class AudioMixer;
class AudioMixerController;
class AudioMixerGroup;
class AudioMixerGroupController;
class AudioMixerSnapshot;
class AudioMixerSnapshotController;
class Avatar; template <> void RegisterUnityClass<Avatar>(const char*);
class AvatarMask; template <> void RegisterUnityClass<AvatarMask>(const char*);
class BillboardAsset;
class ComputeShader; template <> void RegisterUnityClass<ComputeShader>(const char*);
class Flare;
namespace TextRendering { class Font; } template <> void RegisterUnityClass<TextRendering::Font>(const char*);
class LightProbes;
class LocalizationAsset;
class Material; template <> void RegisterUnityClass<Material>(const char*);
class ProceduralMaterial;
class Mesh; template <> void RegisterUnityClass<Mesh>(const char*);
class Motion; template <> void RegisterUnityClass<Motion>(const char*);
class AnimationClip; template <> void RegisterUnityClass<AnimationClip>(const char*);
class NavMeshData;
class OcclusionCullingData;
class PhysicMaterial; template <> void RegisterUnityClass<PhysicMaterial>(const char*);
class PhysicsMaterial2D;
class PreloadData; template <> void RegisterUnityClass<PreloadData>(const char*);
class RayTracingShader;
class RuntimeAnimatorController; template <> void RegisterUnityClass<RuntimeAnimatorController>(const char*);
class AnimatorController; template <> void RegisterUnityClass<AnimatorController>(const char*);
class AnimatorOverrideController; template <> void RegisterUnityClass<AnimatorOverrideController>(const char*);
class SampleClip; template <> void RegisterUnityClass<SampleClip>(const char*);
class AudioClip; template <> void RegisterUnityClass<AudioClip>(const char*);
class Shader; template <> void RegisterUnityClass<Shader>(const char*);
class ShaderVariantCollection;
class SpeedTreeWindAsset;
class Sprite; template <> void RegisterUnityClass<Sprite>(const char*);
class SpriteAtlas; template <> void RegisterUnityClass<SpriteAtlas>(const char*);
class SubstanceArchive;
class TerrainData;
class TerrainLayer;
class TextAsset; template <> void RegisterUnityClass<TextAsset>(const char*);
class CGProgram;
class MonoScript; template <> void RegisterUnityClass<MonoScript>(const char*);
class Texture; template <> void RegisterUnityClass<Texture>(const char*);
class BaseVideoTexture;
class WebCamTexture;
class CubemapArray; template <> void RegisterUnityClass<CubemapArray>(const char*);
class LowerResBlitTexture; template <> void RegisterUnityClass<LowerResBlitTexture>(const char*);
class MovieTexture;
class ProceduralTexture;
class RenderTexture; template <> void RegisterUnityClass<RenderTexture>(const char*);
class CustomRenderTexture;
class SparseTexture;
class Texture2D; template <> void RegisterUnityClass<Texture2D>(const char*);
class Cubemap; template <> void RegisterUnityClass<Cubemap>(const char*);
class Texture2DArray; template <> void RegisterUnityClass<Texture2DArray>(const char*);
class Texture3D; template <> void RegisterUnityClass<Texture3D>(const char*);
class VideoClip;
class VisualEffectObject;
class VisualEffectAsset;
class VisualEffectSubgraph;
class EmptyObject;
class GameManager; template <> void RegisterUnityClass<GameManager>(const char*);
class GlobalGameManager; template <> void RegisterUnityClass<GlobalGameManager>(const char*);
class AudioManager; template <> void RegisterUnityClass<AudioManager>(const char*);
class BuildSettings; template <> void RegisterUnityClass<BuildSettings>(const char*);
class DelayedCallManager; template <> void RegisterUnityClass<DelayedCallManager>(const char*);
class GraphicsSettings; template <> void RegisterUnityClass<GraphicsSettings>(const char*);
class InputManager; template <> void RegisterUnityClass<InputManager>(const char*);
class MonoManager; template <> void RegisterUnityClass<MonoManager>(const char*);
class NavMeshProjectSettings;
class Physics2DSettings;
class PhysicsManager; template <> void RegisterUnityClass<PhysicsManager>(const char*);
class PlayerSettings; template <> void RegisterUnityClass<PlayerSettings>(const char*);
class QualitySettings; template <> void RegisterUnityClass<QualitySettings>(const char*);
class ResourceManager; template <> void RegisterUnityClass<ResourceManager>(const char*);
class RuntimeInitializeOnLoadManager; template <> void RegisterUnityClass<RuntimeInitializeOnLoadManager>(const char*);
class ScriptMapper; template <> void RegisterUnityClass<ScriptMapper>(const char*);
class StreamingManager;
class TagManager; template <> void RegisterUnityClass<TagManager>(const char*);
class TimeManager; template <> void RegisterUnityClass<TimeManager>(const char*);
class UnityConnectSettings;
class VFXManager;
class LevelGameManager; template <> void RegisterUnityClass<LevelGameManager>(const char*);
class LightmapSettings; template <> void RegisterUnityClass<LightmapSettings>(const char*);
class NavMeshSettings;
class OcclusionCullingSettings;
class RenderSettings; template <> void RegisterUnityClass<RenderSettings>(const char*);
class NativeObjectType;
class PropertyModificationsTargetTestObject;
class SerializableManagedHost;
class SerializableManagedRefTestClass;
namespace ObjectProduceTestTypes { class SiblingDerived; }
class TestObjectVectorPairStringBool;
class TestObjectWithSerializedAnimationCurve;
class TestObjectWithSerializedArray;
class TestObjectWithSerializedMapStringBool;
class TestObjectWithSerializedMapStringNonAlignedStruct;
class TestObjectWithSpecialLayoutOne;
class TestObjectWithSpecialLayoutTwo;
void RegisterAllClasses()
{
void RegisterBuiltinTypes();
RegisterBuiltinTypes();
//Total: 85 non stripped classes
//0. Animation
RegisterUnityClass<Animation>("Animation");
//1. AnimationClip
RegisterUnityClass<AnimationClip>("Animation");
//2. Animator
RegisterUnityClass<Animator>("Animation");
//3. AnimatorController
RegisterUnityClass<AnimatorController>("Animation");
//4. AnimatorOverrideController
RegisterUnityClass<AnimatorOverrideController>("Animation");
//5. Avatar
RegisterUnityClass<Avatar>("Animation");
//6. AvatarMask
RegisterUnityClass<AvatarMask>("Animation");
//7. Motion
RegisterUnityClass<Motion>("Animation");
//8. RuntimeAnimatorController
RegisterUnityClass<RuntimeAnimatorController>("Animation");
//9. AudioBehaviour
RegisterUnityClass<AudioBehaviour>("Audio");
//10. AudioClip
RegisterUnityClass<AudioClip>("Audio");
//11. AudioListener
RegisterUnityClass<AudioListener>("Audio");
//12. AudioManager
RegisterUnityClass<AudioManager>("Audio");
//13. AudioReverbZone
RegisterUnityClass<AudioReverbZone>("Audio");
//14. AudioSource
RegisterUnityClass<AudioSource>("Audio");
//15. SampleClip
RegisterUnityClass<SampleClip>("Audio");
//16. Behaviour
RegisterUnityClass<Behaviour>("Core");
//17. BuildSettings
RegisterUnityClass<BuildSettings>("Core");
//18. Camera
RegisterUnityClass<Camera>("Core");
//19. Unity::Component
RegisterUnityClass<Unity::Component>("Core");
//20. ComputeShader
RegisterUnityClass<ComputeShader>("Core");
//21. Cubemap
RegisterUnityClass<Cubemap>("Core");
//22. CubemapArray
RegisterUnityClass<CubemapArray>("Core");
//23. DelayedCallManager
RegisterUnityClass<DelayedCallManager>("Core");
//24. EditorExtension
RegisterUnityClass<EditorExtension>("Core");
//25. FlareLayer
RegisterUnityClass<FlareLayer>("Core");
//26. GameManager
RegisterUnityClass<GameManager>("Core");
//27. GameObject
RegisterUnityClass<GameObject>("Core");
//28. GlobalGameManager
RegisterUnityClass<GlobalGameManager>("Core");
//29. GraphicsSettings
RegisterUnityClass<GraphicsSettings>("Core");
//30. InputManager
RegisterUnityClass<InputManager>("Core");
//31. LevelGameManager
RegisterUnityClass<LevelGameManager>("Core");
//32. Light
RegisterUnityClass<Light>("Core");
//33. LightmapSettings
RegisterUnityClass<LightmapSettings>("Core");
//34. LineRenderer
RegisterUnityClass<LineRenderer>("Core");
//35. LowerResBlitTexture
RegisterUnityClass<LowerResBlitTexture>("Core");
//36. Material
RegisterUnityClass<Material>("Core");
//37. Mesh
RegisterUnityClass<Mesh>("Core");
//38. MeshFilter
RegisterUnityClass<MeshFilter>("Core");
//39. MeshRenderer
RegisterUnityClass<MeshRenderer>("Core");
//40. MonoBehaviour
RegisterUnityClass<MonoBehaviour>("Core");
//41. MonoManager
RegisterUnityClass<MonoManager>("Core");
//42. MonoScript
RegisterUnityClass<MonoScript>("Core");
//43. NamedObject
RegisterUnityClass<NamedObject>("Core");
//44. Object
//Skipping Object
//45. PlayerSettings
RegisterUnityClass<PlayerSettings>("Core");
//46. PreloadData
RegisterUnityClass<PreloadData>("Core");
//47. QualitySettings
RegisterUnityClass<QualitySettings>("Core");
//48. UI::RectTransform
RegisterUnityClass<UI::RectTransform>("Core");
//49. ReflectionProbe
RegisterUnityClass<ReflectionProbe>("Core");
//50. Renderer
RegisterUnityClass<Renderer>("Core");
//51. RenderSettings
RegisterUnityClass<RenderSettings>("Core");
//52. RenderTexture
RegisterUnityClass<RenderTexture>("Core");
//53. ResourceManager
RegisterUnityClass<ResourceManager>("Core");
//54. RuntimeInitializeOnLoadManager
RegisterUnityClass<RuntimeInitializeOnLoadManager>("Core");
//55. ScriptMapper
RegisterUnityClass<ScriptMapper>("Core");
//56. Shader
RegisterUnityClass<Shader>("Core");
//57. SkinnedMeshRenderer
RegisterUnityClass<SkinnedMeshRenderer>("Core");
//58. Sprite
RegisterUnityClass<Sprite>("Core");
//59. SpriteAtlas
RegisterUnityClass<SpriteAtlas>("Core");
//60. SpriteRenderer
RegisterUnityClass<SpriteRenderer>("Core");
//61. TagManager
RegisterUnityClass<TagManager>("Core");
//62. TextAsset
RegisterUnityClass<TextAsset>("Core");
//63. Texture
RegisterUnityClass<Texture>("Core");
//64. Texture2D
RegisterUnityClass<Texture2D>("Core");
//65. Texture2DArray
RegisterUnityClass<Texture2DArray>("Core");
//66. Texture3D
RegisterUnityClass<Texture3D>("Core");
//67. TimeManager
RegisterUnityClass<TimeManager>("Core");
//68. TrailRenderer
RegisterUnityClass<TrailRenderer>("Core");
//69. Transform
RegisterUnityClass<Transform>("Core");
//70. ParticleSystem
RegisterUnityClass<ParticleSystem>("ParticleSystem");
//71. ParticleSystemRenderer
RegisterUnityClass<ParticleSystemRenderer>("ParticleSystem");
//72. BoxCollider
RegisterUnityClass<BoxCollider>("Physics");
//73. CapsuleCollider
RegisterUnityClass<CapsuleCollider>("Physics");
//74. Collider
RegisterUnityClass<Collider>("Physics");
//75. MeshCollider
RegisterUnityClass<MeshCollider>("Physics");
//76. PhysicMaterial
RegisterUnityClass<PhysicMaterial>("Physics");
//77. PhysicsManager
RegisterUnityClass<PhysicsManager>("Physics");
//78. Rigidbody
RegisterUnityClass<Rigidbody>("Physics");
//79. SphereCollider
RegisterUnityClass<SphereCollider>("Physics");
//80. TextRendering::Font
RegisterUnityClass<TextRendering::Font>("TextRendering");
//81. TextRenderingPrivate::TextMesh
RegisterUnityClass<TextRenderingPrivate::TextMesh>("TextRendering");
//82. UI::Canvas
RegisterUnityClass<UI::Canvas>("UI");
//83. UI::CanvasGroup
RegisterUnityClass<UI::CanvasGroup>("UI");
//84. UI::CanvasRenderer
RegisterUnityClass<UI::CanvasRenderer>("UI");
}