Results 1 to 7 of 7

Thread: Help with using "CLLINES," custom lists and extension plugin...

  1. #1
    FLAC Sal R.'s Avatar
    Join Date
    Aug 2006
    Location
    Sun Diego
    Posts
    1,448

    Help with using "CLLINES," custom lists and extension plugin...

    So I have a text file that has path and filename information on it that contain attributes that I want to display.

    i.e.
    path and file #1...
    path and file #2...
    path and file #3...
    path and file #4...
    ...
    etc.

    I have no problems reading the file or displaying the information I mine from it.

    My problem I have is in trying to display such a large list into a custom list RR. The process of gathering the data from each file is slow and hangs RR until the reading/mining operation is complete.

    I need help putting together code so that my plugin only reads data based on the line height of the custom list and list position. This way the file read/data mining is limited to only what is displayed.

    When you page up/down, plugin reads the LISTPOS and CLLINES to run a loop to read the appropriate files, extract the info, and display it appropriately in the custom list.

    I've been at this for a couple days now, but just can't wrap my head around it.

    Help?
    Pico-ITX / XP Home with EWF-HORM / RR v12/02/2009 / Winamp v5.13 / RRMedia v1.2.2

  2. #2
    FLAC Sal R.'s Avatar
    Join Date
    Aug 2006
    Location
    Sun Diego
    Posts
    1,448
    So, I've been pouring over the old RR source code to try and understand how playlists are loaded/updated.

    The problem is, I can't quite...find it.

    I've checked modRoadRunner.bas and frmSkin.frm.

    Can someone please point me in the right direction?

    Thx!
    Pico-ITX / XP Home with EWF-HORM / RR v12/02/2009 / Winamp v5.13 / RRMedia v1.2.2

  3. #3
    FLAC Sal R.'s Avatar
    Join Date
    Aug 2006
    Location
    Sun Diego
    Posts
    1,448
    Found it and figured out a solution to my problem. It's a real hack job, but it works.

    Yay me.

    Pico-ITX / XP Home with EWF-HORM / RR v12/02/2009 / Winamp v5.13 / RRMedia v1.2.2

  4. #4
    The Last Good Gremlin GizmoQ's Avatar
    Join Date
    Nov 2004
    Location
    St Louis
    Posts
    2,344
    and the solution was.......????
    HARDWARE: Fujitsu Stylistic ST5111w/WiFi and dock, internal Hitachi 500G HD, external 1TB HD, Sierra Wireless Aircard 550, DVD-RW, BoomzBox HD radio, XM Commander, Delorme GPS, Saitek X-52 Pro joystick, BluSoleil Bluetooth, TPMS, FB, Elm327

  5. #5
    FLAC Sal R.'s Avatar
    Join Date
    Aug 2006
    Location
    Sun Diego
    Posts
    1,448
    Quote Originally Posted by GizmoQ View Post
    and the solution was.......????
    lol

    Didn't think anyone was interested, but here you go:

    Code:
        Dim i_listpos As Integer ' \\ Current CL listpos
        Dim i_numlines As Integer ' \\ "CLLINES" RR Label
        Dim i_listmax As Integer ' \\ "CLMAX" RR Label
    
        Dim list_start As Integer
        Dim list_end As Integer
        
        list_start = i_listpos - Int(i_numlines / 2)
        list_end = i_listpos + Int(i_numlines / 2)
        
        If list_start < 1 Then
            list_start = 1
            list_end = i_numlines
        ElseIf list_end > i_listmax Then
            list_start = i_listmax - i_numlines
            list_end = i_listmax
        End If
        
        ' \\ Loop until all displayed lines have been updated
        For i = list_start To list_end
           <Insert the code you want to loop here>
           RRSDK.Execute ("CLSET;" + CStr(i) + ";" + <Upated List Item Description>)
        Next
    Run this sub when you page down to update the list that is displayed only.

    It was simpler than I thought.

    Go figure.
    Pico-ITX / XP Home with EWF-HORM / RR v12/02/2009 / Winamp v5.13 / RRMedia v1.2.2

  6. #6
    RoadRunner Mastermind
    Auto Apps:loading...
    guino's Avatar
    Join Date
    Nov 2004
    Location
    Toronto, Canada
    Posts
    9,818
    did you try writing a file in the format that works with CLLOAD/CLSAVE ? CLLOAD should be able to load/display the information quite faster than using CLSET/CLADD individually... however, if writing such file would take a relative amount of time, then your way is probably best.
    Ride Runner RR's Myspace

    "Being happy is not about having what you want, it's about wanting what you have."
    "The best things in life are always free - but that doesn't mean money can't buy you good things."

  7. #7
    FLAC Sal R.'s Avatar
    Join Date
    Aug 2006
    Location
    Sun Diego
    Posts
    1,448
    Quote Originally Posted by guino View Post
    did you try writing a file in the format that works with CLLOAD/CLSAVE ? CLLOAD should be able to load/display the information quite faster than using CLSET/CLADD individually... however, if writing such file would take a relative amount of time, then your way is probably best.
    Yeah, I did. That was not an optimal solution.

    What I'm doing exactly is reading ID3 tag data from the paths/filenames in an .m3u playlist and displaying them in a custom list. Having the plugin read a pl with thousands of entries and then loading it into RR is slow.

    In a nutshell, I replicated an audio player playlist function to be used w/ .m3u playlists so I can properly see the contents of a selected playlist without having to load the playlist first.
    Pico-ITX / XP Home with EWF-HORM / RR v12/02/2009 / Winamp v5.13 / RRMedia v1.2.2

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •