mirror of
https://github.com/curioustorvald/Terrarum.git
synced 2026-03-12 14:51:51 +09:00
Former-commit-id: 9340873f9cfb15264004c32d6e4b8f8bd6828d94 Former-commit-id: 1916747c109876aa064412e01204c3aeda9bbbc0
658 lines
23 KiB
HTML
658 lines
23 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
|
|
<!--NewPage-->
|
|
<HTML>
|
|
<HEAD>
|
|
<!-- Generated by javadoc (build 1.6.0_34) on Mon Jun 03 22:20:32 BST 2013 -->
|
|
<TITLE>
|
|
Gradient (Slick - The 2D Library)
|
|
</TITLE>
|
|
|
|
<META NAME="date" CONTENT="2013-06-03">
|
|
|
|
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
|
|
|
|
<SCRIPT type="text/javascript">
|
|
function windowTitle()
|
|
{
|
|
if (location.href.indexOf('is-external=true') == -1) {
|
|
parent.document.title="Gradient (Slick - The 2D Library)";
|
|
}
|
|
}
|
|
</SCRIPT>
|
|
<NOSCRIPT>
|
|
</NOSCRIPT>
|
|
|
|
</HEAD>
|
|
|
|
<BODY BGCOLOR="white" onload="windowTitle();">
|
|
<HR>
|
|
|
|
|
|
<!-- ========= START OF TOP NAVBAR ======= -->
|
|
<A NAME="navbar_top"><!-- --></A>
|
|
<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
|
|
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
|
|
<TR>
|
|
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
|
|
<A NAME="navbar_top_firstrow"><!-- --></A>
|
|
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
|
|
<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/Gradient.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-all.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>
|
|
</TD>
|
|
</TR>
|
|
|
|
<TR>
|
|
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
|
|
<A HREF="../../../../org/newdawn/slick/svg/Figure.html" title="class in org.newdawn.slick.svg"><B>PREV CLASS</B></A>
|
|
<A HREF="../../../../org/newdawn/slick/svg/InkscapeLoader.html" title="class in org.newdawn.slick.svg"><B>NEXT CLASS</B></A></FONT></TD>
|
|
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
|
|
<A HREF="../../../../index.html?org/newdawn/slick/svg/Gradient.html" target="_top"><B>FRAMES</B></A>
|
|
<A HREF="Gradient.html" target="_top"><B>NO FRAMES</B></A>
|
|
<SCRIPT type="text/javascript">
|
|
<!--
|
|
if(window==top) {
|
|
document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
|
|
}
|
|
//-->
|
|
</SCRIPT>
|
|
<NOSCRIPT>
|
|
<A HREF="../../../../allclasses-noframe.html"><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>
|
|
<A NAME="skip-navbar_top"></A>
|
|
<!-- ========= END OF TOP NAVBAR ========= -->
|
|
|
|
<HR>
|
|
<!-- ======== START OF CLASS DATA ======== -->
|
|
<H2>
|
|
<FONT SIZE="-1">
|
|
org.newdawn.slick.svg</FONT>
|
|
<BR>
|
|
Class Gradient</H2>
|
|
<PRE>
|
|
java.lang.Object
|
|
<IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><B>org.newdawn.slick.svg.Gradient</B>
|
|
</PRE>
|
|
<HR>
|
|
<DL>
|
|
<DT><PRE>public class <B>Gradient</B><DT>extends java.lang.Object</DL>
|
|
</PRE>
|
|
|
|
<P>
|
|
A gradient definition from an SVG file, includes the stops, name and transform.
|
|
<P>
|
|
|
|
<P>
|
|
<DL>
|
|
<DT><B>Author:</B></DT>
|
|
<DD>kevin</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<P>
|
|
|
|
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
|
|
|
|
<A NAME="constructor_summary"><!-- --></A>
|
|
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
|
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
|
|
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
|
|
<B>Constructor Summary</B></FONT></TH>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD><CODE><B><A HREF="../../../../org/newdawn/slick/svg/Gradient.html#Gradient(java.lang.String, boolean)">Gradient</A></B>(java.lang.String name,
|
|
boolean radial)</CODE>
|
|
|
|
<BR>
|
|
Create a new gradient definition</TD>
|
|
</TR>
|
|
</TABLE>
|
|
|
|
<!-- ========== METHOD SUMMARY =========== -->
|
|
|
|
<A NAME="method_summary"><!-- --></A>
|
|
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
|
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
|
|
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
|
|
<B>Method Summary</B></FONT></TH>
|
|
</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="../../../../org/newdawn/slick/svg/Gradient.html#addStep(float, org.newdawn.slick.Color)">addStep</A></B>(float location,
|
|
<A HREF="../../../../org/newdawn/slick/Color.html" title="class in org.newdawn.slick">Color</A> c)</CODE>
|
|
|
|
<BR>
|
|
Add a colour step/stop to the gradient</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="../../../../org/newdawn/slick/svg/Gradient.html#genImage()">genImage</A></B>()</CODE>
|
|
|
|
<BR>
|
|
Generate the image used for texturing the gradient across shapes</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE> <A HREF="../../../../org/newdawn/slick/Color.html" title="class in org.newdawn.slick">Color</A></CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../org/newdawn/slick/svg/Gradient.html#getColorAt(float)">getColorAt</A></B>(float p)</CODE>
|
|
|
|
<BR>
|
|
Get the intepolated colour at the given location on the gradient</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE> <A HREF="../../../../org/newdawn/slick/Image.html" title="class in org.newdawn.slick">Image</A></CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../org/newdawn/slick/svg/Gradient.html#getImage()">getImage</A></B>()</CODE>
|
|
|
|
<BR>
|
|
Get the image generated for this gradient</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE> float</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../org/newdawn/slick/svg/Gradient.html#getR()">getR</A></B>()</CODE>
|
|
|
|
<BR>
|
|
Get the radius value given for this gradient</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE> <A HREF="../../../../org/newdawn/slick/geom/Transform.html" title="class in org.newdawn.slick.geom">Transform</A></CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../org/newdawn/slick/svg/Gradient.html#getTransform()">getTransform</A></B>()</CODE>
|
|
|
|
<BR>
|
|
Get the transform to apply during this gradient application</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE> float</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../org/newdawn/slick/svg/Gradient.html#getX1()">getX1</A></B>()</CODE>
|
|
|
|
<BR>
|
|
Get the first x value given for this gradient (cx in the case of radial)</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE> float</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../org/newdawn/slick/svg/Gradient.html#getX2()">getX2</A></B>()</CODE>
|
|
|
|
<BR>
|
|
Get the second x value given for this gradient (fx in the case of radial)</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE> float</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../org/newdawn/slick/svg/Gradient.html#getY1()">getY1</A></B>()</CODE>
|
|
|
|
<BR>
|
|
Get the first y value given for this gradient (cy in the case of radial)</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE> float</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../org/newdawn/slick/svg/Gradient.html#getY2()">getY2</A></B>()</CODE>
|
|
|
|
<BR>
|
|
Get the second y value given for this gradient (fy in the case of radial)</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE> boolean</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../org/newdawn/slick/svg/Gradient.html#isRadial()">isRadial</A></B>()</CODE>
|
|
|
|
<BR>
|
|
Check if the gradient is radial</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="../../../../org/newdawn/slick/svg/Gradient.html#reference(java.lang.String)">reference</A></B>(java.lang.String ref)</CODE>
|
|
|
|
<BR>
|
|
Reference another gradient, i.e.</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="../../../../org/newdawn/slick/svg/Gradient.html#resolve(org.newdawn.slick.svg.Diagram)">resolve</A></B>(<A HREF="../../../../org/newdawn/slick/svg/Diagram.html" title="class in org.newdawn.slick.svg">Diagram</A> diagram)</CODE>
|
|
|
|
<BR>
|
|
Resolve the gradient reference</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="../../../../org/newdawn/slick/svg/Gradient.html#setR(float)">setR</A></B>(float r)</CODE>
|
|
|
|
<BR>
|
|
Set the radius given in the SVG</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="../../../../org/newdawn/slick/svg/Gradient.html#setTransform(org.newdawn.slick.geom.Transform)">setTransform</A></B>(<A HREF="../../../../org/newdawn/slick/geom/Transform.html" title="class in org.newdawn.slick.geom">Transform</A> trans)</CODE>
|
|
|
|
<BR>
|
|
Set the transform given for this definition</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="../../../../org/newdawn/slick/svg/Gradient.html#setX1(float)">setX1</A></B>(float x1)</CODE>
|
|
|
|
<BR>
|
|
Set the first x value given for the gradient (cx in the case of radial)</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="../../../../org/newdawn/slick/svg/Gradient.html#setX2(float)">setX2</A></B>(float x2)</CODE>
|
|
|
|
<BR>
|
|
Set the second x value given for the gradient (fx in the case of radial)</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="../../../../org/newdawn/slick/svg/Gradient.html#setY1(float)">setY1</A></B>(float y1)</CODE>
|
|
|
|
<BR>
|
|
Set the first y value given for the gradient (cy in the case of radial)</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="../../../../org/newdawn/slick/svg/Gradient.html#setY2(float)">setY2</A></B>(float y2)</CODE>
|
|
|
|
<BR>
|
|
Set the second y value given for the gradient (fy in the case of radial)</TD>
|
|
</TR>
|
|
</TABLE>
|
|
<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
|
|
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
|
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
|
|
<TH ALIGN="left"><B>Methods inherited from class java.lang.Object</B></TH>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD><CODE>clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</CODE></TD>
|
|
</TR>
|
|
</TABLE>
|
|
|
|
<P>
|
|
|
|
<!-- ========= CONSTRUCTOR DETAIL ======== -->
|
|
|
|
<A NAME="constructor_detail"><!-- --></A>
|
|
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
|
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
|
|
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
|
|
<B>Constructor Detail</B></FONT></TH>
|
|
</TR>
|
|
</TABLE>
|
|
|
|
<A NAME="Gradient(java.lang.String, boolean)"><!-- --></A><H3>
|
|
Gradient</H3>
|
|
<PRE>
|
|
public <B>Gradient</B>(java.lang.String name,
|
|
boolean radial)</PRE>
|
|
<DL>
|
|
<DD>Create a new gradient definition
|
|
<P>
|
|
<DL>
|
|
<DT><B>Parameters:</B><DD><CODE>name</CODE> - The name of the gradient<DD><CODE>radial</CODE> - True if the gradient is radial</DL>
|
|
</DL>
|
|
|
|
<!-- ============ METHOD DETAIL ========== -->
|
|
|
|
<A NAME="method_detail"><!-- --></A>
|
|
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
|
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
|
|
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
|
|
<B>Method Detail</B></FONT></TH>
|
|
</TR>
|
|
</TABLE>
|
|
|
|
<A NAME="isRadial()"><!-- --></A><H3>
|
|
isRadial</H3>
|
|
<PRE>
|
|
public boolean <B>isRadial</B>()</PRE>
|
|
<DL>
|
|
<DD>Check if the gradient is radial
|
|
<P>
|
|
<DD><DL>
|
|
|
|
<DT><B>Returns:</B><DD>True if the gradient is radial</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="setTransform(org.newdawn.slick.geom.Transform)"><!-- --></A><H3>
|
|
setTransform</H3>
|
|
<PRE>
|
|
public void <B>setTransform</B>(<A HREF="../../../../org/newdawn/slick/geom/Transform.html" title="class in org.newdawn.slick.geom">Transform</A> trans)</PRE>
|
|
<DL>
|
|
<DD>Set the transform given for this definition
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>trans</CODE> - The transform given for this definition</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="getTransform()"><!-- --></A><H3>
|
|
getTransform</H3>
|
|
<PRE>
|
|
public <A HREF="../../../../org/newdawn/slick/geom/Transform.html" title="class in org.newdawn.slick.geom">Transform</A> <B>getTransform</B>()</PRE>
|
|
<DL>
|
|
<DD>Get the transform to apply during this gradient application
|
|
<P>
|
|
<DD><DL>
|
|
|
|
<DT><B>Returns:</B><DD>The transform given for this gradient</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="reference(java.lang.String)"><!-- --></A><H3>
|
|
reference</H3>
|
|
<PRE>
|
|
public void <B>reference</B>(java.lang.String ref)</PRE>
|
|
<DL>
|
|
<DD>Reference another gradient, i.e. use it's colour stops
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>ref</CODE> - The name of the other gradient to reference</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="resolve(org.newdawn.slick.svg.Diagram)"><!-- --></A><H3>
|
|
resolve</H3>
|
|
<PRE>
|
|
public void <B>resolve</B>(<A HREF="../../../../org/newdawn/slick/svg/Diagram.html" title="class in org.newdawn.slick.svg">Diagram</A> diagram)</PRE>
|
|
<DL>
|
|
<DD>Resolve the gradient reference
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>diagram</CODE> - The diagram to resolve against</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="genImage()"><!-- --></A><H3>
|
|
genImage</H3>
|
|
<PRE>
|
|
public void <B>genImage</B>()</PRE>
|
|
<DL>
|
|
<DD>Generate the image used for texturing the gradient across shapes
|
|
<P>
|
|
<DD><DL>
|
|
</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="getImage()"><!-- --></A><H3>
|
|
getImage</H3>
|
|
<PRE>
|
|
public <A HREF="../../../../org/newdawn/slick/Image.html" title="class in org.newdawn.slick">Image</A> <B>getImage</B>()</PRE>
|
|
<DL>
|
|
<DD>Get the image generated for this gradient
|
|
<P>
|
|
<DD><DL>
|
|
|
|
<DT><B>Returns:</B><DD>The image generated for the gradient</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="setR(float)"><!-- --></A><H3>
|
|
setR</H3>
|
|
<PRE>
|
|
public void <B>setR</B>(float r)</PRE>
|
|
<DL>
|
|
<DD>Set the radius given in the SVG
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>r</CODE> - The radius for radial gradients</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="setX1(float)"><!-- --></A><H3>
|
|
setX1</H3>
|
|
<PRE>
|
|
public void <B>setX1</B>(float x1)</PRE>
|
|
<DL>
|
|
<DD>Set the first x value given for the gradient (cx in the case of radial)
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>x1</CODE> - The first x value given for the gradient</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="setX2(float)"><!-- --></A><H3>
|
|
setX2</H3>
|
|
<PRE>
|
|
public void <B>setX2</B>(float x2)</PRE>
|
|
<DL>
|
|
<DD>Set the second x value given for the gradient (fx in the case of radial)
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>x2</CODE> - The second x value given for the gradient</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="setY1(float)"><!-- --></A><H3>
|
|
setY1</H3>
|
|
<PRE>
|
|
public void <B>setY1</B>(float y1)</PRE>
|
|
<DL>
|
|
<DD>Set the first y value given for the gradient (cy in the case of radial)
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>y1</CODE> - The first y value given for the gradient</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="setY2(float)"><!-- --></A><H3>
|
|
setY2</H3>
|
|
<PRE>
|
|
public void <B>setY2</B>(float y2)</PRE>
|
|
<DL>
|
|
<DD>Set the second y value given for the gradient (fy in the case of radial)
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>y2</CODE> - The second y value given for the gradient</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="getR()"><!-- --></A><H3>
|
|
getR</H3>
|
|
<PRE>
|
|
public float <B>getR</B>()</PRE>
|
|
<DL>
|
|
<DD>Get the radius value given for this gradient
|
|
<P>
|
|
<DD><DL>
|
|
|
|
<DT><B>Returns:</B><DD>The radius value given for this gradient</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="getX1()"><!-- --></A><H3>
|
|
getX1</H3>
|
|
<PRE>
|
|
public float <B>getX1</B>()</PRE>
|
|
<DL>
|
|
<DD>Get the first x value given for this gradient (cx in the case of radial)
|
|
<P>
|
|
<DD><DL>
|
|
|
|
<DT><B>Returns:</B><DD>The first x value given for this gradient</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="getX2()"><!-- --></A><H3>
|
|
getX2</H3>
|
|
<PRE>
|
|
public float <B>getX2</B>()</PRE>
|
|
<DL>
|
|
<DD>Get the second x value given for this gradient (fx in the case of radial)
|
|
<P>
|
|
<DD><DL>
|
|
|
|
<DT><B>Returns:</B><DD>The second x value given for this gradient</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="getY1()"><!-- --></A><H3>
|
|
getY1</H3>
|
|
<PRE>
|
|
public float <B>getY1</B>()</PRE>
|
|
<DL>
|
|
<DD>Get the first y value given for this gradient (cy in the case of radial)
|
|
<P>
|
|
<DD><DL>
|
|
|
|
<DT><B>Returns:</B><DD>The first y value given for this gradient</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="getY2()"><!-- --></A><H3>
|
|
getY2</H3>
|
|
<PRE>
|
|
public float <B>getY2</B>()</PRE>
|
|
<DL>
|
|
<DD>Get the second y value given for this gradient (fy in the case of radial)
|
|
<P>
|
|
<DD><DL>
|
|
|
|
<DT><B>Returns:</B><DD>The second y value given for this gradient</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="addStep(float, org.newdawn.slick.Color)"><!-- --></A><H3>
|
|
addStep</H3>
|
|
<PRE>
|
|
public void <B>addStep</B>(float location,
|
|
<A HREF="../../../../org/newdawn/slick/Color.html" title="class in org.newdawn.slick">Color</A> c)</PRE>
|
|
<DL>
|
|
<DD>Add a colour step/stop to the gradient
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>location</CODE> - The location on the gradient the colour affects<DD><CODE>c</CODE> - The color to apply</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="getColorAt(float)"><!-- --></A><H3>
|
|
getColorAt</H3>
|
|
<PRE>
|
|
public <A HREF="../../../../org/newdawn/slick/Color.html" title="class in org.newdawn.slick">Color</A> <B>getColorAt</B>(float p)</PRE>
|
|
<DL>
|
|
<DD>Get the intepolated colour at the given location on the gradient
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>p</CODE> - The point of the gradient (0 >= n >= 1)
|
|
<DT><B>Returns:</B><DD>The interpolated colour at the given location</DL>
|
|
</DD>
|
|
</DL>
|
|
<!-- ========= END OF CLASS DATA ========= -->
|
|
<HR>
|
|
|
|
|
|
<!-- ======= START OF BOTTOM NAVBAR ====== -->
|
|
<A NAME="navbar_bottom"><!-- --></A>
|
|
<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
|
|
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
|
|
<TR>
|
|
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
|
|
<A NAME="navbar_bottom_firstrow"><!-- --></A>
|
|
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
|
|
<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/Gradient.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-all.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>
|
|
</TD>
|
|
</TR>
|
|
|
|
<TR>
|
|
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
|
|
<A HREF="../../../../org/newdawn/slick/svg/Figure.html" title="class in org.newdawn.slick.svg"><B>PREV CLASS</B></A>
|
|
<A HREF="../../../../org/newdawn/slick/svg/InkscapeLoader.html" title="class in org.newdawn.slick.svg"><B>NEXT CLASS</B></A></FONT></TD>
|
|
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
|
|
<A HREF="../../../../index.html?org/newdawn/slick/svg/Gradient.html" target="_top"><B>FRAMES</B></A>
|
|
<A HREF="Gradient.html" target="_top"><B>NO FRAMES</B></A>
|
|
<SCRIPT type="text/javascript">
|
|
<!--
|
|
if(window==top) {
|
|
document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
|
|
}
|
|
//-->
|
|
</SCRIPT>
|
|
<NOSCRIPT>
|
|
<A HREF="../../../../allclasses-noframe.html"><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>
|
|
<A NAME="skip-navbar_bottom"></A>
|
|
<!-- ======== END OF BOTTOM NAVBAR ======= -->
|
|
|
|
<HR>
|
|
<i>Copyright © 2006 New Dawn Software. All Rights Reserved.</i>
|
|
</BODY>
|
|
</HTML>
|