chromium/native_client_sdk/doc_generated/pepper_stable/c/group___typedefs.html

{{+bindTo:partials.standard_nacl_api}}
<h1>Typedefs</h1>
<div id="doxygen-ref">
{{- dummy div to appease doxygen -}}
  <div>
<!-- Generated by Doxygen 1.7.6.1 -->

</div>
<!--header-->
<div class="contents">
<h2>
Typedefs</h2><table class="memberdecls">

<tr><td class="memItemLeft" align="right" valign="top">typedef void *(*&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___typedefs.html#gaa363de651fad7342a37ec58375276af7">PP_ArrayOutput_GetDataBuffer</a> )(void *user_data, uint32_t element_count, uint32_t element_size)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">typedef void(*&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___typedefs.html#ga6fe12e1a41df5e10103a811036d4d8d2">PP_CompletionCallback_Func</a> )(void *user_data, int32_t result)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">typedef int32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___typedefs.html#ga89b662403e6a687bb914b80114c0d19d">PP_Instance</a></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">typedef int32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___typedefs.html#gab780dd451cd7f51284cb752edd88f9a0">PP_Module</a></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">typedef int32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___typedefs.html#gafdc3895ee80f4750d0d95ae1b677e9b7">PP_Resource</a></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">typedef double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___typedefs.html#ga537b277d2116e42b6acfe9323d40e1a0">PP_Time</a></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">typedef double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___typedefs.html#ga71cb1042cdeb38d7881b121f3b09ce94">PP_TimeTicks</a></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">typedef double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___typedefs.html#ga3962a5355895925a757f613567e422fa">PP_TimeDelta</a></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">typedef const void *(*&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___typedefs.html#ga68ad7c927b86e0c29d890603edd33154">PPB_GetInterface</a> )(const char *interface_name)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">typedef void(*&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___typedefs.html#ga2ec91970f3cb75769ce631b3b732803e">PPB_Audio_Callback</a> )(void *sample_buffer, uint32_t buffer_size_in_bytes, <a class="el" href="group___typedefs.html#ga3962a5355895925a757f613567e422fa">PP_TimeDelta</a> latency, void *user_data)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">typedef int32_t(*&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___typedefs.html#gae33224cdac15cf8596127fe7b5f08325">PP_InitializeModule_Func</a> )(<a class="el" href="group___typedefs.html#gab780dd451cd7f51284cb752edd88f9a0">PP_Module</a> module, <a class="el" href="group___typedefs.html#ga68ad7c927b86e0c29d890603edd33154">PPB_GetInterface</a> get_browser_interface)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">typedef void(*&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___typedefs.html#gad2b49167bcbf6c2c895ffb1a61bc720c">PP_ShutdownModule_Func</a> )(void)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">typedef const void *(*&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___typedefs.html#ga893cfdc559fdf7ae3004816357c3d7e9">PP_GetInterface_Func</a> )(const char *interface_name)</td></tr>
</table>
<hr /><h2>Typedef Documentation</h2>
<a class="anchor" id="gaa363de651fad7342a37ec58375276af7"></a><!-- doxytag: member="pp_array_output.h::PP_ArrayOutput_GetDataBuffer" ref="gaa363de651fad7342a37ec58375276af7" args=")(void *user_data, uint32_t element_count, uint32_t element_size)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef void*(* <a class="el" href="group___typedefs.html#gaa363de651fad7342a37ec58375276af7">PP_ArrayOutput_GetDataBuffer</a>)(void *user_data, uint32_t element_count, uint32_t element_size)</td>
</tr>
</table>
</div>
<div class="memdoc">
</div>
</div>
<a class="anchor" id="ga6fe12e1a41df5e10103a811036d4d8d2"></a><!-- doxytag: member="pp_completion_callback.h::PP_CompletionCallback_Func" ref="ga6fe12e1a41df5e10103a811036d4d8d2" args=")(void *user_data, int32_t result)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef void(* <a class="el" href="group___typedefs.html#ga6fe12e1a41df5e10103a811036d4d8d2">PP_CompletionCallback_Func</a>)(void *user_data, int32_t result)</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>This typedef defines the signature that you implement to receive callbacks on asynchronous completion of an operation. </p>
<dl class="params"><dt><b>Parameters:</b></dt><dd>
<table class="params">
<tr><td class="paramdir">[in]</td><td class="paramname">user_data</td><td>A pointer to user data passed to a callback function. </td></tr>
<tr><td class="paramdir">[in]</td><td class="paramname">result</td><td>If result is 0 (PP_OK), the operation succeeded. Negative values (other than -1 or PP_OK_COMPLETE) indicate error and are specified in <a class="el" href="pp__errors_8h.html" title="This file defines an enumeration of all PPAPI error codes.">pp_errors.h</a>. Positive values for result usually indicate success and have some operation-dependent meaning (such as bytes read). </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a class="anchor" id="ga893cfdc559fdf7ae3004816357c3d7e9"></a><!-- doxytag: member="ppp.h::PP_GetInterface_Func" ref="ga893cfdc559fdf7ae3004816357c3d7e9" args=")(const char *interface_name)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef const void*(* <a class="el" href="group___typedefs.html#ga893cfdc559fdf7ae3004816357c3d7e9">PP_GetInterface_Func</a>)(const char *interface_name)</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Defines the type of the <code>PPP_ShutdownModule</code> function. </p>
</div>
</div>
<a class="anchor" id="gae33224cdac15cf8596127fe7b5f08325"></a><!-- doxytag: member="ppp.h::PP_InitializeModule_Func" ref="gae33224cdac15cf8596127fe7b5f08325" args=")(PP_Module module, PPB_GetInterface get_browser_interface)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef int32_t(* <a class="el" href="group___typedefs.html#gae33224cdac15cf8596127fe7b5f08325">PP_InitializeModule_Func</a>)(<a class="el" href="group___typedefs.html#gab780dd451cd7f51284cb752edd88f9a0">PP_Module</a> module, <a class="el" href="group___typedefs.html#ga68ad7c927b86e0c29d890603edd33154">PPB_GetInterface</a> get_browser_interface)</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Defines the type of the <code>PPP_InitializeModule</code> function. </p>
</div>
</div>
<a class="anchor" id="ga89b662403e6a687bb914b80114c0d19d"></a><!-- doxytag: member="pp_instance.h::PP_Instance" ref="ga89b662403e6a687bb914b80114c0d19d" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="group___typedefs.html#ga89b662403e6a687bb914b80114c0d19d">PP_Instance</a></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>The <code>PP_Instance</code> value uniquely identifies one instance of a module (.nexe/PP_Module). </p>
<p>There will be one module instance for every &lt;embed&gt; tag on a page.</p>
<p>This identifier is an opaque handle assigned by the browser to the module. It is guaranteed never to be 0, so a module can initialize it to 0 to indicate a "NULL handle." </p>
</div>
</div>
<a class="anchor" id="gab780dd451cd7f51284cb752edd88f9a0"></a><!-- doxytag: member="pp_module.h::PP_Module" ref="gab780dd451cd7f51284cb752edd88f9a0" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="group___typedefs.html#gab780dd451cd7f51284cb752edd88f9a0">PP_Module</a></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>The PP_Module value uniquely identifies the module or .nexe. </p>
<p>This identifier is an opaque handle assigned by the browser to the module. It is guaranteed never to be 0, so a module can initialize it to 0 to indicate a "NULL handle." </p>
</div>
</div>
<a class="anchor" id="gafdc3895ee80f4750d0d95ae1b677e9b7"></a><!-- doxytag: member="pp_resource.h::PP_Resource" ref="gafdc3895ee80f4750d0d95ae1b677e9b7" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="group___typedefs.html#gafdc3895ee80f4750d0d95ae1b677e9b7">PP_Resource</a></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>This typedef represents an opaque handle assigned by the browser to the resource. </p>
<p>The handle is guaranteed never to be 0 for a valid resource, so a module can initialize it to 0 to indicate a "NULL handle." Some interfaces may return a NULL resource to indicate failure.</p>
<p>While a Var represents something callable to JS or from the module to the DOM, a resource has no meaning or visibility outside of the module interface.</p>
<p>Resources are reference counted. Use <code>AddRefResource()</code> and <code>ReleaseResource()</code> in <code><a class="el" href="ppb__core_8h.html" title="This file defines the PPB_Core interface defined by the browser and containing pointers to functions ...">ppb_core.h</a></code> to manage the reference count of a resource. The data will be automatically destroyed when the internal reference count reaches 0. </p>
</div>
</div>
<a class="anchor" id="gad2b49167bcbf6c2c895ffb1a61bc720c"></a><!-- doxytag: member="ppp.h::PP_ShutdownModule_Func" ref="gad2b49167bcbf6c2c895ffb1a61bc720c" args=")(void)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef void(* <a class="el" href="group___typedefs.html#gad2b49167bcbf6c2c895ffb1a61bc720c">PP_ShutdownModule_Func</a>)(void)</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Defines the type of the <code>PPP_ShutdownModule</code> function. </p>
</div>
</div>
<a class="anchor" id="ga537b277d2116e42b6acfe9323d40e1a0"></a><!-- doxytag: member="pp_time.h::PP_Time" ref="ga537b277d2116e42b6acfe9323d40e1a0" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="group___typedefs.html#ga537b277d2116e42b6acfe9323d40e1a0">PP_Time</a></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>The <code>PP_Time</code> type represents the "wall clock time" according to the browser and is defined as the number of seconds since the Epoch (00:00:00 UTC, January 1, 1970). </p>
</div>
</div>
<a class="anchor" id="ga3962a5355895925a757f613567e422fa"></a><!-- doxytag: member="pp_time.h::PP_TimeDelta" ref="ga3962a5355895925a757f613567e422fa" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="group___typedefs.html#ga3962a5355895925a757f613567e422fa">PP_TimeDelta</a></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>A <code>PP_TimeDelta</code> value represents a duration of time which is measured in seconds. </p>
</div>
</div>
<a class="anchor" id="ga71cb1042cdeb38d7881b121f3b09ce94"></a><!-- doxytag: member="pp_time.h::PP_TimeTicks" ref="ga71cb1042cdeb38d7881b121f3b09ce94" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="group___typedefs.html#ga71cb1042cdeb38d7881b121f3b09ce94">PP_TimeTicks</a></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>A <code>PP_TimeTicks</code> value represents time ticks which are measured in seconds and are used for indicating the time that certain messages were received. </p>
<p>In contrast to <code>PP_Time</code>, <code>PP_TimeTicks</code> does not correspond to any actual wall clock time and will not change discontinuously if the user changes their computer clock.</p>
<p>The units are in seconds, but are not measured relative to any particular epoch, so the most you can do is compare two values. </p>
</div>
</div>
<a class="anchor" id="ga2ec91970f3cb75769ce631b3b732803e"></a><!-- doxytag: member="ppb_audio.h::PPB_Audio_Callback" ref="ga2ec91970f3cb75769ce631b3b732803e" args=")(void *sample_buffer, uint32_t buffer_size_in_bytes, PP_TimeDelta latency, void *user_data)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef void(* <a class="el" href="group___typedefs.html#ga2ec91970f3cb75769ce631b3b732803e">PPB_Audio_Callback</a>)(void *sample_buffer, uint32_t buffer_size_in_bytes, <a class="el" href="group___typedefs.html#ga3962a5355895925a757f613567e422fa">PP_TimeDelta</a> latency, void *user_data)</td>
</tr>
</table>
</div>
<div class="memdoc">
<p><code>PPB_Audio_Callback</code> defines the type of an audio callback function used to fill the audio buffer with data. </p>
<p>Please see the Create() function in the <code>PPB_Audio</code> interface for more details on this callback.</p>
<dl class="params"><dt><b>Parameters:</b></dt><dd>
<table class="params">
<tr><td class="paramdir">[in]</td><td class="paramname">sample_buffer</td><td>A buffer to fill with audio data. </td></tr>
<tr><td class="paramdir">[in]</td><td class="paramname">buffer_size_in_bytes</td><td>The size of the buffer in bytes. </td></tr>
<tr><td class="paramdir">[in]</td><td class="paramname">latency</td><td>How long before the audio data is to be presented. </td></tr>
<tr><td class="paramdir"></td><td class="paramname">inout]</td><td>user_data An opaque pointer that was passed into <code><a class="el" href="struct_p_p_b___audio__1__1.html#a9714ecad5eeefae9d5d98c5ea29ac5ce" title="Create() creates an audio resource.">PPB_Audio.Create()</a></code>. </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a class="anchor" id="ga68ad7c927b86e0c29d890603edd33154"></a><!-- doxytag: member="ppb.h::PPB_GetInterface" ref="ga68ad7c927b86e0c29d890603edd33154" args=")(const char *interface_name)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef const void*(* <a class="el" href="group___typedefs.html#ga68ad7c927b86e0c29d890603edd33154">PPB_GetInterface</a>)(const char *interface_name)</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>This function pointer type defines the signature for the <code>PPB_GetInterface</code> function. </p>
<p>A generic <code>PPB_GetInterface</code> pointer is passed to <code>PPP_InitializedModule</code> when your module is loaded. You can use this pointer to request a pointer to a specific browser interface. Browser interface names are ASCII strings and are generally defined in the header file for the interface, such as <code>PPB_AUDIO_INTERFACE</code> found in <code>ppb.audio.h</code> or <code>PPB_GRAPHICS_2D_INTERFACE</code> in <code><a class="el" href="ppb__graphics__2d_8h.html" title="Defines the PPB_Graphics2D struct representing a 2D graphics context within the browser.">ppb_graphics_2d.h</a></code>. Click <a href="globals_defs.html" title="macros">here</a> for a complete list of interface names.</p>
<p>This value will be NULL if the interface is not supported on the browser. </p>
</div>
</div>
</div><!-- contents -->
</div>
{{/partials.standard_nacl_api}}