orx  stable
Portable Game Engine
orxFX.h
Go to the documentation of this file.
1 /* Orx - Portable Game Engine
2  *
3  * Copyright (c) 2008-2017 Orx-Project
4  *
5  * This software is provided 'as-is', without any express or implied
6  * warranty. In no event will the authors be held liable for any damages
7  * arising from the use of this software.
8  *
9  * Permission is granted to anyone to use this software for any purpose,
10  * including commercial applications, and to alter it and redistribute it
11  * freely, subject to the following restrictions:
12  *
13  * 1. The origin of this software must not be misrepresented; you must not
14  * claim that you wrote the original software. If you use this software
15  * in a product, an acknowledgment in the product documentation would be
16  * appreciated but is not required.
17  *
18  * 2. Altered source versions must be plainly marked as such, and must not be
19  * misrepresented as being the original software.
20  *
21  * 3. This notice may not be removed or altered from any source
22  * distribution.
23  */
24 
43 #ifndef _orxFX_H_
44 #define _orxFX_H_
45 
46 
47 #include "orxInclude.h"
48 #include "math/orxVector.h"
49 #include "object/orxObject.h"
50 
51 
54 #define orxFX_SLOT_KU32_FLAG_ABSOLUTE 0x00000100
55 #define orxFX_SLOT_KU32_FLAG_USE_ROTATION 0x00000200
56 #define orxFX_SLOT_KU32_FLAG_USE_SCALE 0x00000400
61  typedef enum __orxFX_CURVE_t
62  {
69 
71 
72  orxFX_CURVE_NONE = orxENUM_NONE
73 
74  } orxFX_CURVE;
75 
76 
79 typedef struct __orxFX_t orxFX;
80 
81 
84 typedef enum __orxFX_EVENT_t
85 {
93 
94  orxFX_EVENT_NONE = orxENUM_NONE
95 
96 } orxFX_EVENT;
97 
100 typedef struct __orxFX_EVENT_PAYLOAD_t
101 {
103  const orxSTRING zFXName;
106 
107 
110 extern orxDLLAPI void orxFASTCALL orxFX_Setup();
111 
115 extern orxDLLAPI orxSTATUS orxFASTCALL orxFX_Init();
116 
119 extern orxDLLAPI void orxFASTCALL orxFX_Exit();
120 
124 extern orxDLLAPI orxFX *orxFASTCALL orxFX_Create();
125 
130 extern orxDLLAPI orxFX *orxFASTCALL orxFX_CreateFromConfig(const orxSTRING _zConfigID);
131 
136 extern orxDLLAPI orxSTATUS orxFASTCALL orxFX_Delete(orxFX *_pstFX);
137 
141 extern orxDLLAPI orxSTATUS orxFASTCALL orxFX_ClearCache();
142 
150 extern orxDLLAPI orxSTATUS orxFASTCALL orxFX_Apply(const orxFX *_pstFX, orxOBJECT *_pstObject, orxFLOAT _fStartTime, orxFLOAT _fEndTime);
151 
156 extern orxDLLAPI void orxFASTCALL orxFX_Enable(orxFX *_pstFX, orxBOOL _bEnable);
157 
162 extern orxDLLAPI orxBOOL orxFASTCALL orxFX_IsEnabled(const orxFX *_pstFX);
163 
179 extern orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddAlpha(orxFX *_pstFX, orxFLOAT _fStartTime, orxFLOAT _fEndTime, orxFLOAT _fCyclePeriod, orxFLOAT _fCyclePhase, orxFLOAT _fAmplification, orxFLOAT _fAcceleration, orxFLOAT _fStartAlpha, orxFLOAT _fEndAlpha, orxFX_CURVE _eCurve, orxFLOAT _fPow, orxU32 _u32Flags);
180 
196 extern orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddRGB(orxFX *_pstFX, orxFLOAT _fStartTime, orxFLOAT _fEndTime, orxFLOAT _fCyclePeriod, orxFLOAT _fCyclePhase, orxFLOAT _fAmplification, orxFLOAT _fAcceleration, orxVECTOR *_pvStartColor, orxVECTOR *_pvEndColor, orxFX_CURVE _eCurve, orxFLOAT _fPow, orxU32 _u32Flags);
197 
213 extern orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddHSL(orxFX *_pstFX, orxFLOAT _fStartTime, orxFLOAT _fEndTime, orxFLOAT _fCyclePeriod, orxFLOAT _fCyclePhase, orxFLOAT _fAmplification, orxFLOAT _fAcceleration, orxVECTOR *_pvStartColor, orxVECTOR *_pvEndColor, orxFX_CURVE _eCurve, orxFLOAT _fPow, orxU32 _u32Flags);
214 
230 extern orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddHSV(orxFX *_pstFX, orxFLOAT _fStartTime, orxFLOAT _fEndTime, orxFLOAT _fCyclePeriod, orxFLOAT _fCyclePhase, orxFLOAT _fAmplification, orxFLOAT _fAcceleration, orxVECTOR *_pvStartColor, orxVECTOR *_pvEndColor, orxFX_CURVE _eCurve, orxFLOAT _fPow, orxU32 _u32Flags);
231 
247 extern orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddRotation(orxFX *_pstFX, orxFLOAT _fStartTime, orxFLOAT _fEndTime, orxFLOAT _fCyclePeriod, orxFLOAT _fCyclePhase, orxFLOAT _fAmplification, orxFLOAT _fAcceleration, orxFLOAT _fStartRotation, orxFLOAT _fEndRotation, orxFX_CURVE _eCurve, orxFLOAT _fPow, orxU32 _u32Flags);
248 
264 extern orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddScale(orxFX *_pstFX, orxFLOAT _fStartTime, orxFLOAT _fEndTime, orxFLOAT _fCyclePeriod, orxFLOAT _fCyclePhase, orxFLOAT _fAmplification, orxFLOAT _fAcceleration, const orxVECTOR *_pvStartScale, const orxVECTOR *_pvEndScale, orxFX_CURVE _eCurve, orxFLOAT _fPow, orxU32 _u32Flags);
265 
281 extern orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddPosition(orxFX *_pstFX, orxFLOAT _fStartTime, orxFLOAT _fEndTime, orxFLOAT _fCyclePeriod, orxFLOAT _fCyclePhase, orxFLOAT _fAmplification, orxFLOAT _fAcceleration, const orxVECTOR *_pvStartTranslation, const orxVECTOR *_pvEndTranslation, orxFX_CURVE _eCurve, orxFLOAT _fPow, orxU32 _u32Flags);
282 
298 extern orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddSpeed(orxFX *_pstFX, orxFLOAT _fStartTime, orxFLOAT _fEndTime, orxFLOAT _fCyclePeriod, orxFLOAT _fCyclePhase, orxFLOAT _fAmplification, orxFLOAT _fAcceleration, const orxVECTOR *_pvStartSpeed, const orxVECTOR *_pvEndSpeed, orxFX_CURVE _eCurve, orxFLOAT _fPow, orxU32 _u32Flags);
299 
315 extern orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddVolume(orxFX *_pstFX, orxFLOAT _fStartTime, orxFLOAT _fEndTime, orxFLOAT _fCyclePeriod, orxFLOAT _fCyclePhase, orxFLOAT _fAmplification, orxFLOAT _fAcceleration, orxFLOAT _fStartVolume, orxFLOAT _fEndVolume, orxFX_CURVE _eCurve, orxFLOAT _fPow, orxU32 _u32Flags);
316 
332 extern orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddPitch(orxFX *_pstFX, orxFLOAT _fStartTime, orxFLOAT _fEndTime, orxFLOAT _fCyclePeriod, orxFLOAT _fCyclePhase, orxFLOAT _fAmplification, orxFLOAT _fAcceleration, orxFLOAT _fStartPitch, orxFLOAT _fEndPitch, orxFX_CURVE _eCurve, orxFLOAT _fPow, orxU32 _u32Flags);
333 
339 extern orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddSlotFromConfig(orxFX *_pstFX, const orxSTRING _zSlotID);
340 
345 extern orxDLLAPI orxFLOAT orxFASTCALL orxFX_GetDuration(const orxFX *_pstFX);
346 
351 extern orxDLLAPI const orxSTRING orxFASTCALL orxFX_GetName(const orxFX *_pstFX);
352 
358 extern orxDLLAPI orxSTATUS orxFASTCALL orxFX_Loop(orxFX *_pstFX, orxBOOL _bLoop);
359 
364 extern orxDLLAPI orxBOOL orxFASTCALL orxFX_IsLooping(const orxFX *_pstFX);
365 
366 #endif /* _orxFX_H_ */
367 
orxDLLAPI void orxFASTCALL orxFX_Setup()
orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddSlotFromConfig(orxFX *_pstFX, const orxSTRING _zSlotID)
orxFX_EVENT
Definition: orxFX.h:84
const orxSTRING zFXName
Definition: orxFX.h:103
orxDLLAPI orxSTATUS orxFASTCALL orxFX_Loop(orxFX *_pstFX, orxBOOL _bLoop)
struct __orxFX_t orxFX
Definition: orxFX.h:79
orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddPitch(orxFX *_pstFX, orxFLOAT _fStartTime, orxFLOAT _fEndTime, orxFLOAT _fCyclePeriod, orxFLOAT _fCyclePhase, orxFLOAT _fAmplification, orxFLOAT _fAcceleration, orxFLOAT _fStartPitch, orxFLOAT _fEndPitch, orxFX_CURVE _eCurve, orxFLOAT _fPow, orxU32 _u32Flags)
orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddHSL(orxFX *_pstFX, orxFLOAT _fStartTime, orxFLOAT _fEndTime, orxFLOAT _fCyclePeriod, orxFLOAT _fCyclePhase, orxFLOAT _fAmplification, orxFLOAT _fAcceleration, orxVECTOR *_pvStartColor, orxVECTOR *_pvEndColor, orxFX_CURVE _eCurve, orxFLOAT _fPow, orxU32 _u32Flags)
orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddHSV(orxFX *_pstFX, orxFLOAT _fStartTime, orxFLOAT _fEndTime, orxFLOAT _fCyclePeriod, orxFLOAT _fCyclePhase, orxFLOAT _fAmplification, orxFLOAT _fAcceleration, orxVECTOR *_pvStartColor, orxVECTOR *_pvEndColor, orxFX_CURVE _eCurve, orxFLOAT _fPow, orxU32 _u32Flags)
struct __orxOBJECT_t orxOBJECT
Definition: orxObject.h:86
orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddPosition(orxFX *_pstFX, orxFLOAT _fStartTime, orxFLOAT _fEndTime, orxFLOAT _fCyclePeriod, orxFLOAT _fCyclePhase, orxFLOAT _fAmplification, orxFLOAT _fAcceleration, const orxVECTOR *_pvStartTranslation, const orxVECTOR *_pvEndTranslation, orxFX_CURVE _eCurve, orxFLOAT _fPow, orxU32 _u32Flags)
orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddRGB(orxFX *_pstFX, orxFLOAT _fStartTime, orxFLOAT _fEndTime, orxFLOAT _fCyclePeriod, orxFLOAT _fCyclePhase, orxFLOAT _fAmplification, orxFLOAT _fAcceleration, orxVECTOR *_pvStartColor, orxVECTOR *_pvEndColor, orxFX_CURVE _eCurve, orxFLOAT _fPow, orxU32 _u32Flags)
orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddVolume(orxFX *_pstFX, orxFLOAT _fStartTime, orxFLOAT _fEndTime, orxFLOAT _fCyclePeriod, orxFLOAT _fCyclePhase, orxFLOAT _fAmplification, orxFLOAT _fAcceleration, orxFLOAT _fStartVolume, orxFLOAT _fEndVolume, orxFX_CURVE _eCurve, orxFLOAT _fPow, orxU32 _u32Flags)
orxDLLAPI orxSTATUS orxFASTCALL orxFX_ClearCache()
orxDLLAPI orxSTATUS orxFASTCALL orxFX_Delete(orxFX *_pstFX)
orxSTATUS
Definition: orxType.h:243
orxDLLAPI orxBOOL orxFASTCALL orxFX_IsEnabled(const orxFX *_pstFX)
orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddRotation(orxFX *_pstFX, orxFLOAT _fStartTime, orxFLOAT _fEndTime, orxFLOAT _fCyclePeriod, orxFLOAT _fCyclePhase, orxFLOAT _fAmplification, orxFLOAT _fAcceleration, orxFLOAT _fStartRotation, orxFLOAT _fEndRotation, orxFX_CURVE _eCurve, orxFLOAT _fPow, orxU32 _u32Flags)
orxDLLAPI void orxFASTCALL orxFX_Enable(orxFX *_pstFX, orxBOOL _bEnable)
orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddScale(orxFX *_pstFX, orxFLOAT _fStartTime, orxFLOAT _fEndTime, orxFLOAT _fCyclePeriod, orxFLOAT _fCyclePhase, orxFLOAT _fAmplification, orxFLOAT _fAcceleration, const orxVECTOR *_pvStartScale, const orxVECTOR *_pvEndScale, orxFX_CURVE _eCurve, orxFLOAT _fPow, orxU32 _u32Flags)
orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddAlpha(orxFX *_pstFX, orxFLOAT _fStartTime, orxFLOAT _fEndTime, orxFLOAT _fCyclePeriod, orxFLOAT _fCyclePhase, orxFLOAT _fAmplification, orxFLOAT _fAcceleration, orxFLOAT _fStartAlpha, orxFLOAT _fEndAlpha, orxFX_CURVE _eCurve, orxFLOAT _fPow, orxU32 _u32Flags)
orxFX * pstFX
Definition: orxFX.h:102
orxDLLAPI const orxSTRING orxFASTCALL orxFX_GetName(const orxFX *_pstFX)
#define orxDLLAPI
Definition: orxDecl.h:387
orxDLLAPI orxBOOL orxFASTCALL orxFX_IsLooping(const orxFX *_pstFX)
orxDLLAPI orxSTATUS orxFASTCALL orxFX_AddSpeed(orxFX *_pstFX, orxFLOAT _fStartTime, orxFLOAT _fEndTime, orxFLOAT _fCyclePeriod, orxFLOAT _fCyclePhase, orxFLOAT _fAmplification, orxFLOAT _fAcceleration, const orxVECTOR *_pvStartSpeed, const orxVECTOR *_pvEndSpeed, orxFX_CURVE _eCurve, orxFLOAT _fPow, orxU32 _u32Flags)
orxDLLAPI orxFLOAT orxFASTCALL orxFX_GetDuration(const orxFX *_pstFX)
orxDLLAPI orxFX *orxFASTCALL orxFX_Create()
orxDLLAPI orxSTATUS orxFASTCALL orxFX_Init()
orxFX_CURVE
Definition: orxFX.h:61
orxDLLAPI orxSTATUS orxFASTCALL orxFX_Apply(const orxFX *_pstFX, orxOBJECT *_pstObject, orxFLOAT _fStartTime, orxFLOAT _fEndTime)
orxDLLAPI void orxFASTCALL orxFX_Exit()
orxDLLAPI orxFX *orxFASTCALL orxFX_CreateFromConfig(const orxSTRING _zConfigID)

Generated for orx by doxygen 1.5.6