Uses of Class
org.xjge.graphics.Color
| Package | Description |
|---|---|
| org.xjge.core |
Contains various classes, objects, and utilities many of which are essential
to the function of the engine.
|
| org.xjge.graphics |
Supplies abstractions of OpenGL into various objects and data structures to
be used by other parts of the engine.
|
-
Uses of Color in org.xjge.core
Fields in org.xjge.core declared as Color Modifier and Type Field Description ColorLight. ambientColorColorLight. diffuseColorColorLight. specularColorMethods in org.xjge.core with parameters of type Color Modifier and Type Method Description protected voidWidget. drawString(Font font, java.lang.String text, org.joml.Vector2i position, Color color)Draws a string of text to the screen.static voidGame. setClearColor(Color color)Changes the color OpenGL will use to clear color buffers.protected voidTerminalCommand. setOutput(java.lang.String text, Color color)Provides a response to the user upon executing a command.Constructors in org.xjge.core with parameters of type Color Constructor Description Light(float brightness, float contrast, float distance, org.joml.Vector3f position, Color color)Variant ofLight(float,float,float,org.joml.Vector3f,org.xjge.graphics.Color,org.xjge.graphics.Color,org.xjge.graphics.Color)that will initialize each color used in the Phong lighting model to the same value.Light(float brightness, float contrast, float distance, org.joml.Vector3f position, Color ambientColor, Color diffuseColor, Color specularColor)Creates a new light object that contains data which can be used by a fragment shader during lighting calculations. -
Uses of Color in org.xjge.graphics
Fields in org.xjge.graphics declared as Color Modifier and Type Field Description static ColorColor. BLACKstatic ColorColor. BLUEstatic ColorColor. BROWNColorIcon. colorColorModel. colorColorPolygon. colorstatic ColorColor. CYANstatic ColorColor. GRAYstatic ColorColor. GREENstatic ColorColor. LIMEstatic ColorColor. MAGENTAstatic ColorColor. ORANGEstatic ColorColor. PINKstatic ColorColor. PURPLEstatic ColorColor. REDstatic ColorColor. SILVERstatic ColorColor. TEALstatic ColorColor. WHITEstatic ColorColor. YELLOWMethods in org.xjge.graphics that return Color Modifier and Type Method Description static ColorColor. create(int r, int g, int b)Creates a new color object using the values of the three RGB components supplied.static ColorColor. random()Creates a random color.Methods in org.xjge.graphics with parameters of type Color Modifier and Type Method Description booleanColor. compareTo(Color other)Compares the RGB component values of this color to another.voidRectangleBatch. drawRectangle(int x, int y, int width, int height, Color color)Draws a rectangle using the data provided.voidRectangleBatch. drawRectangle(org.joml.Vector2i pos, int width, int height, Color color)Draws a rectangle using the data provided.voidRectangleBatch. drawRectangle(Rectangle rectangle, Color color)Draws a rectangle using the data provided.voidRectangle. render(float opacity, Color color)A quick and dirty way to render a rectangle with little overhead.Constructors in org.xjge.graphics with parameters of type Color Constructor Description Polygon(int numSides, boolean fill, float radius, Color color, int xPos, int yPos)Creates a new n-sided polygon object which can be used to represent regular shapes and circles.Polygon(int numSides, boolean fill, float radius, Color color, org.joml.Vector2i position)Alternate version of thePolygon()constructor.