Graphics

 View Only
Expand all | Collapse all

Live sorting of a standings-table

  • 1.  Live sorting of a standings-table

    Posted 01-09-2025 09:27

    Hey hey,

    I was wondering if anyone here knows what it would take to create a scoreboard where the standings move depending on what the data changed to. So for example I have a excel sheet with points assinged to different teams, the table sorts itself automatically depending on what team has the most points. I would like the graphics to represent that but rather have the new order just pop into existence I'd like for the teams to actually move/animate into the new position. So basically imagine the Formula1 sidebar with the positions of the cars on the track and one of the drivers gets overtaken. The new order doesn't just plopp in, but the positions actually swap. F1 Excample when Kvyat goes from 12th place to 2nd

    YouTube remove preview
    F1 2019 TV Coverage - Bahrain - 2160p 4K 50fps (29.0 Mb/s bit rate) Footage (Channel 4 Commentary)
    As per request this is the 4k bahrain footage with channel 4 commentary dubbed over Format : MPEG-TS File size : 10.7 GiB Duration : 52 min 9 s Overall bit rate mode : Variable Overall bit rate : 29.3 Mb/s Video ID : 1535 (0x5FF) Menu ID : 553
    View this on YouTube >

    Also handy to know that while I'm doing rather ok with VL, I have very little experience with VB.



    ------------------------------
    Johannes Pedri
    Berlin Germany
    ------------------------------


  • 2.  RE: Live sorting of a standings-table

    Posted 01-09-2025 09:33

    It requires scripting as you need to update the keyframe values with the items current position and tell it where its new position needs to be and then move it. accordingly. 

    At the same time you must move all other items to their new respective positions. 

    So every time the data changes you must re-evaluate every position, it's quite a complex graphic. 



    ------------------------------
    Simon Redmile
    Senior Graphic Programmer & Designer
    Ross Video
    Bristol United Kingdom
    ------------------------------



  • 3.  RE: Live sorting of a standings-table

    Posted 01-09-2025 09:49
    Hi Simon 
    Can you send this script? 





  • 4.  RE: Live sorting of a standings-table

    Posted 01-09-2025 09:52

    I would need to write it first as I don't seem to have any saved examples, I am working on a project with a pressing deadline at the moment.

    I will try to write something when I am done with project unless someone beats me to it. 



    ------------------------------
    Simon Redmile
    Senior Graphic Programmer & Designer
    Ross Video
    Bristol United Kingdom
    ------------------------------



  • 5.  RE: Live sorting of a standings-table

    Posted 01-09-2025 10:02

    That would be amazing, even if my deadline for this won't allow me to use it, it will definitly come in handy at some point and I get to learn something new.



    ------------------------------
    Thanks for taking the time reading,
    Johannes
    ------------------------------



  • 6.  RE: Live sorting of a standings-table

    Posted 01-09-2025 10:03
    Sure take your time thanks dear





  • 7.  RE: Live sorting of a standings-table

    Posted 01-09-2025 09:50

    I expected it to be complicated so no surprises there. Thank you for the answer anyways.



    ------------------------------
    Thanks for taking the time reading,
    Johannes
    ------------------------------



  • 8.  RE: Live sorting of a standings-table

    Posted 01-09-2025 09:58

    I will try to find time to make an example in the mean time this looks like a similar conversation on here;

    https://rossvideo.community/discussion/racing-results-leaderboard-animations#bmd7a974c3-eb80-40c3-8481-75e853eeb6e0 



    ------------------------------
    Simon Redmile
    Senior Graphic Programmer & Designer
    Ross Video
    Bristol United Kingdom
    ------------------------------



  • 9.  RE: Live sorting of a standings-table

    Posted 01-09-2025 13:55
    group folder has the data for the first line i.e first name last name text if they are two separate objects...etc

    and the points is just the text. 

    and of course the y position for all the lines.

    makes sense?

    good luck






  • 10.  RE: Live sorting of a standings-table

    Posted 01-09-2025 14:02
    forgot to mention, i used this a long time
    ago and i forget if it swaps or pops on...you'll have to test it. ��





  • 11.  RE: Live sorting of a standings-table

    Posted 01-09-2025 14:29

    The OG poster asked for it to be animated between positions, this will just jump positions. 



    ------------------------------
    Simon Redmile
    Senior Graphic Programmer & Designer
    Ross Video
    Bristol United Kingdom
    ------------------------------



  • 12.  RE: Live sorting of a standings-table

    Posted 01-09-2025 14:41

    If you check this thread;

    https://rossvideo.community/discussion/racing-results-leaderboard-animations#bmd7a974c3-eb80-40c3-8481-75e853eeb6e0

    And download Roman's project testt.xpp it has what you need just connect the "Pos_0/1/2/3" etc to your data for each position and you'll see it will work when you change the data. 

    If you don't have data to test with you can use widgets. 



    ------------------------------
    Simon Redmile
    Senior Graphic Programmer & Designer
    Ross Video
    Bristol United Kingdom
    ------------------------------



  • 13.  RE: Live sorting of a standings-table

    Posted 01-09-2025 14:59

    Downloaded the file, but somehow I can't compile any of the scripts. Could this be because I'm just on a designer licence right now?



    ------------------------------
    Thanks for taking the time reading,
    Johannes
    ------------------------------



  • 14.  RE: Live sorting of a standings-table

    Posted 01-09-2025 15:04

    Correct you need at Developer or Studio to compile scripts. 



    ------------------------------
    Simon Redmile
    Senior Graphic Programmer & Designer
    Ross Video
    Bristol United Kingdom
    ------------------------------



  • 15.  RE: Live sorting of a standings-table

    Posted 01-09-2025 15:07

    Alright, it will have to wait till tomorrow then. This was already really helpful so thank you for that.



    ------------------------------
    Best wishes,
    Johannes
    ------------------------------



  • 16.  RE: Live sorting of a standings-table

    Posted 01-10-2025 09:17

    I just did something like this. It's pretty easy. First, create Animation Controllers for each object you want to move. For simplicity, give them the same name as the group object you want to move. Each Animation Controller has 2 keyframes - one at the start and one at the end. You will also need text objects for each group that has the Datalinq on it for the position. Then, when the text changes (OnSetText), call this global sub:

    ' Pos is the ordinal position of the item (1,2,3, etc)
    ' group is the object to move
    Sub MoveRunnerTo(pos As String, group As xpBaseObject, scene As xpScene)
    	' No data?
    	If pos = "" Then
    		group.Visible = False
    	Else
    		' Calculate where it should move to. Change -47 to whatever your size is
    		Dim posY As Double = (CInt(pos) - 1) * -47
    		If posY <> group.PosY Then
    			Dim anim As xpAnimController = Nothing
    			' The anim controller's name is the same as the group
    			scene.GetAnimControllerByName(group.Name, anim)
    			anim.Stop()
    			' Set first keyframe to current position
    			anim.SetKeyFrameValue(group, 0, "Position.Y", group.PosY)
    			anim.Position = 0
    			' Set last keyframe to desired position (my controller length is 15 frames)
    			anim.SetKeyFrameValue(group, 15, "Position.Y", posY)
    			' Run the animation
    			anim.Play()
    		End If
    		group.Visible = True
    	End If
    End Sub

    The script sets the 2 keyframes and runs the animation.



    ------------------------------
    JohnCorigliano
    Senior Software Engineer
    ISC
    ------------------------------



  • 17.  RE: Live sorting of a standings-table

    Posted 01-10-2025 11:42

    XPression Designer can compile and create scripts. Studio/Developer is only needed for API applications, I don't think Romans project has an API app, just scripts. 

    Can you post an image of the error you are seeing in XPression Designer? 

    I would also recommend to try just re-running the XPression Designer installer. 




  • 18.  RE: Live sorting of a standings-table

    Posted 01-10-2025 11:46

    Oopse yes I spoke wrong here! 



    ------------------------------
    Simon Redmile
    Senior Graphic Programmer & Designer
    Ross Video
    Bristol United Kingdom
    ------------------------------



  • 19.  RE: Live sorting of a standings-table

    Posted 01-10-2025 12:05

    It's alright, after changing licences it worked just as intended. Might be the restart of the software that led to the script working now. Haven't checked the second script that has been posted yet but it looks promising to my untrained eye.



    ------------------------------
    Best wishes,
    Johannes
    ------------------------------