Cool VL Viewer forum

View unanswered posts | View active topics It is currently 2024-04-19 06:09:52



Reply to topic  [ 5 posts ] 
Avatar "Hover" not reflected properly 
Author Message

Joined: 2010-04-07 08:23:18
Posts: 210
Reply with quote
Hello Henri, hi everyone,

I'll be bold and put this in the "bug" category. I am sure Henri will chastize me properly if it is something I did, but at the moment I don't see a reason to feel guilty.

The issue that I have been observing is that the amount of hover displayed for avatars in Cool VL Viewer does not match the amount displayed in the official viewer. From what I have seen, avatars are always rendered further above ground in the Cool VL Viewer. This sometimes leads to my adjusting the hover downwards too far, which then looks fine for me, but people with the official viewer (and possibly others, I presume) see my feet/shoes sunk into the floor. Someone else with Cool VL Viewer will see the same hover as I do, so I presume it's something about the local interpretation of these values.

I have attached some sample pictures to illustrate it. I used a static pose, adjusted the "Z-Offset" in my viewer until the soles hit the ground (in this case -0.10) and then took screenshots in 'my' viewer, another instance of the same version Cool VL Viewer with my script testing alt logged on, and once again with the latest official viewer with that alt logged on.

Attachment:
File comment: Example Pictures
HoverProblemLo.jpg [49.14 KiB]
Not downloaded yet


Could you possibly check into that sometime please, Henri? And maybe there's others who can comment on this and provide more insight.

Love,
Lia


2013-08-27 18:45:33
Profile

Joined: 2009-03-17 18:42:51
Posts: 5546
Reply with quote
This is actually a bug in LL's viewer... The hover parameter is accounted twice: once by the physics engine which sends an adjusted render position back to the viewer, position which already accounts for the hover parameter, and another time, erroneously, in LLVOAvatar::updateCharacter(), where the hover parameter is again added to the render position which was already accounting for it !...

You can see this bug in action in LL's viewer by editing your avatar shape: changing the offset immediately changes the avatar position on your screen (it should not, but it does because the buggy code in LLVOAvatar::updateCharacter() immediately changes the avatar position on your screen), and once you save the shape, you will see your avatar sink again (or raise again, depending whether you decreased or increased the Hover param below or above 50) by the same amount (this time, it's normal, since it's the effect of the physics engine taking into account what the "oven" told it to use as the Hover parameter and changing the avatar's render position accordingly), thus doubling the effect of the Hover parameter !

The Cool VL Viewer doesn't suffer from this bug, because when I ported the code I immediately rejected this silly code line which messes everything up in LLVOAvatar::updateCharacter()...

Now, I must find a way to work around this bug till LL fixes their viewer (I'll also have to discuss this with Nyx Linden and/or open a JIRA for this bug...). The good news is that it should be enough to add the buggy line and divide the Z offset by two before applying it to the shape as the Hover parameter to work around the issue... I'll work on that tomorrow, because it's largely past bed time for me now.


2013-08-28 00:53:38
Profile WWW

Joined: 2009-03-17 18:42:51
Posts: 5546
Reply with quote
Got the work around implemented and working... It's however just a work around and the true fix will be to disable it when LL will get their viewer code straight !!!


2013-08-28 11:56:02
Profile WWW

Joined: 2010-04-07 08:23:18
Posts: 210
Reply with quote
Hello again Henri,

thank you so much for looking into this. For a while there I thought I was going crazy when friends told me I was either hovering far in the air or stuck with my feet in the ground, when everything looked alright to me. :shock:

Henri Beauchamp wrote:
This is actually a bug in LL's viewer... The hover parameter is accounted twice: once by the physics engine which sends an adjusted render position back to the viewer, position which already accounts for the hover parameter, and another time, erroneously, in LLVOAvatar::updateCharacter(), where the hover parameter is again added to the render position which was already accounting for it !...
Duh. So for the time being I could roughly halve the value that makes things look ok to me and it is likely to look sane to others. Unless they're smart and use the Cool VL Viewer as well ... :lol:

Henri Beauchamp wrote:
You can see this bug in action in LL's viewer by editing your avatar shape: [...]
Naaaah, I believe you. I dread starting the Linden viewer, so I'm keeping that to a minimum. 8-)

Henri Beauchamp wrote:
Got the work around implemented and working... It's however just a work around and the true fix will be to disable it when LL will get their viewer code straight !!!
Oh my, you're spoiling us by coming up with a solution so quickly! :o

Once again, thank you for all the excellent work that you do!

Love,
Lia


2013-08-28 17:12:18
Profile

Joined: 2009-03-17 18:42:51
Posts: 5546
Reply with quote
In fact, the multiplication factor to apply to work around that bug is even slightly more than 2... From my testing sessions, to obtain the same result as in former non-SSB sims, that factor must be around 2.25; that's because the Hover parameter is also added to the avatar height, and the pelvis offset above the ground is further adjusted server-side depending on this total height by the physics engine...

The implementation of the work-around in today's releases therefore involves a new debug variable ("HoverToZOffsetFactor"), which defaults to 2.25. Setting this variable to 1.0 or less disables the work around (for when/if LL's gets their viewer fixed...).


2013-08-31 13:39:30
Profile WWW
Display posts from previous:  Sort by  
Reply to topic   [ 5 posts ] 

Who is online

Users browsing this forum: No registered users and 56 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group
Designed by ST Software.