mirror of
https://github.com/openmv/openmv.git
synced 2025-11-04 14:49:50 +08:00
78 lines
85 KiB
HTML
78 lines
85 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
|
|
|
<html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><title>Texture Functions</title><link rel="stylesheet" type="text/css" href="../../styles/main.css"><script language=JavaScript src="../../javascript/main.js"></script><script language=JavaScript src="../../javascript/prettify.js"></script><script language=JavaScript src="../../javascript/searchdata.js"></script></head><body class="ContentPage" onLoad="NDOnLoad();prettyPrint();"><script language=JavaScript><!--
|
|
if (browserType) {document.write("<div class=" + browserType + ">");if (browserVer) {document.write("<div class=" + browserVer + ">"); }}// --></script>
|
|
|
|
<!-- Generated by Natural Docs, version 1.52 -->
|
|
<!-- http://www.naturaldocs.org -->
|
|
|
|
<!-- saved from url=(0026)http://www.naturaldocs.org -->
|
|
|
|
|
|
|
|
|
|
<div id=Content><div class="CSection"><div class=CTopic id=MainTopic><h1 class=CTitle><a name="Texture_Functions"></a>Texture Functions</h1><div class=CBody><p>Modify texture mapping settings</p><p>Texture attributes are part of the context (see: <a href="dave_context-c.html#Context_Functions" class=LSection id=link19 onMouseOver="ShowTip(event, 'tt19', 'link19')" onMouseOut="HideTip('tt19')">Context Functions</a>) but a single context might contain multiple mapping attributes if multiple texture hardware units are present.</p><!--START_ND_SUMMARY--><div class=Summary><div class=STitle>Summary</div><div class=SBorder><table border=0 cellspacing=0 cellpadding=0 class=STable><tr class="SMain"><td class=SEntry><a href="#Texture_Functions" >Texture Functions</a></td><td class=SDescription>Modify texture mapping settings</td></tr><tr class="SGroup SIndent1"><td class=SEntry><a href="#Texture_Attribute_Writes" >Texture Attribute Writes</a></td><td class=SDescription></td></tr><tr class="SFunction SIndent2 SMarked"><td class=SEntry><a href="#d2_settexture" id=link1 onMouseOver="ShowTip(event, 'tt1', 'link1')" onMouseOut="HideTip('tt1')">d2_settexture</a></td><td class=SDescription>Specify the source for texture mapping.</td></tr><tr class="SFunction SIndent2"><td class=SEntry><a href="#d2_settexturemode" id=link2 onMouseOver="ShowTip(event, 'tt2', 'link2')" onMouseOut="HideTip('tt2')">d2_settexturemode</a></td><td class=SDescription>Define texture addressing details.</td></tr><tr class="SFunction SIndent2 SMarked"><td class=SEntry><a href="#d2_settextureoperation" id=link3 onMouseOver="ShowTip(event, 'tt3', 'link3')" onMouseOut="HideTip('tt3')">d2_settextureoperation</a></td><td class=SDescription>Choose texture operation for each channel.</td></tr><tr class="SFunction SIndent2"><td class=SEntry><a href="#d2_settexopparam" id=link4 onMouseOver="ShowTip(event, 'tt4', 'link4')" onMouseOut="HideTip('tt4')">d2_settexopparam</a></td><td class=SDescription>Set texture operation parameter.</td></tr><tr class="SFunction SIndent2 SMarked"><td class=SEntry><a href="#d2_settexturemapping" id=link5 onMouseOver="ShowTip(event, 'tt5', 'link5')" onMouseOut="HideTip('tt5')">d2_settexturemapping</a></td><td class=SDescription>Define texture mapping.</td></tr><tr class="SFunction SIndent2"><td class=SEntry><a href="#d2_settexelcenter" id=link6 onMouseOver="ShowTip(event, 'tt6', 'link6')" onMouseOut="HideTip('tt6')">d2_settexelcenter</a></td><td class=SDescription>Set texel center offset.</td></tr><tr class="SFunction SIndent2 SMarked"><td class=SEntry><a href="#d2_settexclut" id=link7 onMouseOver="ShowTip(event, 'tt7', 'link7')" onMouseOut="HideTip('tt7')">d2_settexclut</a></td><td class=SDescription>Set texture colour palette pointer.</td></tr><tr class="SFunction SIndent2"><td class=SEntry><a href="#d2_settexclut_part" id=link8 onMouseOver="ShowTip(event, 'tt8', 'link8')" onMouseOut="HideTip('tt8')">d2_settexclut_part</a></td><td class=SDescription>Set a part of the color lookup table.</td></tr><tr class="SFunction SIndent2 SMarked"><td class=SEntry><a href="#d2_writetexclut_direct" id=link9 onMouseOver="ShowTip(event, 'tt9', 'link9')" onMouseOut="HideTip('tt9')">d2_writetexclut_direct</a></td><td class=SDescription>Write a part of the color lookup table directly to the render buffer.</td></tr><tr class="SFunction SIndent2"><td class=SEntry><a href="#d2_settexclut_offset" id=link10 onMouseOver="ShowTip(event, 'tt10', 'link10')" onMouseOut="HideTip('tt10')">d2_settexclut_offset</a></td><td class=SDescription>Set index offset for indexed texture formats.</td></tr><tr class="SFunction SIndent2 SMarked"><td class=SEntry><a href="#d2_settexclut_format" id=link11 onMouseOver="ShowTip(event, 'tt11', 'link11')" onMouseOut="HideTip('tt11')">d2_settexclut_format</a></td><td class=SDescription>Set color format of texture CLUT.</td></tr><tr class="SFunction SIndent2"><td class=SEntry><a href="#d2_setcolorkey" id=link12 onMouseOver="ShowTip(event, 'tt12', 'link12')" onMouseOut="HideTip('tt12')">d2_setcolorkey</a></td><td class=SDescription>Set the color for color keying.</td></tr><tr class="SGroup SIndent1"><td class=SEntry><a href="#Texture_Attribute_Queries" >Texture Attribute Queries</a></td><td class=SDescription></td></tr><tr class="SFunction SIndent2 SMarked"><td class=SEntry><a href="#d2_gettextureoperationa" id=link13 onMouseOver="ShowTip(event, 'tt13', 'link13')" onMouseOut="HideTip('tt13')">d2_gettextureoperationa</a></td><td class=SDescription>Query texture operation for alpha channel.</td></tr><tr class="SFunction SIndent2"><td class=SEntry><a href="#d2_gettextureoperationr" id=link14 onMouseOver="ShowTip(event, 'tt14', 'link14')" onMouseOut="HideTip('tt14')">d2_gettextureoperationr</a></td><td class=SDescription>Query texture operation for red channel.</td></tr><tr class="SFunction SIndent2 SMarked"><td class=SEntry><a href="#d2_gettextureoperationg" id=link15 onMouseOver="ShowTip(event, 'tt15', 'link15')" onMouseOut="HideTip('tt15')">d2_gettextureoperationg</a></td><td class=SDescription>Query texture operation for green channel.</td></tr><tr class="SFunction SIndent2"><td class=SEntry><a href="#d2_gettextureoperationb" id=link16 onMouseOver="ShowTip(event, 'tt16', 'link16')" onMouseOut="HideTip('tt16')">d2_gettextureoperationb</a></td><td class=SDescription>Query texture operation for blue channel.</td></tr><tr class="SFunction SIndent2 SMarked"><td class=SEntry><a href="#d2_gettexopparam1" id=link17 onMouseOver="ShowTip(event, 'tt17', 'link17')" onMouseOut="HideTip('tt17')">d2_gettexopparam1</a></td><td class=SDescription>Query texture operation parameter p1.</td></tr><tr class="SFunction SIndent2"><td class=SEntry><a href="#d2_gettexopparam2" id=link18 onMouseOver="ShowTip(event, 'tt18', 'link18')" onMouseOut="HideTip('tt18')">d2_gettexopparam2</a></td><td class=SDescription>Query texture operation parameter p2.</td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
|
|
|
|
<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="Texture_Attribute_Writes"></a>Texture Attribute Writes</h3></div></div>
|
|
|
|
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="d2_settexture"></a>d2_settexture</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_settexture(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>void </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>ptr,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_s32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>pitch,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_s32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>width,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_s32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>height,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>format</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Specify the source for texture mapping.</p><p>The specified texture is used only when <a href="dave_context-c.html#d2_setfillmode" class=LFunction id=link20 onMouseOver="ShowTip(event, 'tt20', 'link20')" onMouseOut="HideTip('tt20')">d2_setfillmode</a> is set to <b>d2_fm_texture</b></p><h4 class=CHeading>parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>handle</td><td class=CDLDescription>device pointer (see: <a href="dave_driver-c.html#d2_opendevice" class=LFunction id=link21 onMouseOver="ShowTip(event, 'tt21', 'link21')" onMouseOut="HideTip('tt21')">d2_opendevice</a>)</td></tr><tr><td class=CDLEntry>ptr</td><td class=CDLDescription>address of the top left texel (coordinate 0,0)</td></tr><tr><td class=CDLEntry>pitch</td><td class=CDLDescription>number of texels (<b>not bytes</b>) per scanline</td></tr><tr><td class=CDLEntry>width</td><td class=CDLDescription>width of texture in texels (equal or less than pitch)</td></tr><tr><td class=CDLEntry>height</td><td class=CDLDescription>height of texture in texels</td></tr><tr><td class=CDLEntry>format</td><td class=CDLDescription>texel encoding type (texture format)</td></tr></table><h4 class=CHeading>texture formats</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>d2_mode_alpha8</td><td class=CDLDescription>monochrome 8bit per pixel</td></tr><tr><td class=CDLEntry>d2_mode_alpha4</td><td class=CDLDescription>monochrome 4bit per pixel</td></tr><tr><td class=CDLEntry>d2_mode_alpha2</td><td class=CDLDescription>monochrome 2bit per pixel</td></tr><tr><td class=CDLEntry>d2_mode_alpha1</td><td class=CDLDescription>monochrome 1bit per pixel</td></tr><tr><td class=CDLEntry>d2_mode_rgb565</td><td class=CDLDescription>colored 16bit per pixel (alpha is blue)</td></tr><tr><td class=CDLEntry>d2_mode_argb8888</td><td class=CDLDescription>colored 32bit per pixel</td></tr><tr><td class=CDLEntry>d2_mode_rgba8888</td><td class=CDLDescription>colored 32bit per pixel</td></tr><tr><td class=CDLEntry>d2_mode_rgb888</td><td class=CDLDescription>(same as d2_mode_argb8888)</td></tr><tr><td class=CDLEntry>d2_mode_argb4444</td><td class=CDLDescription>colored 16bit per pixel</td></tr><tr><td class=CDLEntry>d2_mode_rgba4444</td><td class=CDLDescription>colored 16bit per pixel</td></tr><tr><td class=CDLEntry>d2_mode_rgb444</td><td class=CDLDescription>(same as d2_mode_argb4444)</td></tr><tr><td class=CDLEntry>d2_mode_argb1555</td><td class=CDLDescription>colored 16bit per pixel</td></tr><tr><td class=CDLEntry>d2_mode_rgba5551</td><td class=CDLDescription>colored 16bit per pixel</td></tr><tr><td class=CDLEntry>d2_mode_rgb555</td><td class=CDLDescription>(same as d2_mode_argb1555)</td></tr><tr><td class=CDLEntry>d2_mode_ai44</td><td class=CDLDescription>colored, palletized 8bit per pixel, (4 bit alpha, 4 bit indexed RGB: see <a href="#d2_settexclut" class=LFunction id=link22 onMouseOver="ShowTip(event, 'tt7', 'link22')" onMouseOut="HideTip('tt7')">d2_settexclut</a>)</td></tr><tr><td class=CDLEntry>d2_mode_i8</td><td class=CDLDescription>colored, palletized 8bit per pixel (palette is used if d2_mode_clut is also set)</td></tr><tr><td class=CDLEntry>d2_mode_i4</td><td class=CDLDescription>colored, palletized 4bit per pixel (palette is used if d2_mode_clut is also set)</td></tr><tr><td class=CDLEntry>d2_mode_i2</td><td class=CDLDescription>colored, palletized 2bit per pixel (palette is used if d2_mode_clut is also set)</td></tr><tr><td class=CDLEntry>d2_mode_i1</td><td class=CDLDescription>colored, palletized 1bit per pixel (palette is used if d2_mode_clut is also set)</td></tr></table><p>additional flags (can be combined with all above formats) :</p><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>d2_mode_clut</td><td class=CDLDescription>Enables the color look up table (for d2_mode_i8 through d2_mode_i1) (see <a href="#d2_settexclut" class=LFunction id=link23 onMouseOver="ShowTip(event, 'tt7', 'link23')" onMouseOut="HideTip('tt7')">d2_settexclut</a>).</td></tr></table><p>Modes d2_mode_rgb888, d2_mode_rgb444 and d2_mode_rgb555 can be used as well. In this case alpha information has to be ignored by setting a <a href="#d2_settextureoperation" class=LFunction id=link24 onMouseOver="ShowTip(event, 'tt3', 'link24')" onMouseOut="HideTip('tt3')">d2_settextureoperation</a> of d2_to_one for alpha.</p><p>If the CLUT is not enabled with an indexed color format (d2_mode_i8 to d2_mode_i1), the index is written directly to the framebuffer. The index can be combined with the offset, see <a href="#d2_settexclut_offset" class=LFunction id=link25 onMouseOver="ShowTip(event, 'tt10', 'link25')" onMouseOut="HideTip('tt10')">d2_settexclut_offset</a>.</p><p>In case of d2_mode_alpha4 to d2_mode_alpha1 bits are MSB aligned and replicated to the lower bits of the 8 bit format of the internal A, R, G and B channels.</p><h4 class=CHeading>returns</h4><p>errorcode (D2_OK if successful) see list of <a href="../inc/dave_errorcodes-h.html#Errorcodes" class=LSection id=link26 onMouseOver="ShowTip(event, 'tt22', 'link26')" onMouseOut="HideTip('tt22')">Errorcodes</a> for details</p><h4 class=CHeading>note</h4><p>Please notice that a cache flush using ‘d1_cacheblockflush’ might be necessary if memory contents were changed before! To avoid problems you can use the d1 driver memory management functions ‘d1_copytovidmem’ or ‘d1_copyfromvidmem’, which implicitly do a cache flush.</p></div></div></div>
|
|
|
|
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="d2_settexturemode"></a>d2_settexturemode</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_settexturemode(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>mode</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Define texture addressing details.</p><p>Texture wrapping will work with texture dimensions that are integer powers of two only (2,4,8,16,32,..). Other sizes will wrap at the next higher power of two.</p><h4 class=CHeading>parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>handle</td><td class=CDLDescription>device pointer (see: <a href="dave_driver-c.html#d2_opendevice" class=LFunction id=link27 onMouseOver="ShowTip(event, 'tt21', 'link27')" onMouseOut="HideTip('tt21')">d2_opendevice</a>)</td></tr><tr><td class=CDLEntry>mode</td><td class=CDLDescription>any combination of texture mode bits (default is d2_tm_filter, see below)</td></tr></table><h4 class=CHeading>texture mode bits</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>d2_tm_wrapu</td><td class=CDLDescription>wrap texture on U axis (x-direction)</td></tr><tr><td class=CDLEntry>d2_tm_wrapv</td><td class=CDLDescription>wrap texture on V axis (y-direction)</td></tr><tr><td class=CDLEntry>d2_tm_filteru</td><td class=CDLDescription>apply linear filter on U axis (x-direction)</td></tr><tr><td class=CDLEntry>d2_tm_filterv</td><td class=CDLDescription>apply linear filter in V axis (y-direction)</td></tr><tr><td class=CDLEntry>d2_tm_filter</td><td class=CDLDescription>apply bilinear filter (both axis)</td></tr></table><h4 class=CHeading>returns</h4><p>errorcode (D2_OK if successfull) see list of <a href="../inc/dave_errorcodes-h.html#Errorcodes" class=LSection id=link28 onMouseOver="ShowTip(event, 'tt22', 'link28')" onMouseOut="HideTip('tt22')">Errorcodes</a> for details</p></div></div></div>
|
|
|
|
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="d2_settextureoperation"></a>d2_settextureoperation</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_settextureoperation(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u8 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>amode,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u8 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>rmode,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u8 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>gmode,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u8 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>bmode</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Choose texture operation for each channel.</p><p>Textures can be ‘colorized’ by a varity of operations. A textureoperation can be defined for each channel (a,r,g,b) individually. Depending on the chosen operation one or two additional parameters have to be set using <a href="#d2_settexopparam" class=LFunction id=link29 onMouseOver="ShowTip(event, 'tt4', 'link29')" onMouseOut="HideTip('tt4')">d2_settexopparam</a>.</p><p>The default setting is d2_to_one, d2_to_copy, d2_to_copy, d2_to_copy and will therfore ignore any alpha information in the texture.</p><h4 class=CHeading>parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>handle</td><td class=CDLDescription>device pointer (see: <a href="dave_driver-c.html#d2_opendevice" class=LFunction id=link30 onMouseOver="ShowTip(event, 'tt21', 'link30')" onMouseOut="HideTip('tt21')">d2_opendevice</a>)</td></tr><tr><td class=CDLEntry>amode</td><td class=CDLDescription>texture operation for alpha channel</td></tr><tr><td class=CDLEntry>rmode</td><td class=CDLDescription>texture operation for red channel</td></tr><tr><td class=CDLEntry>gmode</td><td class=CDLDescription>texture operation for green channel</td></tr><tr><td class=CDLEntry>bmode</td><td class=CDLDescription>texture operation for blue channel</td></tr></table><h4 class=CHeading>texture operations</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>d2_to_zero</td><td class=CDLDescription>replace channel data with zero (no parameters)</td></tr><tr><td class=CDLEntry>d2_to_one</td><td class=CDLDescription>replace channel data with one (no parameters)</td></tr><tr><td class=CDLEntry>d2_to_replace</td><td class=CDLDescription>replace channel data with a constant (p1)</td></tr><tr><td class=CDLEntry>d2_to_copy</td><td class=CDLDescription>copy channel data unchanged (no parameters)</td></tr><tr><td class=CDLEntry>d2_to_invert</td><td class=CDLDescription>invert channel data (no parameters)</td></tr><tr><td class=CDLEntry>d2_to_multiply</td><td class=CDLDescription>multiply channel data with a constant (p1)</td></tr><tr><td class=CDLEntry>d2_to_invmultiply</td><td class=CDLDescription>multiply inverted data with a constant (p1)</td></tr><tr><td class=CDLEntry>d2_to_blend</td><td class=CDLDescription>use channel data to blend between two constants (p1,p2)</td></tr></table><h4 class=CHeading>returns</h4><p>errorcode (D2_OK if successfull) see list of <a href="../inc/dave_errorcodes-h.html#Errorcodes" class=LSection id=link31 onMouseOver="ShowTip(event, 'tt22', 'link31')" onMouseOut="HideTip('tt22')">Errorcodes</a> for details</p><h4 class=CHeading>see also</h4><p><a href="#d2_settexopparam" class=LFunction id=link32 onMouseOver="ShowTip(event, 'tt4', 'link32')" onMouseOut="HideTip('tt4')">d2_settexopparam</a></p></div></div></div>
|
|
|
|
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="d2_settexopparam"></a>d2_settexopparam</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_settexopparam(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>index,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>p1,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>p2</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Set texture operation parameter.</p><p>Several texture operations require additional constants. See <a href="#d2_settextureoperation" class=LFunction id=link33 onMouseOver="ShowTip(event, 'tt3', 'link33')" onMouseOut="HideTip('tt3')">d2_settextureoperation</a> for a list and description of all operations and their constants. The index parameter selects the color channels for which new parameters are to be set.</p><p>Both constant have to be in the range of 0 .. 255 unused constants (e.g. p2 in most operations) are ignored. Note that several color channel indices can be or’ed together.</p><h4 class=CHeading>parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>handle</td><td class=CDLDescription>device pointer (see: <a href="dave_driver-c.html#d2_opendevice" class=LFunction id=link34 onMouseOver="ShowTip(event, 'tt21', 'link34')" onMouseOut="HideTip('tt21')">d2_opendevice</a>)</td></tr><tr><td class=CDLEntry>index</td><td class=CDLDescription>color channel index / indices</td></tr><tr><td class=CDLEntry>p1</td><td class=CDLDescription>parameter ‘p1’ (see: <a href="#d2_settextureoperation" class=LFunction id=link35 onMouseOver="ShowTip(event, 'tt3', 'link35')" onMouseOut="HideTip('tt3')">d2_settextureoperation</a>)</td></tr><tr><td class=CDLEntry>p2</td><td class=CDLDescription>parameter ‘p2’ (see: <a href="#d2_settextureoperation" class=LFunction id=link36 onMouseOver="ShowTip(event, 'tt3', 'link36')" onMouseOut="HideTip('tt3')">d2_settextureoperation</a>)</td></tr></table><h4 class=CHeading>color channel indices</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>d2_cc_alpha</td><td class=CDLDescription>alpha channel</td></tr><tr><td class=CDLEntry>d2_cc_red</td><td class=CDLDescription>red channel</td></tr><tr><td class=CDLEntry>d2_cc_green</td><td class=CDLDescription>green channel</td></tr><tr><td class=CDLEntry>d2_cc_blue</td><td class=CDLDescription>blue channel</td></tr><tr><td class=CDLEntry>d2_cc_rgb</td><td class=CDLDescription>all channels except alpha</td></tr><tr><td class=CDLEntry>d2_cc_all</td><td class=CDLDescription>all channels</td></tr></table><h4 class=CHeading>returns</h4><p>errorcode (D2_OK if successfull) see list of <a href="../inc/dave_errorcodes-h.html#Errorcodes" class=LSection id=link37 onMouseOver="ShowTip(event, 'tt22', 'link37')" onMouseOut="HideTip('tt22')">Errorcodes</a> for details</p><h4 class=CHeading>see also</h4><p><a href="#d2_settextureoperation" class=LFunction id=link38 onMouseOver="ShowTip(event, 'tt3', 'link38')" onMouseOut="HideTip('tt3')">d2_settextureoperation</a></p></div></div></div>
|
|
|
|
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="d2_settexturemapping"></a>d2_settexturemapping</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_settexturemapping(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_point </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>x,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_point </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>y,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_s32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>u0,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_s32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>v0,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_s32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>dxu,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_s32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>dyu,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_s32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>dxv,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_s32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>dyv</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Define texture mapping.</p><p>This is the most basic function to setup the texture mapping frame of reference. You can directly specify the texture increments in u and v direction for stepping on the x or y axis.</p><h4 class=CHeading>parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>handle</td><td class=CDLDescription>device pointer (see: <a href="dave_driver-c.html#d2_opendevice" class=LFunction id=link39 onMouseOver="ShowTip(event, 'tt21', 'link39')" onMouseOut="HideTip('tt21')">d2_opendevice</a>)</td></tr><tr><td class=CDLEntry>x , y</td><td class=CDLDescription>position of the (u0,v0) texel on screen (fixedpoint)</td></tr><tr><td class=CDLEntry>u0, v0</td><td class=CDLDescription>initial texture coordinates (valid at point x,y) (16:16 fixedpoint)</td></tr><tr><td class=CDLEntry>dxu, dxv</td><td class=CDLDescription>texture increment for a step in x direction (16:16 fixedpoint)</td></tr><tr><td class=CDLEntry>dyu, dyv</td><td class=CDLDescription>texture increment for a step in y direction (16:16 fixedpoint)</td></tr></table><h4 class=CHeading>returns</h4><p>errorcode (D2_OK if successfull) see list of <a href="../inc/dave_errorcodes-h.html#Errorcodes" class=LSection id=link40 onMouseOver="ShowTip(event, 'tt22', 'link40')" onMouseOut="HideTip('tt22')">Errorcodes</a> for details</p></div></div></div>
|
|
|
|
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="d2_settexelcenter"></a>d2_settexelcenter</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_settexelcenter(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_point </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>x,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_point </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>y</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Set texel center offset.</p><p>Default texel center is top left corner (0.0 , 0.0)</p><h4 class=CHeading>parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>handle</td><td class=CDLDescription>device pointer (see: <a href="dave_driver-c.html#d2_opendevice" class=LFunction id=link41 onMouseOver="ShowTip(event, 'tt21', 'link41')" onMouseOut="HideTip('tt21')">d2_opendevice</a>)</td></tr><tr><td class=CDLEntry>x , y</td><td class=CDLDescription>subpixel position of the texel center (fixedpoint)</td></tr></table><h4 class=CHeading>returns</h4><p>errorcode (D2_OK if successfull) see list of <a href="../inc/dave_errorcodes-h.html#Errorcodes" class=LSection id=link42 onMouseOver="ShowTip(event, 'tt22', 'link42')" onMouseOut="HideTip('tt22')">Errorcodes</a> for details</p></div></div></div>
|
|
|
|
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="d2_settexclut"></a>d2_settexclut</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_settexclut(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_color </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>clut</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Set texture colour palette pointer.</p><p>For indexed texture formats (see: <a href="#d2_settexture" class=LFunction id=link43 onMouseOver="ShowTip(event, 'tt1', 'link43')" onMouseOut="HideTip('tt1')">d2_settexture</a>), a colour look-up table is used. This function registers a pointer to a ARGB CLUT (32 bit values, format 0xAARRGGBB) with the current context. The size of the CLUT must be 16 resp. 256 words (see note).</p><p>The pointer needs to be persistent, as the table is not immediately copied to the context. It is read once before the next object using textures is rendered or if <a href="#d2_settexclut_part" class=LFunction id=link44 onMouseOver="ShowTip(event, 'tt8', 'link44')" onMouseOut="HideTip('tt8')">d2_settexclut_part</a> is used. If the CLUT is changed later on, d2_settexclut has to be called again to trigger a new upload.</p><h4 class=CHeading>parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>handle</td><td class=CDLDescription>device pointer (see: <a href="dave_driver-c.html#d2_opendevice" class=LFunction id=link45 onMouseOver="ShowTip(event, 'tt21', 'link45')" onMouseOut="HideTip('tt21')">d2_opendevice</a>)</td></tr><tr><td class=CDLEntry>clut</td><td class=CDLDescription>persistent pointer to CLUT</td></tr></table><h4 class=CHeading>returns</h4><p>errorcode (D2_OK if successful) see list of <a href="../inc/dave_errorcodes-h.html#Errorcodes" class=LSection id=link46 onMouseOver="ShowTip(event, 'tt22', 'link46')" onMouseOut="HideTip('tt22')">Errorcodes</a> for details</p><h4 class=CHeading>note</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>size of CLUT:</td><td class=CDLDescription>16 x 32bit if feature bit D2FB_TEXCLUT256 = 0 (see <a href="dave_driver-c.html#d2_getrevisionhw" class=LFunction id=link47 onMouseOver="ShowTip(event, 'tt23', 'link47')" onMouseOut="HideTip('tt23')">d2_getrevisionhw</a>)</td></tr><tr><td class=CDLEntry>size of CLUT:</td><td class=CDLDescription>256 x 32bit if feature bit D2FB_TEXCLUT256 = 1 (see <a href="dave_driver-c.html#d2_getrevisionhw" class=LFunction id=link48 onMouseOver="ShowTip(event, 'tt23', 'link48')" onMouseOut="HideTip('tt23')">d2_getrevisionhw</a>)</td></tr></table><p>the parameter clut can be NULL. If the CLUT was cached then the allocated memory will be freed (see: <a href="#d2_settexclut_part" class=LFunction id=link49 onMouseOver="ShowTip(event, 'tt8', 'link49')" onMouseOut="HideTip('tt8')">d2_settexclut_part</a>)</p><h4 class=CHeading>see also</h4><p><a href="#d2_settexture" class=LFunction id=link50 onMouseOver="ShowTip(event, 'tt1', 'link50')" onMouseOut="HideTip('tt1')">d2_settexture</a>, <a href="#d2_settexclut_part" class=LFunction id=link51 onMouseOver="ShowTip(event, 'tt8', 'link51')" onMouseOut="HideTip('tt8')">d2_settexclut_part</a></p></div></div></div>
|
|
|
|
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="d2_settexclut_part"></a>d2_settexclut_part</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_settexclut_part(</td><td class="PTypePrefix prettyprint " nowrap></td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PTypePrefix prettyprint " nowrap>const </td><td class="PType prettyprint " nowrap>d2_color </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>clut_part,</td></tr><tr><td></td><td class="PTypePrefix prettyprint " nowrap></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>start_index,</td></tr><tr><td></td><td class="PTypePrefix prettyprint " nowrap></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>length</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Set a part of the color lookup table.</p><p>Only parts of the CLUT can be set or overridden. The CLUT content will be cached in the current context. If a pointer to a CLUT was given by <a href="#d2_settexclut" class=LFunction id=link52 onMouseOver="ShowTip(event, 'tt7', 'link52')" onMouseOut="HideTip('tt7')">d2_settexclut</a> this CLUT contents is first copied to the context. The contents of clut_part is then copied to the cached CLUT starting at start_index with a length of length.</p><p>The size of the CLUT is 256 resp. 16 (if feature bit D2FB_TEXCLUT256 = 1 resp. = 0 (see <a href="dave_driver-c.html#d2_getrevisionhw" class=LFunction id=link53 onMouseOver="ShowTip(event, 'tt23', 'link53')" onMouseOut="HideTip('tt23')">d2_getrevisionhw</a>))</p><h4 class=CHeading>parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>handle</td><td class=CDLDescription>device pointer (see: <a href="dave_driver-c.html#d2_opendevice" class=LFunction id=link54 onMouseOver="ShowTip(event, 'tt21', 'link54')" onMouseOut="HideTip('tt21')">d2_opendevice</a>)</td></tr><tr><td class=CDLEntry>clut_part</td><td class=CDLDescription>pointer to a segment for the CLUT</td></tr><tr><td class=CDLEntry>start_index</td><td class=CDLDescription>start index of the CLUT where clut_part will be copied to (0..size-1)</td></tr><tr><td class=CDLEntry>length</td><td class=CDLDescription>number of CLUT entries to be copied (1..size)</td></tr></table><h4 class=CHeading>returns</h4><p>errorcode (D2_OK if successful) see list of <a href="../inc/dave_errorcodes-h.html#Errorcodes" class=LSection id=link55 onMouseOver="ShowTip(event, 'tt22', 'link55')" onMouseOut="HideTip('tt22')">Errorcodes</a> for details</p><h4 class=CHeading>see also</h4><p><a href="#d2_settexclut" class=LFunction id=link56 onMouseOver="ShowTip(event, 'tt7', 'link56')" onMouseOut="HideTip('tt7')">d2_settexclut</a></p></div></div></div>
|
|
|
|
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="d2_writetexclut_direct"></a>d2_writetexclut_direct</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_writetexclut_direct(</td><td class="PTypePrefix prettyprint " nowrap></td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PTypePrefix prettyprint " nowrap>const </td><td class="PType prettyprint " nowrap>d2_color </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>clut_part,</td></tr><tr><td></td><td class="PTypePrefix prettyprint " nowrap></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>start_index,</td></tr><tr><td></td><td class="PTypePrefix prettyprint " nowrap></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>length</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Write a part of the color lookup table directly to the render buffer.</p><p>Only parts of the CLUT can be set. The contents of clut_part is written directly to the render buffer starting at start_index with a length of length.</p><p>The size of the CLUT is 256 resp. 16 (if feature bit D2FB_TEXCLUT256 = 1 resp. = 0 (see <a href="dave_driver-c.html#d2_getrevisionhw" class=LFunction id=link57 onMouseOver="ShowTip(event, 'tt23', 'link57')" onMouseOut="HideTip('tt23')">d2_getrevisionhw</a>))</p><h4 class=CHeading>parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>handle</td><td class=CDLDescription>device pointer (see: <a href="dave_driver-c.html#d2_opendevice" class=LFunction id=link58 onMouseOver="ShowTip(event, 'tt21', 'link58')" onMouseOut="HideTip('tt21')">d2_opendevice</a>)</td></tr><tr><td class=CDLEntry>clut_part</td><td class=CDLDescription>pointer to a segment for the CLUT</td></tr><tr><td class=CDLEntry>start_index</td><td class=CDLDescription>start index of the CLUT where clut_part will be written to (0..size-1)</td></tr><tr><td class=CDLEntry>length</td><td class=CDLDescription>number of CLUT entries to write (1..size)</td></tr></table><h4 class=CHeading>returns</h4><p>errorcode (D2_OK if successful) see list of <a href="../inc/dave_errorcodes-h.html#Errorcodes" class=LSection id=link59 onMouseOver="ShowTip(event, 'tt22', 'link59')" onMouseOut="HideTip('tt22')">Errorcodes</a> for details</p><h4 class=CHeading>note</h4><ul><li>no data needs to be cached</li><li>clut_part does not need to be persistent</li><li>a context switch does not restore the contents of the CLUT</li></ul><h4 class=CHeading>see also</h4><p><a href="#d2_settexclut" class=LFunction id=link60 onMouseOver="ShowTip(event, 'tt7', 'link60')" onMouseOut="HideTip('tt7')">d2_settexclut</a> <a href="#d2_settexclut_part" class=LFunction id=link61 onMouseOver="ShowTip(event, 'tt8', 'link61')" onMouseOut="HideTip('tt8')">d2_settexclut_part</a></p></div></div></div>
|
|
|
|
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="d2_settexclut_offset"></a>d2_settexclut_offset</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_settexclut_offset(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>offset</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Set index offset for indexed texture formats.</p><p>For the indexed texture formats d2_mode_i4, d2_mode_i2 and d2_mode_i1 (see: <a href="#d2_settexture" class=LFunction id=link62 onMouseOver="ShowTip(event, 'tt1', 'link62')" onMouseOut="HideTip('tt1')">d2_settexture</a>) an offset to the color index can be used.</p><p>The offset is an 8 bit resp. 4 bit value (if feature bit D2FB_TEXCLUT256 = 1 resp. = 0 (see <a href="dave_driver-c.html#d2_getrevisionhw" class=LFunction id=link63 onMouseOver="ShowTip(event, 'tt23', 'link63')" onMouseOut="HideTip('tt23')">d2_getrevisionhw</a>))</p><h4 class=CHeading>parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>handle</td><td class=CDLDescription>device pointer (see: <a href="dave_driver-c.html#d2_opendevice" class=LFunction id=link64 onMouseOver="ShowTip(event, 'tt21', 'link64')" onMouseOut="HideTip('tt21')">d2_opendevice</a>)</td></tr><tr><td class=CDLEntry>offset</td><td class=CDLDescription>offset to index (default = 0); will be or’ed with the index of the texel</td></tr></table><h4 class=CHeading>returns</h4><p>errorcode (D2_OK if successful) see list of <a href="../inc/dave_errorcodes-h.html#Errorcodes" class=LSection id=link65 onMouseOver="ShowTip(event, 'tt22', 'link65')" onMouseOut="HideTip('tt22')">Errorcodes</a> for details</p><h4 class=CHeading>see also</h4><p><a href="#d2_settexclut" class=LFunction id=link66 onMouseOver="ShowTip(event, 'tt7', 'link66')" onMouseOut="HideTip('tt7')">d2_settexclut</a> <a href="#d2_settexture" class=LFunction id=link67 onMouseOver="ShowTip(event, 'tt1', 'link67')" onMouseOut="HideTip('tt1')">d2_settexture</a></p></div></div></div>
|
|
|
|
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="d2_settexclut_format"></a>d2_settexclut_format</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_settexclut_format(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>format</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Set color format of texture CLUT.</p><p>The Color lookup table has 256 entries of 32 bit color values. Each color value is coded as ARGB8888. In case of RGB565 the CLUT 256x32bit is divided into a lower and an upper part for 256 16bit color entries. One 32bit word contains two successive 16bit color entries. The lower 16 bit contain the first color entry and the upper 16 bit contain the next color entry. The upper part of the CLUT can be accessed by the texture unit by setting the texclut_offset to 0x80. When loading the CLUT 32bit words are written to the RAM. In this 16bit mode the driver has to take care to write the correct data.</p><p>If the feature bit D2FB_TEXCLUT256 = 0 the format applies to 16 entries of 32 bit (see <a href="dave_driver-c.html#d2_getrevisionhw" class=LFunction id=link68 onMouseOver="ShowTip(event, 'tt23', 'link68')" onMouseOut="HideTip('tt23')">d2_getrevisionhw</a>).</p><h4 class=CHeading>parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>handle</td><td class=CDLDescription>device pointer (see: <a href="dave_driver-c.html#d2_opendevice" class=LFunction id=link69 onMouseOver="ShowTip(event, 'tt21', 'link69')" onMouseOut="HideTip('tt21')">d2_opendevice</a>)</td></tr><tr><td class=CDLEntry>format</td><td class=CDLDescription>color format</td></tr></table><h4 class=CHeading>returns</h4><p>errorcode (D2_OK if successful) see list of <a href="../inc/dave_errorcodes-h.html#Errorcodes" class=LSection id=link70 onMouseOver="ShowTip(event, 'tt22', 'link70')" onMouseOut="HideTip('tt22')">Errorcodes</a> for details</p><h4 class=CHeading>color formats</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>d2_mode_argb8888</td><td class=CDLDescription>colored 32bit per pixel (default)</td></tr><tr><td class=CDLEntry>d2_mode_rgb565</td><td class=CDLDescription>colored 16bit per pixel (alpha is blue)</td></tr></table><h4 class=CHeading>see also</h4><p><a href="#d2_settexclut" class=LFunction id=link71 onMouseOver="ShowTip(event, 'tt7', 'link71')" onMouseOut="HideTip('tt7')">d2_settexclut</a> <a href="#d2_settexture" class=LFunction id=link72 onMouseOver="ShowTip(event, 'tt1', 'link72')" onMouseOut="HideTip('tt1')">d2_settexture</a></p></div></div></div>
|
|
|
|
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="d2_setcolorkey"></a>d2_setcolorkey</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_setcolorkey(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_s32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>enable,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_color </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>color_key</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Set the color for color keying.</p><p>Color keying compares every RGB value of a texture pixel with color_key. If the values are equal then Alpha as well as R, G and B are set to 0 to mark the pixel transparent.</p><h4 class=CHeading>parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>handle</td><td class=CDLDescription>device pointer (see: <a href="dave_driver-c.html#d2_opendevice" class=LFunction id=link73 onMouseOver="ShowTip(event, 'tt21', 'link73')" onMouseOut="HideTip('tt21')">d2_opendevice</a>)</td></tr><tr><td class=CDLEntry>enable</td><td class=CDLDescription>enables color keying</td></tr><tr><td class=CDLEntry>color_key</td><td class=CDLDescription>RGB value of color key</td></tr></table><h4 class=CHeading>returns</h4><p>errorcode (D2_OK if successfull) see list of <a href="../inc/dave_errorcodes-h.html#Errorcodes" class=LSection id=link74 onMouseOver="ShowTip(event, 'tt22', 'link74')" onMouseOut="HideTip('tt22')">Errorcodes</a> for details</p><h4 class=CHeading>note</h4><p>colorkeying is available if the feature bit D2FB_COLORKEY is set (see <a href="dave_driver-c.html#d2_getrevisionhw" class=LFunction id=link75 onMouseOver="ShowTip(event, 'tt23', 'link75')" onMouseOut="HideTip('tt23')">d2_getrevisionhw</a>)</p><h4 class=CHeading>see also</h4><p><a href="#d2_settexture" class=LFunction id=link76 onMouseOver="ShowTip(event, 'tt1', 'link76')" onMouseOut="HideTip('tt1')">d2_settexture</a></p></div></div></div>
|
|
|
|
<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="Texture_Attribute_Queries"></a>Texture Attribute Queries</h3></div></div>
|
|
|
|
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="d2_gettextureoperationa"></a>d2_gettextureoperationa</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_u8 d2_gettextureoperationa(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Query texture operation for alpha channel.</p><p>See <a href="#d2_settextureoperation" class=LFunction id=link77 onMouseOver="ShowTip(event, 'tt3', 'link77')" onMouseOut="HideTip('tt3')">d2_settextureoperation</a> for a list of texture operations</p><h4 class=CHeading>parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>handle</td><td class=CDLDescription>device pointer (see: <a href="dave_driver-c.html#d2_opendevice" class=LFunction id=link78 onMouseOver="ShowTip(event, 'tt21', 'link78')" onMouseOut="HideTip('tt21')">d2_opendevice</a>)</td></tr></table><h4 class=CHeading>returns</h4><p>texture operation. undefined in case of an error (check with <a href="dave_driver-c.html#d2_geterror" class=LFunction id=link79 onMouseOver="ShowTip(event, 'tt24', 'link79')" onMouseOut="HideTip('tt24')">d2_geterror</a> or <a href="dave_driver-c.html#d2_geterrorstring" class=LFunction id=link80 onMouseOver="ShowTip(event, 'tt25', 'link80')" onMouseOut="HideTip('tt25')">d2_geterrorstring</a>)</p><h4 class=CHeading>see also</h4><p><a href="#d2_gettextureoperationr" class=LFunction id=link81 onMouseOver="ShowTip(event, 'tt14', 'link81')" onMouseOut="HideTip('tt14')">d2_gettextureoperationr</a>, <a href="#d2_gettextureoperationg" class=LFunction id=link82 onMouseOver="ShowTip(event, 'tt15', 'link82')" onMouseOut="HideTip('tt15')">d2_gettextureoperationg</a>, <a href="#d2_gettextureoperationb" class=LFunction id=link83 onMouseOver="ShowTip(event, 'tt16', 'link83')" onMouseOut="HideTip('tt16')">d2_gettextureoperationb</a></p></div></div></div>
|
|
|
|
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="d2_gettextureoperationr"></a>d2_gettextureoperationr</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_u8 d2_gettextureoperationr(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Query texture operation for red channel.</p><p>See <a href="#d2_settextureoperation" class=LFunction id=link84 onMouseOver="ShowTip(event, 'tt3', 'link84')" onMouseOut="HideTip('tt3')">d2_settextureoperation</a> for a list of texture operations</p><h4 class=CHeading>parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>handle</td><td class=CDLDescription>device pointer (see: <a href="dave_driver-c.html#d2_opendevice" class=LFunction id=link85 onMouseOver="ShowTip(event, 'tt21', 'link85')" onMouseOut="HideTip('tt21')">d2_opendevice</a>)</td></tr></table><h4 class=CHeading>returns</h4><p>texture operation. undefined in case of an error (check with <a href="dave_driver-c.html#d2_geterror" class=LFunction id=link86 onMouseOver="ShowTip(event, 'tt24', 'link86')" onMouseOut="HideTip('tt24')">d2_geterror</a> or <a href="dave_driver-c.html#d2_geterrorstring" class=LFunction id=link87 onMouseOver="ShowTip(event, 'tt25', 'link87')" onMouseOut="HideTip('tt25')">d2_geterrorstring</a>)</p><h4 class=CHeading>see also</h4><p><a href="#d2_gettextureoperationa" class=LFunction id=link88 onMouseOver="ShowTip(event, 'tt13', 'link88')" onMouseOut="HideTip('tt13')">d2_gettextureoperationa</a>, <a href="#d2_gettextureoperationg" class=LFunction id=link89 onMouseOver="ShowTip(event, 'tt15', 'link89')" onMouseOut="HideTip('tt15')">d2_gettextureoperationg</a>, <a href="#d2_gettextureoperationb" class=LFunction id=link90 onMouseOver="ShowTip(event, 'tt16', 'link90')" onMouseOut="HideTip('tt16')">d2_gettextureoperationb</a></p></div></div></div>
|
|
|
|
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="d2_gettextureoperationg"></a>d2_gettextureoperationg</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_u8 d2_gettextureoperationg(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Query texture operation for green channel.</p><p>See <a href="#d2_settextureoperation" class=LFunction id=link91 onMouseOver="ShowTip(event, 'tt3', 'link91')" onMouseOut="HideTip('tt3')">d2_settextureoperation</a> for a list of texture operations</p><h4 class=CHeading>parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>handle</td><td class=CDLDescription>device pointer (see: <a href="dave_driver-c.html#d2_opendevice" class=LFunction id=link92 onMouseOver="ShowTip(event, 'tt21', 'link92')" onMouseOut="HideTip('tt21')">d2_opendevice</a>)</td></tr></table><h4 class=CHeading>returns</h4><p>texture operation. undefined in case of an error (check with <a href="dave_driver-c.html#d2_geterror" class=LFunction id=link93 onMouseOver="ShowTip(event, 'tt24', 'link93')" onMouseOut="HideTip('tt24')">d2_geterror</a> or <a href="dave_driver-c.html#d2_geterrorstring" class=LFunction id=link94 onMouseOver="ShowTip(event, 'tt25', 'link94')" onMouseOut="HideTip('tt25')">d2_geterrorstring</a>)</p><h4 class=CHeading>see also</h4><p><a href="#d2_gettextureoperationa" class=LFunction id=link95 onMouseOver="ShowTip(event, 'tt13', 'link95')" onMouseOut="HideTip('tt13')">d2_gettextureoperationa</a>, <a href="#d2_gettextureoperationr" class=LFunction id=link96 onMouseOver="ShowTip(event, 'tt14', 'link96')" onMouseOut="HideTip('tt14')">d2_gettextureoperationr</a>, <a href="#d2_gettextureoperationb" class=LFunction id=link97 onMouseOver="ShowTip(event, 'tt16', 'link97')" onMouseOut="HideTip('tt16')">d2_gettextureoperationb</a></p></div></div></div>
|
|
|
|
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="d2_gettextureoperationb"></a>d2_gettextureoperationb</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_u8 d2_gettextureoperationb(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Query texture operation for blue channel.</p><p>See <a href="#d2_settextureoperation" class=LFunction id=link98 onMouseOver="ShowTip(event, 'tt3', 'link98')" onMouseOut="HideTip('tt3')">d2_settextureoperation</a> for a list of texture operations</p><h4 class=CHeading>parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>handle</td><td class=CDLDescription>device pointer (see: <a href="dave_driver-c.html#d2_opendevice" class=LFunction id=link99 onMouseOver="ShowTip(event, 'tt21', 'link99')" onMouseOut="HideTip('tt21')">d2_opendevice</a>)</td></tr></table><h4 class=CHeading>returns</h4><p>texture operation. undefined in case of an error (check with <a href="dave_driver-c.html#d2_geterror" class=LFunction id=link100 onMouseOver="ShowTip(event, 'tt24', 'link100')" onMouseOut="HideTip('tt24')">d2_geterror</a> or <a href="dave_driver-c.html#d2_geterrorstring" class=LFunction id=link101 onMouseOver="ShowTip(event, 'tt25', 'link101')" onMouseOut="HideTip('tt25')">d2_geterrorstring</a>)</p><h4 class=CHeading>see also</h4><p><a href="#d2_gettextureoperationa" class=LFunction id=link102 onMouseOver="ShowTip(event, 'tt13', 'link102')" onMouseOut="HideTip('tt13')">d2_gettextureoperationa</a>, <a href="#d2_gettextureoperationr" class=LFunction id=link103 onMouseOver="ShowTip(event, 'tt14', 'link103')" onMouseOut="HideTip('tt14')">d2_gettextureoperationr</a>, <a href="#d2_gettextureoperationg" class=LFunction id=link104 onMouseOver="ShowTip(event, 'tt15', 'link104')" onMouseOut="HideTip('tt15')">d2_gettextureoperationg</a></p></div></div></div>
|
|
|
|
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="d2_gettexopparam1"></a>d2_gettexopparam1</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_alpha d2_gettexopparam1(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>index</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Query texture operation parameter p1.</p><p>See <a href="#d2_settexopparam" class=LFunction id=link105 onMouseOver="ShowTip(event, 'tt4', 'link105')" onMouseOut="HideTip('tt4')">d2_settexopparam</a> and <a href="#d2_settextureoperation" class=LFunction id=link106 onMouseOver="ShowTip(event, 'tt3', 'link106')" onMouseOut="HideTip('tt3')">d2_settextureoperation</a> for details</p><h4 class=CHeading>parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>handle</td><td class=CDLDescription>device pointer (see: <a href="dave_driver-c.html#d2_opendevice" class=LFunction id=link107 onMouseOver="ShowTip(event, 'tt21', 'link107')" onMouseOut="HideTip('tt21')">d2_opendevice</a>)</td></tr><tr><td class=CDLEntry>index</td><td class=CDLDescription>color channel index</td></tr></table><h4 class=CHeading>color channel indices</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>d2_cc_alpha</td><td class=CDLDescription>alpha channel</td></tr><tr><td class=CDLEntry>d2_cc_red</td><td class=CDLDescription>red channel</td></tr><tr><td class=CDLEntry>d2_cc_green</td><td class=CDLDescription>green channel</td></tr><tr><td class=CDLEntry>d2_cc_blue</td><td class=CDLDescription>blue channel</td></tr></table><h4 class=CHeading>returns</h4><p>texture operation parameter p1. undefined in case of an error (check with <a href="dave_driver-c.html#d2_geterror" class=LFunction id=link108 onMouseOver="ShowTip(event, 'tt24', 'link108')" onMouseOut="HideTip('tt24')">d2_geterror</a> or <a href="dave_driver-c.html#d2_geterrorstring" class=LFunction id=link109 onMouseOver="ShowTip(event, 'tt25', 'link109')" onMouseOut="HideTip('tt25')">d2_geterrorstring</a>)</p><h4 class=CHeading>see also</h4><p><a href="#d2_settexopparam" class=LFunction id=link110 onMouseOver="ShowTip(event, 'tt4', 'link110')" onMouseOut="HideTip('tt4')">d2_settexopparam</a></p></div></div></div>
|
|
|
|
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="d2_gettexopparam2"></a>d2_gettexopparam2</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_alpha d2_gettexopparam2(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>index</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Query texture operation parameter p2.</p><p>See <a href="#d2_settexopparam" class=LFunction id=link111 onMouseOver="ShowTip(event, 'tt4', 'link111')" onMouseOut="HideTip('tt4')">d2_settexopparam</a> and <a href="#d2_settextureoperation" class=LFunction id=link112 onMouseOver="ShowTip(event, 'tt3', 'link112')" onMouseOut="HideTip('tt3')">d2_settextureoperation</a> for details</p><h4 class=CHeading>parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>handle</td><td class=CDLDescription>device pointer (see: <a href="dave_driver-c.html#d2_opendevice" class=LFunction id=link113 onMouseOver="ShowTip(event, 'tt21', 'link113')" onMouseOut="HideTip('tt21')">d2_opendevice</a>)</td></tr><tr><td class=CDLEntry>index</td><td class=CDLDescription>color channel index</td></tr></table><h4 class=CHeading>color channel indices</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>d2_cc_alpha</td><td class=CDLDescription>alpha channel</td></tr><tr><td class=CDLEntry>d2_cc_red</td><td class=CDLDescription>red channel</td></tr><tr><td class=CDLEntry>d2_cc_green</td><td class=CDLDescription>green channel</td></tr><tr><td class=CDLEntry>d2_cc_blue</td><td class=CDLDescription>blue channel</td></tr></table><h4 class=CHeading>returns</h4><p>texture operation parameter p2. undefined in case of an error (check with <a href="dave_driver-c.html#d2_geterror" class=LFunction id=link114 onMouseOver="ShowTip(event, 'tt24', 'link114')" onMouseOut="HideTip('tt24')">d2_geterror</a> or <a href="dave_driver-c.html#d2_geterrorstring" class=LFunction id=link115 onMouseOver="ShowTip(event, 'tt25', 'link115')" onMouseOut="HideTip('tt25')">d2_geterrorstring</a>)</p><h4 class=CHeading>see also</h4><p><a href="#d2_settexopparam" class=LFunction id=link116 onMouseOver="ShowTip(event, 'tt4', 'link116')" onMouseOut="HideTip('tt4')">d2_settexopparam</a></p></div></div></div>
|
|
|
|
</div><!--Content-->
|
|
|
|
|
|
<div id=Footer>© 2016 by TES Electronic Solutions · <a href="http://www.naturaldocs.org">Generated by Natural Docs</a></div><!--Footer-->
|
|
|
|
|
|
<div id=Menu><div class=MEntry><div class=MFile><a href="../doc/overview-txt.html">Driver Overview</a></div></div><div class=MEntry><div class=MFile><a href="../doc/limitations-txt.html">Limitations</a></div></div><div class=MEntry><div class=MFile><a href="../inc/dave_driver-h.html">Basic Types</a></div></div><div class=MEntry><div class=MGroup><a href="javascript:ToggleMenu('MGroupContent1')">API</a><div class=MGroupContent id=MGroupContent1><div class=MEntry><div class=MFile><a href="dave_driver-c.html">Basic Functions</a></div></div><div class=MEntry><div class=MFile><a href="dave_viewport-c.html">Viewport Functions</a></div></div><div class=MEntry><div class=MFile><a href="dave_context-c.html">Context Functions</a></div></div><div class=MEntry><div class=MFile id=MSelected>Texture Functions</div></div><div class=MEntry><div class=MFile><a href="dave_render-c.html">Rendering Functions</a></div></div><div class=MEntry><div class=MFile><a href="dave_blit-c.html">Blit Functions</a></div></div><div class=MEntry><div class=MFile><a href="dave_rbuffer-c.html">Render Buffers</a></div></div><div class=MEntry><div class=MFile><a href="dave_perfcount-c.html">Profiling</a></div></div><div class=MEntry><div class=MFile><a href="dave_utility-c.html">Utility Functions</a></div></div><div class=MEntry><div class=MFile><a href="dave_64bitoperation-c.html">Functions for 64bit operations</a></div></div><div class=MEntry><div class=MFile><a href="dave_dlist-c.html">Dlist Functions</a></div></div><div class=MEntry><div class=MFile><a href="../inc/dave_math-h.html">Math Functions</a></div></div><div class=MEntry><div class=MFile><a href="../inc/dave_errorcodes-h.html">Errorcodes</a></div></div></div></div></div><div class=MEntry><div class=MGroup><a href="javascript:ToggleMenu('MGroupContent2')">Index</a><div class=MGroupContent id=MGroupContent2><div class=MEntry><div class=MIndex><a href="../../index/General.html">Everything</a></div></div><div class=MEntry><div class=MIndex><a href="../../index/Functions.html">Functions</a></div></div><div class=MEntry><div class=MIndex><a href="../../index/Types.html">Types</a></div></div></div></div></div><script type="text/javascript"><!--
|
|
var searchPanel = new SearchPanel("searchPanel", "HTML", "../../search");
|
|
--></script><div id=MSearchPanel class=MSearchPanelInactive><input type=text id=MSearchField value=Search onFocus="searchPanel.OnSearchFieldFocus(true)" onBlur="searchPanel.OnSearchFieldFocus(false)" onKeyUp="searchPanel.OnSearchFieldChange()"><select id=MSearchType onFocus="searchPanel.OnSearchTypeFocus(true)" onBlur="searchPanel.OnSearchTypeFocus(false)" onChange="searchPanel.OnSearchTypeChange()"><option id=MSearchEverything selected value="General">Everything</option><option value="Functions">Functions</option><option value="Types">Types</option></select></div></div><!--Menu-->
|
|
|
|
|
|
|
|
<!--START_ND_TOOLTIPS-->
|
|
<div class=CToolTip id="tt1"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_settexture(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>void </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>ptr,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_s32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>pitch,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_s32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>width,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_s32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>height,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>format</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Specify the source for texture mapping.</div></div><div class=CToolTip id="tt2"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_settexturemode(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>mode</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Define texture addressing details.</div></div><div class=CToolTip id="tt3"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_settextureoperation(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u8 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>amode,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u8 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>rmode,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u8 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>gmode,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u8 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>bmode</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Choose texture operation for each channel.</div></div><div class=CToolTip id="tt4"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_settexopparam(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>index,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>p1,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>p2</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Set texture operation parameter.</div></div><div class=CToolTip id="tt5"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_settexturemapping(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_point </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>x,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_point </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>y,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_s32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>u0,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_s32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>v0,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_s32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>dxu,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_s32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>dyu,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_s32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>dxv,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_s32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>dyv</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Define texture mapping.</div></div><div class=CToolTip id="tt6"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_settexelcenter(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_point </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>x,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_point </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>y</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Set texel center offset.</div></div><div class=CToolTip id="tt7"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_settexclut(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_color </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>clut</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Set texture colour palette pointer.</div></div><div class=CToolTip id="tt8"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_settexclut_part(</td><td class="PTypePrefix prettyprint " nowrap></td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PTypePrefix prettyprint " nowrap>const </td><td class="PType prettyprint " nowrap>d2_color </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>clut_part,</td></tr><tr><td></td><td class="PTypePrefix prettyprint " nowrap></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>start_index,</td></tr><tr><td></td><td class="PTypePrefix prettyprint " nowrap></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>length</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Set a part of the color lookup table.</div></div><div class=CToolTip id="tt9"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_writetexclut_direct(</td><td class="PTypePrefix prettyprint " nowrap></td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PTypePrefix prettyprint " nowrap>const </td><td class="PType prettyprint " nowrap>d2_color </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>clut_part,</td></tr><tr><td></td><td class="PTypePrefix prettyprint " nowrap></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>start_index,</td></tr><tr><td></td><td class="PTypePrefix prettyprint " nowrap></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>length</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Write a part of the color lookup table directly to the render buffer.</div></div><div class=CToolTip id="tt10"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_settexclut_offset(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>offset</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Set index offset for indexed texture formats.</div></div><div class=CToolTip id="tt11"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_settexclut_format(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>format</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Set color format of texture CLUT.</div></div><div class=CToolTip id="tt12"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_setcolorkey(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_s32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>enable,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_color </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>color_key</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Set the color for color keying.</div></div><div class=CToolTip id="tt13"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_u8 d2_gettextureoperationa(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Query texture operation for alpha channel.</div></div><div class=CToolTip id="tt14"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_u8 d2_gettextureoperationr(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Query texture operation for red channel.</div></div><div class=CToolTip id="tt15"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_u8 d2_gettextureoperationg(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Query texture operation for green channel.</div></div><div class=CToolTip id="tt16"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_u8 d2_gettextureoperationb(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Query texture operation for blue channel.</div></div><div class=CToolTip id="tt17"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_alpha d2_gettexopparam1(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>index</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Query texture operation parameter p1.</div></div><div class=CToolTip id="tt18"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_alpha d2_gettexopparam2(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>index</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Query texture operation parameter p2.</div></div><div class=CToolTip id="tt19"><div class=CSection>Modify material settings</div></div><div class=CToolTip id="tt20"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_setfillmode(</td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle,</td></tr><tr><td></td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameterPrefix prettyprint " nowrap></td><td class="PParameter prettyprint " nowrap>mode</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Select fillmode (solid,patter,texture,..)</div></div><div class=CToolTip id="tt21"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_device * d2_opendevice(</td><td class="PType prettyprint " nowrap>d2_u32 </td><td class="PParameter prettyprint " nowrap>flags</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Create a new device handle.</div></div><div class=CToolTip id="tt22"><div class=CSection>List of all dave driver errorcodes.</div></div><div class=CToolTip id="tt23"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_u32 d2_getrevisionhw(</td><td class="PTypePrefix prettyprint " nowrap>const </td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Query hw revisionID. </div></div><div class=CToolTip id="tt24"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>d2_s32 d2_geterror(</td><td class="PTypePrefix prettyprint " nowrap>const </td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Query device error information.</div></div><div class=CToolTip id="tt25"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>const d2_char * d2_geterrorstring(</td><td class="PTypePrefix prettyprint " nowrap>const </td><td class="PType prettyprint " nowrap>d2_device </td><td class="PParameterPrefix prettyprint " nowrap>*</td><td class="PParameter prettyprint " nowrap>handle</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Query detailed device error information.</div></div><!--END_ND_TOOLTIPS-->
|
|
|
|
|
|
|
|
|
|
<div id=MSearchResultsWindow><iframe src="" frameborder=0 name=MSearchResults id=MSearchResults></iframe><a href="javascript:searchPanel.CloseResultsWindow()" id=MSearchResultsWindowClose>Close</a></div>
|
|
|
|
|
|
<script language=JavaScript><!--
|
|
if (browserType) {if (browserVer) {document.write("</div>"); }document.write("</div>");}// --></script></body></html> |