multiimage using a diffuse texture, does not fade nicely
#1
PHP Code:
<!-- Fanart multiimage -->
            <
control type="multiimage">
                <
description>fanart multiimage</description>
                <
posx>50</posx>
                <
posy>50</posy>
                <
width>630</width>
                <
height>445</height>
                <
imagepath diffuse="twc-fanart-diffuse.png">$INFO[Skin.String(twc-fanart-path)]/$INFO[Weather.Location]</imagepath>
                <
timeperimage>2000</timeperimage>
                <
pauseatend>0</pauseatend>
                <
fadetime>500</fadetime>
                <
randomize>true</randomize>
                <
loop>yes</loop>
                <
aspectratio>stretch</aspectratio>
            </
control

that is the control i'm using, it all works, but the fade flashes. is this unavoidable with a multiimage or is there something i've messed up.

i can supply a sample script if need be.
For python coding questions first see http://mirrors.xbmc.org/docs/python-docs/
Reply
#2
If the diffuse image contains transparency, then yes. The problem is that to cross fade between two images you have to actually render the previous image first, then put the next one on top. As it is at the moment, it will cause a flash when the bottom image then disappears (which would normally be completely hidden behind the front one), as the top image is partially transparent due to the diffuse image.

We *may* be able to workaround it by allowing the skinner to specify a base transparency so that we can apply the alternate fade function we use when the images have an alpha fade on them. This then uses a fading technique that takes into account the fact that both images are a bit transparent.

See CGUIMultiImage::Render() for the code - we'd have to specify m_diffuseColor separately (without it actually applying to the image).

Cheers,
Jonathan
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#3
let me clarify.

jmarshall, you fixed the fading of multiimages when the images were partially transparent. the diffuse texture is a 35% texture, so is there anyway for you to take the diffuse texture into account when transforming?
For python coding questions first see http://mirrors.xbmc.org/docs/python-docs/
Reply
#4
Smile
For python coding questions first see http://mirrors.xbmc.org/docs/python-docs/
Reply
#5
<colordiffuse> fades nicely, but doesn't clip, so i did a full opacity diffuse texture and the <colordiffuse> and it works perfect, so probably no need to change anything.

thanks.
For python coding questions first see http://mirrors.xbmc.org/docs/python-docs/
Reply
#6
Smile i was going to request <colordiffuse> accept an infolabel, so users could set the fade, but it already works.
For python coding questions first see http://mirrors.xbmc.org/docs/python-docs/
Reply
#7
yes, you guessed it. feature request. all control settings run thru $INFO[] so i could have fadetime and timesperimage user selectable. Smile
For python coding questions first see http://mirrors.xbmc.org/docs/python-docs/
Reply
#8
Not without knowing the number in advance. If you know it's 35% or whatever, then yes it's possible, but we'd have to add an additional tag to the multiimage control first.

EDIT: Ignore this Smile
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply

Logout Mark Read Team Forum Stats Members Help
multiimage using a diffuse texture, does not fade nicely1