⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 texture2d.html

📁 J2ME Mobile3D API,高性能手机3D开发的api
💻 HTML
📖 第 1 页 / 共 4 页
字号:
<B>Constructor Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Texture2D.html#Texture2D(javax.microedition.m3g.Image2D)">Texture2D</A></B>(<A HREF="../../../javax/microedition/m3g/Image2D.html">Image2D</A>&nbsp;image)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Constructs a new texture object with the given image, setting the texture attributes to their default values. </TD>
</TR>
</TABLE>
&nbsp;
<!-- ========== METHOD SUMMARY =========== -->

<A NAME="method_summary"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Method Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Texture2D.html#getBlendColor()">getBlendColor</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the current texture blend color for this Texture2D. </TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Texture2D.html#getBlending()">getBlending</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the current texture blend mode for this Texture2D.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="../../../javax/microedition/m3g/Image2D.html">Image2D</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Texture2D.html#getImage()">getImage</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Retrieves the current base level (full size) texture image.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Texture2D.html#getWrappingS()">getWrappingS</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the current texture wrapping mode for the S texture coordinate.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Texture2D.html#getWrappingT()">getWrappingT</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the current texture wrapping mode for the T texture coordinate.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Texture2D.html#setBlendColor(int)">setBlendColor</A></B>(int&nbsp;RGB)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the texture blend color for this Texture2D. </TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Texture2D.html#setBlending(int)">setBlending</A></B>(int&nbsp;func)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Selects the texture blend mode, or blend function, for this Texture2D.  </TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Texture2D.html#setFiltering(int, int)">setFiltering</A></B>(int&nbsp;levelFilter,             int&nbsp;imageFilter)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Selects the filtering mode for this Texture2D. </TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Texture2D.html#setImage(javax.microedition.m3g.Image2D)">setImage</A></B>(<A HREF="../../../javax/microedition/m3g/Image2D.html">Image2D</A>&nbsp;image)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the given Image2D as the texture image of this Texture2D. </TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Texture2D.html#setWrapping(int, int)">setWrapping</A></B>(int&nbsp;wrapS,            int&nbsp;wrapT)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the wrapping mode for the S and T texture coordinates.</TD>
</TR>
</TABLE>
&nbsp;<A NAME="methods_inherited_from_class_javax.microedition.m3g.Transformable"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TD><B>Methods inherited from class javax.microedition.m3g.<A HREF="../../../javax/microedition/m3g/Transformable.html">Transformable</A></B></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><A HREF="../../../javax/microedition/m3g/Transformable.html#getCompositeTransform(javax.microedition.m3g.Transform)">getCompositeTransform</A>, <A HREF="../../../javax/microedition/m3g/Transformable.html#getOrientation(float[])">getOrientation</A>, <A HREF="../../../javax/microedition/m3g/Transformable.html#getScale(float[])">getScale</A>, <A HREF="../../../javax/microedition/m3g/Transformable.html#getTransform(javax.microedition.m3g.Transform)">getTransform</A>, <A HREF="../../../javax/microedition/m3g/Transformable.html#getTranslation(float[])">getTranslation</A>, <A HREF="../../../javax/microedition/m3g/Transformable.html#postRotate(float, float, float, float)">postRotate</A>, <A HREF="../../../javax/microedition/m3g/Transformable.html#preRotate(float, float, float, float)">preRotate</A>, <A HREF="../../../javax/microedition/m3g/Transformable.html#scale(float, float, float)">scale</A>, <A HREF="../../../javax/microedition/m3g/Transformable.html#setOrientation(float, float, float, float)">setOrientation</A>, <A HREF="../../../javax/microedition/m3g/Transformable.html#setScale(float, float, float)">setScale</A>, <A HREF="../../../javax/microedition/m3g/Transformable.html#setTransform(javax.microedition.m3g.Transform)">setTransform</A>, <A HREF="../../../javax/microedition/m3g/Transformable.html#setTranslation(float, float, float)">setTranslation</A>, <A HREF="../../../javax/microedition/m3g/Transformable.html#translate(float, float, float)">translate</A></CODE></TD>
</TR>
</TABLE>
&nbsp;<A NAME="methods_inherited_from_class_javax.microedition.m3g.Object3D"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TD><B>Methods inherited from class javax.microedition.m3g.<A HREF="../../../javax/microedition/m3g/Object3D.html">Object3D</A></B></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><A HREF="../../../javax/microedition/m3g/Object3D.html#addAnimationTrack(javax.microedition.m3g.AnimationTrack)">addAnimationTrack</A>, <A HREF="../../../javax/microedition/m3g/Object3D.html#animate(int)">animate</A>, <A HREF="../../../javax/microedition/m3g/Object3D.html#duplicate()">duplicate</A>, <A HREF="../../../javax/microedition/m3g/Object3D.html#find(int)">find</A>, <A HREF="../../../javax/microedition/m3g/Object3D.html#getAnimationTrack(int)">getAnimationTrack</A>, <A HREF="../../../javax/microedition/m3g/Object3D.html#getAnimationTrackCount()">getAnimationTrackCount</A>, <A HREF="../../../javax/microedition/m3g/Object3D.html#getReferences(javax.microedition.m3g.Object3D[])">getReferences</A>, <A HREF="../../../javax/microedition/m3g/Object3D.html#getUserID()">getUserID</A>, <A HREF="../../../javax/microedition/m3g/Object3D.html#getUserObject()">getUserObject</A>, <A HREF="../../../javax/microedition/m3g/Object3D.html#removeAnimationTrack(javax.microedition.m3g.AnimationTrack)">removeAnimationTrack</A>, <A HREF="../../../javax/microedition/m3g/Object3D.html#setUserID(int)">setUserID</A>, <A HREF="../../../javax/microedition/m3g/Object3D.html#setUserObject(java.lang.Object)">setUserObject</A></CODE></TD>
</TR>
</TABLE>
&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TD><B>Methods inherited from class java.lang.Object</B></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE>equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</CODE></TD>
</TR>
</TABLE>
&nbsp;
<P>

