Slider Shadow Area w/ AlfiskoSkin Not Updating

For help with general CEGUI usage:
- Questions about the usage of CEGUI and its features, if not explained in the documentation.
- Problems with the CMAKE configuration or problems occuring during the build process/compilation.
- Errors or unexpected behaviour.

Moderators: CEGUI MVP, CEGUI Team

Oam
Not too shy to talk
Not too shy to talk
Posts: 23
Joined: Thu Nov 13, 2014 07:01

Slider Shadow Area w/ AlfiskoSkin Not Updating

Postby Oam » Fri Mar 20, 2015 06:23

Hello,

I am using CEGUI 0.8.4.

I'm currently in the process of getting some of my various options menu stuff in. When I click my Slider and then change it's position, the shadow that surrounds the actual scrollable slider on the left and right don't update until I click another CEGUI::Window within my layout. Is there a way to manually tell the slider to keep updating as the Slider is being moved? I tried adding a : CEGUI::Slider::EventValueChanged event and then call the update / activate / .. functions to see if that would solve the problem, but that didn't do it. I also set the UpdateMode to be Always updating, that also did not solve the problem.

Thank you for any insight.

- Oam

lucebac
Just can't stay away
Just can't stay away
Posts: 193
Joined: Sat May 24, 2014 21:55

Re: Slider Shadow Area w/ AlfiskoSkin Not Updating

Postby lucebac » Fri Mar 20, 2015 09:51

I think you need to make this call:

Code: Select all

window.setAutoRenderingSurface(true);

Oam
Not too shy to talk
Not too shy to talk
Posts: 23
Joined: Thu Nov 13, 2014 07:01

Re: Slider Shadow Area w/ AlfiskoSkin Not Updating

Postby Oam » Fri Mar 20, 2015 11:00

Unfortunately that didn't solve the problem, thank you for the suggestion tho.

This is the problem in image format : http://i.imgur.com/MaGxMzV.png

The top slider is before the movement, the bottom is after the movement. The shadow area doesn't update until after I click inside another CEGUI::Window* component.

User avatar
Ident
CEGUI Team
Posts: 1998
Joined: Sat Oct 31, 2009 13:57
Location: Austria

Re: Slider Shadow Area w/ AlfiskoSkin Not Updating

Postby Ident » Fri Mar 20, 2015 11:18

Thanks for your report and screenshot. So if you click on another window then the 2nd image looks more like the first (but with another slider position of course) ?

Can you try to use another look's slider, so from another LNF, such as taharez, and see if you get the same issue? If you do not then we can be certain the issue lies in the LNF.

Thank you.
CrazyEddie: "I don't like GUIs"

Oam
Not too shy to talk
Not too shy to talk
Posts: 23
Joined: Thu Nov 13, 2014 07:01

Re: Slider Shadow Area w/ AlfiskoSkin Not Updating

Postby Oam » Fri Mar 20, 2015 22:54

That is correct. Everything does work normally, but the HorzSliderShadowL and HorzSliderShadowR within the AlfiskoSkin.imageset doesn't update with the slider until after I click into a different CEGUI::Window. The Taharez look and feel also works, but doesn't have the HorzSliderShadowL or HorzSliderShadowR that the AlfiskoSkin has. I would really like to get those shadow pieces for the AlfiskoSkin scrolling with the slider as it is intended to. It adds a really awesome effect around the slider.

User avatar
Ident
CEGUI Team
Posts: 1998
Joined: Sat Oct 31, 2009 13:57
Location: Austria

Re: Slider Shadow Area w/ AlfiskoSkin Not Updating

Postby Ident » Fri Mar 20, 2015 23:02

I understand the issue better now. I am not sure if the Falagard Slider class allows rendering this the way you describe it should be rendered. TaharezLook is ancient, Alfisko is quite new. It might simply be that this feature that you look for was intended in the design of AlfiskoSkin but it is not supported at the moment on the technical side (until someon adds it of course). I would ask you to open a ticket on the issue tracker: https://bitbucket.org/cegui/cegui/issue ... tatus=open

Unfortunately I do not know more than what I told you because I never worked with Slider LookNFeels and have no experience with AlfiskoSkin. I could therefore be wrong. Maybe someone else can help you, but issuing a ticket is definitely a good idea at this point in any way.
CrazyEddie: "I don't like GUIs"

Oam
Not too shy to talk
Not too shy to talk
Posts: 23
Joined: Thu Nov 13, 2014 07:01

Re: Slider Shadow Area w/ AlfiskoSkin Not Updating

Postby Oam » Fri Mar 20, 2015 23:19

Do you know if there is a way to collect the positional information of the AlfiskoSkin slider pieces? The HorzSliderShadowL, and HorzSliderShadowR and manually move them in relation to the position of the HorzSliderThumb? I'm not too sure how to do that.

AlfiskoSkin.looknfeel :

Code: Select all

<WidgetLook name="AlfiskoSkin/HorizontalSlider">
        <Property name="MouseAutoRepeatEnabled" value="true"/>
        <Property name="WantsMultiClickEvents" value="false"/>
        <Property name="Size" value="{{0, 256}, {0, 32}}" />
        <NamedArea name="ThumbTrackArea"/>
        <Child nameSuffix="__auto_thumb__" type="AlfiskoSkin/HorizontalSliderThumb">
            <Area>
                <Dim type="LeftEdge">
                    <AbsoluteDim value="0"/>
                </Dim>
                <Dim type="TopEdge">
                    <AbsoluteDim value="0"/>
                </Dim>
                <Dim type="Width">
                    <ImageDim name="AlfiskoSkin/HorzSliderThumbNormal" dimension="Width"/>
                </Dim>
                <Dim type="Height">
                    <ImageDim name="AlfiskoSkin/HorzSliderThumbNormal" dimension="Height"/>
                </Dim>
            </Area>
            <VertAlignment type="CentreAligned"/>
        </Child>
        <ImagerySection name="track">
            <ImageryComponent>
                <Image name="AlfiskoSkin/HorzSliderTrackL"/>
                <VertFormat type="CentreAligned"/>
            </ImageryComponent>
            <ImageryComponent>
                <Image name="AlfiskoSkin/HorzSliderTrackR"/>
                <VertFormat type="CentreAligned"/>
                <HorzFormat type="RightAligned"/>
            </ImageryComponent>
            <ImageryComponent>
                <Area>
                    <Dim type="LeftEdge">
                        <ImageDim name="AlfiskoSkin/HorzSliderTrackL" dimension="Width"/>
                    </Dim>
                    <Dim type="RightEdge">
                        <OperatorDim op="Subtract">
                            <UnifiedDim scale="1" type="Width"/>
                            <ImageDim name="AlfiskoSkin/HorzSliderTrackR" dimension="Width"/>
                        </OperatorDim>
                    </Dim>
                </Area>
                <Image name="AlfiskoSkin/HorzSliderTrackFill"/>
                <VertFormat type="CentreAligned"/>
                <HorzFormat type="Stretched"/>
            </ImageryComponent>
            <ImageryComponent>
                <Area>
                    <Dim type="RightEdge">
                        <WidgetDim widget="__auto_thumb__" dimension="LeftEdge"/>
                    </Dim>
                </Area>
                <Image name="AlfiskoSkin/HorzSliderShadowL"/>
                <VertFormat type="CentreAligned"/>
                <HorzFormat type="RightAligned"/>
            </ImageryComponent>
            <ImageryComponent>
                <Area>
                    <Dim type="LeftEdge">
                        <WidgetDim widget="__auto_thumb__" dimension="RightEdge"/>
                    </Dim>
                </Area>
                <Image name="AlfiskoSkin/HorzSliderShadowR"/>
                <VertFormat type="CentreAligned"/>
            </ImageryComponent>
        </ImagerySection>
        <StateImagery name="Enabled">
            <Layer>
                <Section section="track"/>
            </Layer>
        </StateImagery>
        <StateImagery name="Disabled">
            <Layer>
                <Section section="track"/>
            </Layer>
        </StateImagery>
    </WidgetLook>


Possibly something to do with the : widget="__auto_thumb__" field within the <ImagerySection name="track"> area. I'm not entirely sure.

User avatar
Ident
CEGUI Team
Posts: 1998
Joined: Sat Oct 31, 2009 13:57
Location: Austria

Re: Slider Shadow Area w/ AlfiskoSkin Not Updating

Postby Ident » Fri Mar 20, 2015 23:34

Okay now you made me curious. I will open the LNF and play with it a bit, since I already gained some experience with the Falagard system in the past.

This thing is quite buggy. This "darkening area" often for example completly covers the imagery on the ends (these circles). Clearly there has to be 4 layers:
1. the background for the track ofthe slider
2. the shadow of the slider
3. the slider
4. the circles at the ends
and finally a separate widget on top being
5. the thumb

Also the updating is wrong as you say. I m looking into it.
CrazyEddie: "I don't like GUIs"

Oam
Not too shy to talk
Not too shy to talk
Posts: 23
Joined: Thu Nov 13, 2014 07:01

Re: Slider Shadow Area w/ AlfiskoSkin Not Updating

Postby Oam » Sat Mar 21, 2015 00:07

That is interesting, I look forward to hearing about what you discover.

User avatar
Ident
CEGUI Team
Posts: 1998
Joined: Sat Oct 31, 2009 13:57
Location: Austria

Re: Slider Shadow Area w/ AlfiskoSkin Not Updating

Postby Ident » Sat Mar 21, 2015 01:40

The order (top-drawn stuff last) fixes the "ends" being on top. However they still need to be cropped or the area around them will still be black.

Regarding the updating, this might need to be changed in C++ code. More testing is needed. I have a very busy weekend and I m on holidays for a week after that so i dont know if i will get to it. Please make a ticket and link this thread
CrazyEddie: "I don't like GUIs"

User avatar
Ident
CEGUI Team
Posts: 1998
Joined: Sat Oct 31, 2009 13:57
Location: Austria

Re: Slider Shadow Area w/ AlfiskoSkin Not Updating

Postby Ident » Sat Mar 21, 2015 14:24

I think the idea behind the updating was that slider thumb changes do not require a full slider window draw refresh, because only the thumb itself is changed which is a separate window. And this works everywhere where the thumb has no influence on the drawing (e.g. if there is no shadow). This can only be solved by changing the renderer class of the widget and that should actually be done in my opinion. I will see if the fix is easy.

Regarding the cropping: I do not yet know how to go on about this. I have to look into it.
CrazyEddie: "I don't like GUIs"


Return to “Help”

Who is online

Users browsing this forum: No registered users and 14 guests