mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2025-01-17 22:55:38 +00:00
Fixed ImageComponent not using mColorShift's transparency.
Fixes using transparency in <color> tag. Updated documentation to emphasize the fact that you can control transparency with the <color> tag.
This commit is contained in:
parent
7ba1bce133
commit
6cf6e62b85
|
@ -400,7 +400,7 @@ Can be created as an extra.
|
||||||
* `tile` - type: BOOLEAN.
|
* `tile` - type: BOOLEAN.
|
||||||
- If true, the image will be tiled instead of stretched to fit its size. Useful for backgrounds.
|
- If true, the image will be tiled instead of stretched to fit its size. Useful for backgrounds.
|
||||||
* `color` - type: COLOR.
|
* `color` - type: COLOR.
|
||||||
- Multiply each pixel's color by this color. For example, an all-white image with `<color>FF0000</color>` would become completely red.
|
- Multiply each pixel's color by this color. For example, an all-white image with `<color>FF0000</color>` would become completely red. You can also control the transparency of an image with `<color>FFFFFFAA</color>` - keeping all the pixels their normal color and only affecting the alpha channel.
|
||||||
|
|
||||||
#### text
|
#### text
|
||||||
|
|
||||||
|
|
|
@ -232,7 +232,7 @@ void ImageComponent::updateVertices()
|
||||||
|
|
||||||
void ImageComponent::updateColors()
|
void ImageComponent::updateColors()
|
||||||
{
|
{
|
||||||
Renderer::buildGLColorArray(mColors, (mColorShift >> 8 << 8)| (getOpacity()), 6);
|
Renderer::buildGLColorArray(mColors, mColorShift, 6);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ImageComponent::render(const Eigen::Affine3f& parentTrans)
|
void ImageComponent::render(const Eigen::Affine3f& parentTrans)
|
||||||
|
|
Loading…
Reference in a new issue