<!-- ============ FIELD DETAIL =========== -->

<A NAME="field_detail"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Field Detail</B></FONT></TD>
</TR>
</TABLE>

<A NAME="FILTER_BASE_LEVEL"><!-- --></A><H3>
FILTER_BASE_LEVEL</H3>
<PRE>
public static final int <B>FILTER_BASE_LEVEL</B></PRE>
<DL>
<DD><p>A level filtering parameter to <code>setFiltering</code> that selects the base level image, even if mipmap levels exist. This is not applicable as the <code>imageFilter</code> parameter.</p>
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../constant-values.html#javax.microedition.m3g.Texture2D.FILTER_BASE_LEVEL">Constant Field Values</A></DL>
</DL>
<HR>

<A NAME="FILTER_LINEAR"><!-- --></A><H3>
FILTER_LINEAR</H3>
<PRE>
public static final int <B>FILTER_LINEAR</B></PRE>
<DL>
<DD><p>A parameter to <code>setFiltering</code> that selects linear filtering. As a level filter parameter, it specifies that a weighted average of the two closest mipmap levels should be selected. As an image filter parameter, it specifies that a weighted average of the four texels that are nearest to (s, t) in Manhattan distance should be selected.</p>
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../constant-values.html#javax.microedition.m3g.Texture2D.FILTER_LINEAR">Constant Field Values</A></DL>
</DL>
<HR>

<A NAME="FILTER_NEAREST"><!-- --></A><H3>
FILTER_NEAREST</H3>
<PRE>
public static final int <B>FILTER_NEAREST</B></PRE>
<DL>
<DD><p>A parameter to <code>setFiltering</code> that selects nearest neighbor filtering. As a level filter parameter, it specifies that the closest mipmap level should be selected. As an image filter parameter, it specifies that the texel that is nearest to (s, t) in Manhattan distance should be selected.</p>
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../constant-values.html#javax.microedition.m3g.Texture2D.FILTER_NEAREST">Constant Field Values</A></DL>
</DL>
<HR>

