Class TextureBitmap
java.lang.Object
eu.svjatoslav.sixth.e3d.renderer.raster.texture.TextureBitmap
-
Field Summary
Modifier and TypeFieldDescriptionfinal byte[]
Byte order: Alpha, Blue, Green, Redfinal int
double
final int
-
Constructor Summary
ConstructorDescriptionTextureBitmap
(int width, int height, byte[] bytes, double multiplicationFactor) TextureBitmap
(int width, int height, double multiplicationFactor) -
Method Summary
Modifier and TypeMethodDescriptionvoid
drawPixel
(int sourceBitmapPixelAddress, byte[] targetBitmap, int targetBitmapPixelAddress) Transfer (render) one pixel from currentTextureBitmap
to target raster bitmap.void
void
drawRectangle
(int x1, int y1, int x2, int y2, Color color) void
int
getAddress
(int x, int y)
-
Field Details
-
bytes
public final byte[] bytesByte order: Alpha, Blue, Green, Red -
width
public final int width -
height
public final int height -
multiplicationFactor
public double multiplicationFactor
-
-
Constructor Details
-
TextureBitmap
public TextureBitmap(int width, int height, byte[] bytes, double multiplicationFactor) -
TextureBitmap
public TextureBitmap(int width, int height, double multiplicationFactor)
-
-
Method Details
-
drawPixel
public void drawPixel(int sourceBitmapPixelAddress, byte[] targetBitmap, int targetBitmapPixelAddress) Transfer (render) one pixel from currentTextureBitmap
to target raster bitmap.- Parameters:
sourceBitmapPixelAddress
- Pixel address within currentTextureBitmap
as indicated by its offset.targetBitmap
- Bitmap of the target image where pixel should be rendered to.targetBitmapPixelAddress
- Pixel location within target image where pixel should be rendered to.
-
drawPixel
-
drawRectangle
-
fillColor
-
getAddress
public int getAddress(int x, int y)
-