INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Feature Request: New field [Last Played (album)]  (Read 1015 times)

markf2748

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 822
Feature Request: New field [Last Played (album)]
« on: June 13, 2021, 06:41:10 pm »

New built-in field with the following functionality:

(1) Returns the most recent (i.e. largest) value of [Last Played] across all audio and image files in the album of the current file. 

(2) The field updates itself immediately whenever [Last Played] changes for any audio or image file in the album.

(3) The implementation must be O(1), not O(N).

Note:  (1) and (2) are already available in the expression language function GroupSummaryQuery(album, last played, 1), but unfortunately with impact O(N).  The slow performance due to matching over the entire library makes this function call unworkable in applications of interest.

Alternative or in addition:
A new expression language function LastPlayedAlbum(mode)

Mode:
0 = return most recent [Last Played] over all audio files in current album
1 = return most recent [Last Played] over all image files in current album
2 = return most recent [Last Played] over both audio and image files in current album

Reference:

https://yabb.jriver.com/interact/index.php/topic,129688.msg899908.html#msg899908

Logged

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42376
  • Shoes gone again!
Re: Feature Request: New field [Last Played (album)]
« Reply #1 on: June 13, 2021, 06:46:31 pm »

So basically an album relational version of the existing last played?  What would be the purpose?  Thanks.
Logged
Matt Ashland, JRiver Media Center

markf2748

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 822
Re: Feature Request: New field [Last Played (album)]
« Reply #2 on: June 13, 2021, 07:17:41 pm »

Yes, except [Last Played] by itself generally returns different values for audio files (played) and image files (played = viewed).  I need [Last Played (album)] to return the same value to both audio and image files in the current album in order for it to be useful as a common sort target.  Same for LastPlayedAlbum(mode).

I store album covers and artwork in files adjacent to my audio files, in a simple, usual, shallow Music > Artist > Album file structure.

I want "global" views of the album art which are sorted in the same way, 1-1, as the audio views.

Examples:
One tab with Audio view sorted by Most Recently Played and another tab with Image View of the covers and artwork sorted in the same order. Both are View As: Categories, grouped by [album].
Most Recently Added Audio <--> Most Recently Added Images
Artists Audio <--> Artists Images
Year (released) Audio <--> Year (released) Images

I have implemented all these synchronizations easily (each has View As: Categories, Expression to Group By = ...[album]...) with MC's view sorting capability, except the Most Recently Played has been a real challenge.
All the sorts are very fast, except for Most Recently Played because it is O(N2) as discussed extensively in the later parts of the Reference.

Summary:  I am looking for a synchronized O(N) sort for Most Recently Played, which means I need an O(1) method of finding Last Played in each album, and the identical result must be automatically distributed to both audio and image files whenever a change occurs.

A mouthful!  But I really like the way these sorts look  :).

PS:  One could envision extending this concept to include document files, for a last played synchronized view of other album materials.
 
Logged

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42376
  • Shoes gone again!
Re: Feature Request: New field [Last Played (album)]
« Reply #3 on: June 14, 2021, 11:35:37 am »

Coming to MC28:
NEW: Added a "Last Played (album)" field that is set album wide for plays.

Cheers.
Logged
Matt Ashland, JRiver Media Center

markf2748

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 822
Re: Feature Request: New field [Last Played (album)]
« Reply #4 on: June 14, 2021, 11:49:43 am »

Coming to MC28:
NEW: Added a "Last Played (album)" field that is set album wide for plays.

Thanks!  :)
Logged
Pages: [1]   Go Up