![]()
gePuppet
Description: Puppet interface.
Source file: \genesis3d\OpenSource\Source\Actor\puppet.h
Functions: Create, Destroy, RenderThroughFrustum, Render, GetMaterialCount, GetMaterial, SetMaterial, SetShadow, GetLightingOptions, SetLightingOptions
Types: gePuppet
Additions for Genesis3D v1.6: GetAlpha, GetEnvironmentOptions, GetStaticLightingOptions, SetAlpha, SetEnvironmentOptions, SetStaticLightingOptions
![]()
Types:
typedef struct gePuppet gePuppet;
NOTE: The contents of this structure have been intentionally left out of the interface, by the designers of this module. Think of this as a handle only.
For the curious, the following is private and not part of the API.
typedef struct gePuppet
{
geVFile* TextureFileContext;
geBodyInst* BodyInstance;
int MaterialCount;
gePuppet_Material* MaterialArray;
int MaxDynamicLightsToUse;
int LightReferenceBoneIndex;
geVec3d FillLightNormal;
gePuppet_Color FillLightColor; // 0..255
geBoolean UseFillLight; // use fill light normal
gePuppet_Color AmbientLightIntensity; // 0..1
geBoolean AmbientLightFromFloor; // use local lighting from floor
geBoolean PerBoneLighting;
geBoolean DoShadow;
geFloat ShadowScale;
const geBitmap* ShadowMap;
int ShadowBoneIndex;
geWorld* World;
} gePuppet;
typedef struct gePuppet_Color
{
geFloat
Red,Green,Blue;
} gePuppet_Color;
Note: This is not part of the API, and is for the curious and those willing to compile the entire source code.
typedef struct gePuppet_Material
{
gePuppet_Color
Color;
geBoolean
UseTexture;
geBitmap* Bitmap;
const char* TextureName;
const char* AlphaName;
} gePuppet_Material;
Note: This is not part of the API, and is for the curious and those willing to compile the entire source code.
![]()
Functions:
![]()
gePuppet* GENESISCC gePuppet_Create(geVFile* TextureFS, const geBody* B, geWorld* World);
![]()
void GENESISCC gePuppet_Destroy(gePuppet** P);
![]()
geBoolean GENESISCC gePuppet_RenderThroughFrustum(const gePuppet* P, const gePose* Joints, const geExtBox* Box, geEngine* Engine, geWorld* World, const geCamera* Camera, Frustum_Info* FInfo);
![]()
geBoolean GENESISCC gePuppet_Render(const gePuppet* P, const gePose* Joints, geEngine* Engine, geWorld* World, const geCamera* Camera, geExtBox* Box);
![]()
geFloat GENESISCC gePuppet_GetAlpha(const gePuppet* P) ;
Added for Genesis3D v1.6
![]()
geEnvironmentOptions GENESISCC gePuppet_GetEnvironmentOptions(const gePuppet* P);
Added for Genesis3D v1.6
//Environment mapping code...
![]()
int GENESISCC gePuppet_GetMaterialCount(gePuppet* P );
![]()
geBoolean GENESISCC gePuppet_GetMaterial(gePuppet* P, int MaterialIndex, geBitmap** Bitmap, geFloat* Red, geFloat* Green, geFloat* Blue);
![]()
void GENESISCC gePuppet_GetStaticLightingOptions(const gePuppet* P, geBoolean * AmbientLightFromStaticLights, geBoolean * TestRayCollision, int* MaxStaticLightsToUse);
Added for Genesis3D v1.6
![]()
void GENESISCC gePuppet_SetAlpha(gePuppet* P, geFloat Alpha ) ;
Added for Genesis3D v1.6
![]()
void GENESISCC gePuppet_SetEnvironmentOptions(gePuppet* P, geEnvironmentOptions* envop );
Added for Genesis3D v1.6
![]()
geBoolean GENESISCC gePuppet_SetMaterial(gePuppet* P, int MaterialIndex, geBitmap* Bitmap, geFloat Red, geFloat Green, geFloat Blue);
![]()
void GENESISCC gePuppet_SetShadow(gePuppet* P, geBoolean DoShadow, geFloat Scale, const geBitmap* ShadowMap, int BoneIndex);
![]()
void GENESISCC gePuppet_SetStaticLightingOptions(gePuppet* P, geBoolean AmbientLightFromStaticLights, geBoolean TestRayCollision, int MaxStaticLightsToUse);
Added for Genesis3D v1.6
![]()
void GENESISCC gePuppet_GetLightingOptions(const gePuppet* P, geBoolean* UseFillLight, geVec3d* FillLightNormal, geFloat* FillLightRed, geFloat* FillLightGreen, geFloat* FillLightBlue, geFloat* AmbientLightRed, geFloat* AmbientLightGreen, geFloat* AmbientLightBlue, geBoolean* UseAmbientLightFromFloor, int * MaximumDynamicLightsToUse, int * LightReferenceBoneIndex, geBoolean* PerBoneLighting);
![]()
void GENESISCC gePuppet_SetLightingOptions(gePuppet* P, geBoolean UseFillLight, const geVec3d* FillLightNormal, geFloat FillLightRed, geFloat FillLightGreen, geFloat FillLightBlue, geFloat AmbientLightRed, geFloat AmbientLightGreen, geFloat AmbientLightBlue, geBoolean AmbientLightFromFloor, int MaximumDynamicLightsToUse, int LightReferenceBoneIndex, int PerBoneLighting);
Note: FillLightRed/GreeN/Blue and AmbientLightRed/Green/Blue values must be 0..255, Set MaximumdynamicLightsToUse to 0 to use no lights.
![]()