blob: ba1a8e017506d3d7c9dbac9c6edaf67c3b9a5228 (
plain)
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
|
/**
* f_op_scene.cpp
* Scene Process Framework
*/
#include "f_op/f_op_scene.h"
#include "f_pc/f_pc_manager.h"
#include "f_op/f_op_scene_mng.h"
#include "m_Do/m_Do_hostIO.h"
#if DEBUG
#pragma nosyminline on
#endif
static int fopScn_Draw(scene_class* i_this) {
int ret = fpcNd_DrawMethod((nodedraw_method_class*)i_this->submethod, i_this);
return ret;
}
static int fopScn_Execute(scene_class* i_this) {
int ret = fpcMtd_Execute((process_method_class*)i_this->submethod, i_this);
return ret;
}
static int fopScn_IsDelete(void* i_this) {
int ret = fpcMtd_IsDelete((process_method_class*)((scene_class*) i_this)->submethod, i_this);
return ret;
}
static int fopScn_Delete(void* i_this) {
scene_class* scene = (scene_class*)i_this;
int ret = 0;
ret = fpcMtd_Delete((process_method_class*)scene->submethod, scene);
if (ret == 1) {
fopScnTg_QueueTo(&scene->scene_tag);
}
#if DEBUG
mDoHIO_update();
#endif
return ret;
}
static int fopScn_Create(void* i_this) {
scene_class* scene = (scene_class*)i_this;
int ret;
if (fpcM_IsFirstCreating(i_this)) {
scene_process_profile_definition* profile = (scene_process_profile_definition*)fpcM_GetProfile(i_this);
scene->submethod = profile->submethod;
fopScnTg_Init(&scene->scene_tag, i_this);
fopScnTg_ToQueue(&scene->scene_tag);
u32* append = (u32*)fopScnM_GetAppend(i_this);
if (append != NULL) {
fopScnM_SetParam(i_this, *append);
}
}
ret = fpcMtd_Create((process_method_class*)scene->submethod, scene);
return ret;
}
leafdraw_method_class g_fopScn_Method = {
(process_method_func)fopScn_Create,
(process_method_func)fopScn_Delete,
(process_method_func)fopScn_Execute,
(process_method_func)fopScn_IsDelete,
(process_method_func)fopScn_Draw
};
|