📄 appearance.html
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN""http://www.w3.org/TR/REC-html40/loose.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<!-- Generated by javadoc on Thu Nov 27 13:54:34 EET 2003 -->
<META http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<TITLE>
Appearance (Mobile 3D Graphics API (M3G))
</TITLE>
<META NAME="keywords" CONTENT="javax.microedition.m3g.Appearance,Appearance class">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
</HEAD>
<SCRIPT>
function asd()
{
parent.document.title="Appearance (Mobile 3D Graphics API (M3G))";
}
</SCRIPT>
<BODY BGCOLOR="white" onload="asd();">
<!-- ========== START OF NAVBAR ========== -->
<A NAME="navbar_top"><!-- --></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0">
<TR>
<TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_top_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/Appearance.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-files/index-1.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
<EM><B>Nov 19, 2003</B></EM></EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../javax/microedition/m3g/AnimationTrack.html"><B>PREV CLASS</B></A>
<A HREF="../../../javax/microedition/m3g/Background.html"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../index.html" TARGET="_top"><B>FRAMES</B></A>
<A HREF="Appearance.html" TARGET="_top"><B>NO FRAMES</B></A>
<SCRIPT> <!-- if(window==top) { document.writeln('<A HREF="../../../allclasses-noframe.html" TARGET=""><B>All Classes</B></A>'); } //--></SCRIPT><NOSCRIPT><A HREF="../../../allclasses-noframe.html" TARGET=""><B>All Classes</B></A></NOSCRIPT></FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY: NESTED | FIELD | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL: FIELD | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<!-- =========== END OF NAVBAR =========== -->
<HR>
<!-- ======== START OF CLASS DATA ======== -->
<H2>
<FONT SIZE="-1">
javax.microedition.m3g</FONT>
<BR>
Class Appearance</H2>
<PRE>
java.lang.Object
|
+--<A HREF="../../../javax/microedition/m3g/Object3D.html">javax.microedition.m3g.Object3D</A>
|
+--<B>javax.microedition.m3g.Appearance</B>
</PRE>
<HR>
<DL>
<DT>public class <B>Appearance</B><DT>extends <A HREF="../../../javax/microedition/m3g/Object3D.html">Object3D</A></DL>
<P>
<p>A set of component objects that define the rendering attributes ofa Mesh or Sprite3D.</p><p>Appearance attributes are grouped into component objects, eachencapsulating a set of properties that are functionally and logicallyrelated to each other. This division helps applications to conservememory by sharing component objects across multiple meshes andsprites. The Appearance component classes and a summary of theircontents are presented in the figure below.</p><center><img src="./doc-files/Appearance-components.png"/></center><p>All components of a newly created Appearance object are initialized to null.It is completely legal for any or all of the components to be null even whenrendering. The behavior when each of the components is null is as follows:</p><ul><li>If a Texture2D is null, the corresponding texturing unit is disabled.</li><li>If the PolygonMode is null, default values are used.</li><li>If the CompositingMode is null, default values are used.</li><li>If the Material is null, lighting is disabled.</li><li>If the Fog is null, fogging is disabled.</li></ul><p>Using a null Appearance on a submesh (or sprite) disables rendering andpicking of that submesh (or sprite). An Appearance must always be providedfor an object in order to make it visible.</p><h3>Implementation guidelines</h3><p>By default, everything in Appearance works exactly the same way as inOpenGL 1.3. As a general exception, the color index (palette) mode is notsupported. Other than that, any deviations from the OpenGL 1.3 specificationare documented explicitly in the individual Appearance component classes.</p>
<P>
<P>
<DL>
<DT><B>See Also:</B><DD><a href="../../../file-format.html#Appearance">Binary format</a></DL>
<HR>
<P>
<!-- ======== NESTED CLASS SUMMARY ======== -->
<!-- =========== FIELD SUMMARY =========== -->
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<A NAME="constructor_summary"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Constructor Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Appearance.html#Appearance()">Appearance</A></B>()</CODE>
<BR>
Constructs an Appearance object with default values. </TD>
</TR>
</TABLE>
<!-- ========== 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> <A HREF="../../../javax/microedition/m3g/CompositingMode.html">CompositingMode</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Appearance.html#getCompositingMode()">getCompositingMode</A></B>()</CODE>
<BR>
Returns the current CompositingMode for this Appearance.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../javax/microedition/m3g/Fog.html">Fog</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Appearance.html#getFog()">getFog</A></B>()</CODE>
<BR>
Returns the current fogging attributes for this Appearance.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Appearance.html#getLayer()">getLayer</A></B>()</CODE>
<BR>
Gets the current rendering layer for this Appearance.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../javax/microedition/m3g/Material.html">Material</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Appearance.html#getMaterial()">getMaterial</A></B>()</CODE>
<BR>
Returns the current Material for this Appearance.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../javax/microedition/m3g/PolygonMode.html">PolygonMode</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Appearance.html#getPolygonMode()">getPolygonMode</A></B>()</CODE>
<BR>
Returns the current PolygonMode for this Appearance.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../javax/microedition/m3g/Texture2D.html">Texture2D</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Appearance.html#getTexture(int)">getTexture</A></B>(int index)</CODE>
<BR>
Retrieves the current texture image and its attributes for the given texturing unit.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Appearance.html#setCompositingMode(javax.microedition.m3g.CompositingMode)">setCompositingMode</A></B>(<A HREF="../../../javax/microedition/m3g/CompositingMode.html">CompositingMode</A> compositingMode)</CODE>
<BR>
Sets the CompositingMode to use for this Appearance. </TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Appearance.html#setFog(javax.microedition.m3g.Fog)">setFog</A></B>(<A HREF="../../../javax/microedition/m3g/Fog.html">Fog</A> fog)</CODE>
<BR>
Sets the fogging attributes to use for this Appearance. </TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Appearance.html#setLayer(int)">setLayer</A></B>(int layer)</CODE>
<BR>
Sets the rendering layer for this Appearance. </TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Appearance.html#setMaterial(javax.microedition.m3g.Material)">setMaterial</A></B>(<A HREF="../../../javax/microedition/m3g/Material.html">Material</A> material)</CODE>
<BR>
Sets the Material to use when lighting this Appearance. </TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Appearance.html#setPolygonMode(javax.microedition.m3g.PolygonMode)">setPolygonMode</A></B>(<A HREF="../../../javax/microedition/m3g/PolygonMode.html">PolygonMode</A> polygonMode)</CODE>
<BR>
Sets the PolygonMode to use for this Appearance. </TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../javax/microedition/m3g/Appearance.html#setTexture(int, javax.microedition.m3g.Texture2D)">setTexture</A></B>(int index, <A HREF="../../../javax/microedition/m3g/Texture2D.html">Texture2D</A> texture)</CODE>
<BR>
Sets the texture image and its attributes for the given texturing unit. </TD>
</TR>
</TABLE>
<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>
<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>
<P>
<!-- ============ FIELD DETAIL =========== -->
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<A NAME="constructor_detail"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Constructor Detail</B></FONT></TD>
</TR>
</TABLE>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -