Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00047 #ifndef IRES_
00048 #define IRES_
00049
00052
00053
00054 #ifdef __cplusplus
00055 extern "C" {
00056 #endif
00057
00058 #include "ires_common.h"
00059
00060 typedef enum IRES_YieldResourceType {
00061 IRES_ALL = 0,
00064 IRES_SCRATCHMEMORY,
00067 IRES_SCRATCHDMA,
00070 IRES_RESOURCEHANDLE
00073 } IRES_YieldResourceType;
00074
00075 typedef Void (*IRES_ContextSaveFxn)(IALG_Handle algHandle, Void *contextArgs);
00076 typedef Void (*IRES_ContextRestoreFxn)
00077 (IALG_Handle algHandle, Void *contextArgs);
00078
00084 typedef struct IRES_YieldContext {
00085
00089 IALG_Handle algHandle;
00090
00097 IRES_Handle resourceHandle;
00098
00110 IRES_ContextSaveFxn contextSave;
00111
00125 IRES_ContextRestoreFxn contextRestore;
00126
00134 Void *contextArgs;
00135
00136 } IRES_YieldContext ;
00137
00138
00139 typedef IRES_YieldContext *IRES_YieldContextHandle;
00140 typedef Void *IRES_YieldArgs;
00141
00159 typedef Void (*IRES_YieldFxn)(IRES_YieldResourceType resourceType,
00160 IRES_YieldContextHandle algYieldContext, IRES_YieldArgs yieldArgs);
00161
00168 typedef struct IRES_Fxns {
00169
00174 Void *implementationId;
00175
00180 IRES_Status (*getResourceDescriptors)(IALG_Handle handle,
00181 IRES_ResourceDescriptor *resourceDescriptors);
00182
00190 Int32 (*numResourceDescriptors)(IALG_Handle handle);
00191
00203 IRES_Status (*initResources)(IALG_Handle handle,
00204 IRES_ResourceDescriptor * resourceDescriptor,
00205 IRES_YieldFxn yieldFxn, IRES_YieldArgs yieldArgs);
00206
00217 IRES_Status (*reinitResources)(IALG_Handle handle,
00218 IRES_ResourceDescriptor * resourceDescriptor,
00219 IRES_YieldFxn yieldFxn, IRES_YieldArgs yieldArgs);
00220
00225 IRES_Status (*deinitResources)(IALG_Handle handle,
00226 IRES_ResourceDescriptor * resourceDescriptor);
00227
00237 IRES_Status (*activateResource)(IALG_Handle handle,
00238 IRES_Handle resourceHandle);
00239
00246 IRES_Status (*activateAllResources)(IALG_Handle handle);
00247
00254 IRES_Status (*deactivateResource)(IALG_Handle handle,
00255 IRES_Handle resourceHandle);
00256
00263 IRES_Status (*deactivateAllResources)(IALG_Handle handle);
00264
00265 } IRES_Fxns;
00266
00270 #ifdef __cplusplus
00271 }
00272 #endif
00273
00274
00275 #endif
00276
00277
00278
00279
00280