OSDN Git Service

Javadocs.
authorNathanSweet <nathan.sweet@gmail.com>
Wed, 11 Sep 2013 17:24:17 +0000 (19:24 +0200)
committerNathanSweet <nathan.sweet@gmail.com>
Wed, 11 Sep 2013 17:24:17 +0000 (19:24 +0200)
gdx/src/com/badlogic/gdx/graphics/g2d/PolygonRegion.java
gdx/src/com/badlogic/gdx/graphics/g2d/PolygonSpriteBatch.java

index 516c2ba..4b78454 100644 (file)
 package com.badlogic.gdx.graphics.g2d;\r
 \r
 /** Defines a polygon shape on top of a texture region to avoid drawing transparent pixels.\r
- * \r
+ * <p>\r
  * THIS STUFF IS A WIP\r
- * \r
+ * <p>\r
  * @see PolygonRegionLoader\r
- * \r
  * @author Stefan Bachmann\r
  * @author Nathan Sweet */\r
 public class PolygonRegion {\r
index 6d6c7b0..b9dc9da 100644 (file)
@@ -33,44 +33,29 @@ import com.badlogic.gdx.math.Matrix4;
 import com.badlogic.gdx.utils.NumberUtils;\r
 \r
 /** <p>\r
- * A PolyongSpriteBatch is used to draw 2D polygons that reference a texture (region). The class will batch the drawing commands\r
+ * A PolygonSpriteBatch is used to draw 2D polygons that reference a texture (region). The class will batch the drawing commands\r
  * and optimize them for processing by the GPU.\r
- * </p>\r
- * \r
+ * <p>\r
  * THIS STUFF IS WIP\r
- * \r
  * <p>\r
- * To draw something with a PolyongSpriteBatch one has to first call the {@link PolygonSpriteBatch#begin()} method which will\r
+ * To draw something with a PolygonSpriteBatch one has to first call the {@link PolygonSpriteBatch#begin()} method which will\r
  * setup appropriate render states. When you are done with drawing you have to call {@link PolygonSpriteBatch#end()} which will\r
  * actually draw the things you specified.\r
- * </p>\r
- * \r
  * <p>\r
- * All drawing commands of the PolyongSpriteBatch operate in screen coordinates. The screen coordinate system has an x-axis\r
+ * All drawing commands of the PolygonSpriteBatch operate in screen coordinates. The screen coordinate system has an x-axis\r
  * pointing to the right, an y-axis pointing upwards and the origin is in the lower left corner of the screen. You can also\r
  * provide your own transformation and projection matrices if you so wish.\r
- * </p>\r
- * \r
  * <p>\r
- * A PolyongSpriteBatch is managed. In case the OpenGL context is lost all OpenGL resources a PolyongSpriteBatch uses internally\r
+ * A PolygonSpriteBatch is managed. In case the OpenGL context is lost all OpenGL resources a PolygonSpriteBatch uses internally\r
  * get invalidated. A context is lost when a user switches to another application or receives an incoming call on Android. A\r
- * SpritPolyongSpriteBatcheBatch will be automatically reloaded after the OpenGL context is restored.\r
- * </p>\r
- * \r
+ * SpritPolygonSpriteBatcheBatch will be automatically reloaded after the OpenGL context is restored.\r
  * <p>\r
- * A PolyongSpriteBatch is a pretty heavy object so you should only ever have one in your program.\r
- * </p>\r
- * \r
+ * A PolygonSpriteBatch is a pretty heavy object so you should only ever have one in your program.\r
  * <p>\r
- * A PolyongSpriteBatch works with OpenGL ES 1.x and 2.0. In the case of a 2.0 context it will use its own custom shader to draw\r
+ * A PolygonSpriteBatch works with OpenGL ES 1.x and 2.0. In the case of a 2.0 context it will use its own custom shader to draw\r
  * all provided sprites. You can set your own custom shader via {@link #setShader(ShaderProgram)}.\r
- * </p>\r
- * \r
  * <p>\r
- * A PolyongSpriteBatch has to be disposed if it is no longer used.\r
- * </p>\r
- * \r
- * \r
+ * A PolygonSpriteBatch has to be disposed if it is no longer used.\r
  * @author mzechner\r
  * @author Stefan Bachmann\r
  * @author Nathan Sweet */\r
@@ -122,21 +107,14 @@ public class PolygonSpriteBatch {
                this(size, null);\r
        }\r
 \r
-       /** <p>\r
-        * Constructs a new PolygonSpriteBatch. Sets the projection matrix to an orthographic projection with y-axis point upwards,\r
+       /** Constructs a new PolygonSpriteBatch. Sets the projection matrix to an orthographic projection with y-axis point upwards,\r
         * x-axis point to the right and the origin being in the bottom left corner of the screen. The projection will be pixel perfect\r
         * with respect to the screen resolution.\r
-        * </p>\r
-        * \r
         * <p>\r
         * The size parameter specifies the maximum size of a single batch in number of vertices(!)\r
-        * </p>\r
-        * \r
         * <p>\r
         * The defaultShader specifies the shader to use. Note that the names for uniforms for this default shader are different than\r
         * the ones expect for shaders set with {@link #setShader(ShaderProgram)}. See the {@link #createDefaultShader()} method.\r
-        * </p>\r
-        * \r
         * @param size the batch size in number of vertices(!)\r
         * @param defaultShader the default shader to use. This is not owned by the SpriteBatch and must be disposed separately. */\r
        public PolygonSpriteBatch (int size, ShaderProgram defaultShader) {\r
@@ -149,21 +127,14 @@ public class PolygonSpriteBatch {
                this(size, buffers, null);\r
        }\r
 \r
-       /** <p>\r
-        * Constructs a new PolygonSpriteBatch. Sets the projection matrix to an orthographic projection with y-axis point upwards,\r
+       /** Constructs a new PolygonSpriteBatch. Sets the projection matrix to an orthographic projection with y-axis point upwards,\r
         * x-axis point to the right and the origin being in the bottom left corner of the screen. The projection will be pixel perfect\r
         * with respect to the screen resolution.\r
-        * </p>\r
-        * \r
         * <p>\r
         * The size parameter specifies the maximum size of a single batch in number of vertices(!)\r
-        * </p>\r
-        * \r
         * <p>\r
         * The defaultShader specifies the shader to use. Note that the names for uniforms for this default shader are different than\r
         * the ones expect for shaders set with {@link #setShader(ShaderProgram)}. See the {@link #createDefaultShader()} method.\r
-        * </p>\r
-        * \r
         * @param size the batch size in number of vertices(!)\r
         * @param buffers the number of buffers to use. only makes sense with VBOs. This is an expert function.\r
         * @param defaultShader the default shader to use. This is not owned by the SpriteBatch and must be disposed separately. */\r
@@ -586,13 +557,12 @@ public class PolygonSpriteBatch {
         * which gets "0" appened to indicate the use of the first texture unit. The projection matrix is uploaded via a mat4 uniform\r
         * called "u_proj", the transform matrix is uploaded via a uniform called "u_trans", the combined transform and projection\r
         * matrx is is uploaded via a mat4 uniform called "u_projTrans". The texture sampler is passed via a uniform called\r
-        * "u_texture".</p>\r
-        * \r
-        * Call this method with a null argument to use the default shader.</p>\r
-        * \r
+        * "u_texture".\r
+        * <p>\r
+        * Call this method with a null argument to use the default shader.\r
+        * <p>\r
         * This method will flush the batch before setting the new shader, you can call it in between {@link #begin()} and\r
         * {@link #end()}.\r
-        * \r
         * @param shader the {@link ShaderProgram} or null to use the default shader. */\r
        public void setShader (ShaderProgram shader) {\r
                if (drawing) {\r