<A NAME="FUNC_ADD"><!-- --></A><H3>
FUNC_ADD</H3>
<PRE>
public static final int <B>FUNC_ADD</B></PRE>
<DL>
<DD><p>A parameter to <code>setBlending</code>, specifying that the texel color is to be added to the fragment color. The texel alpha is to be multiplied with the fragment alpha.</p>
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../constant-values.html#javax.microedition.m3g.Texture2D.FUNC_ADD">Constant Field Values</A></DL>
</DL>
<HR>

<A NAME="FUNC_BLEND"><!-- --></A><H3>
FUNC_BLEND</H3>
<PRE>
public static final int <B>FUNC_BLEND</B></PRE>
<DL>
<DD><p>A parameter to <code>setBlending</code>, specifying that the texture blend color is to be blended into the fragment color in proportion to the texel RGB values. The texel alpha is to be multiplied with the fragment alpha.</p>
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../constant-values.html#javax.microedition.m3g.Texture2D.FUNC_BLEND">Constant Field Values</A></DL>
</DL>
<HR>

<A NAME="FUNC_DECAL"><!-- --></A><H3>
FUNC_DECAL</H3>
<PRE>
public static final int <B>FUNC_DECAL</B></PRE>
<DL>
<DD><p>A parameter to <code>setBlending</code>, specifying that the texel color is to be blended into the fragment color in proportion to the texel alpha.</p>
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../constant-values.html#javax.microedition.m3g.Texture2D.FUNC_DECAL">Constant Field Values</A></DL>
</DL>
<HR>

<A NAME="FUNC_MODULATE"><!-- --></A><H3>
FUNC_MODULATE</H3>
<PRE>
public static final int <B>FUNC_MODULATE</B></PRE>
<DL>
<DD><p>A parameter to <code>setBlending</code>, specifying that the texel color and/or alpha are to be multiplied with the fragment color and alpha.</p>
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../constant-values.html#javax.microedition.m3g.Texture2D.FUNC_MODULATE">Constant Field Values</A></DL>
</DL>
<HR>

<A NAME="FUNC_REPLACE"><!-- --></A><H3>
FUNC_REPLACE</H3>
<PRE>
public static final int <B>FUNC_REPLACE</B></PRE>
<DL>
<DD><p>A parameter to <code>setBlending</code>, specifying that the texel color and/or alpha are to replace the fragment color and alpha.</p>
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../constant-values.html#javax.microedition.m3g.Texture2D.FUNC_REPLACE">Constant Field Values</A></DL>
</DL>
<HR>

<A NAME="WRAP_CLAMP"><!-- --></A><H3>
WRAP_CLAMP</H3>
<PRE>
public static final int <B>WRAP_CLAMP</B></PRE>
<DL>
<DD><p>A parameter to <code>setWrapping</code>, specifying that the texture image is to be repeated only once. This can be specified independently for the S and T texture coordinates. Formally, clamping means that the texture coordinate value is clamped to the range [0, 1]. This is equivalent to the <code>CLAMP</code> mode, with a border width of zero, in OpenGL.</p>
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../constant-values.html#javax.microedition.m3g.Texture2D.WRAP_CLAMP">Constant Field Values</A></DL>
</DL>
<HR>

<A NAME="WRAP_REPEAT"><!-- --></A><H3>
WRAP_REPEAT</H3>
<PRE>
public static final int <B>WRAP_REPEAT</B></PRE>
<DL>
<DD><p>A parameter to <code>setWrapping</code>, specifying that the texture image is to be repeated indefinitely. This can be specified independently for the S and T texture coordinates. Formally, repeating

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -