Jump to content
IGNORED

iTunes - HQPlayer front-end re-visited


Recommended Posts

12 hours ago, Geoffrey Armstrong said:

I have re-written my iTunes front end to HQPlayer. This new version works with both HQPlayer4Desktop and HQPlayerDesktop (series3).

 

The first time you run this, please launch HQPlayer before launching my app. This will allow my app to correctly configure itself to the version of HQPlayer you are using. Then if you subsequently launch my app when HQPlayer is not running and request my app to launch HQPlayer, it will launch the last version that you ran.

 

For those of you who go between versions 3 an 4 of HQPlayer, you'll need to repeat this exercise (launch the version of HQPlayer you wish to use before launching my app) so again my app can correctly configure itself for the version of HQPlayer being used.

 

I will post this software on my own web-site once I've had some testing feedback here.

 

Thanks

 

Geoff

iTunes - HQPlayer Server.app.zip 7.48 MB · 4 downloads

 

Aloha Geoffrey,

 

Thanks so much for putting your time into this.  I'm on the latest version of Mojave.  I followed your instructions regarding launching HQP 3 before your app.  I did not alter your preference screen as I can't remember from way back if, or how, the preferences out to be set.  When I clicked "ok" on  your preference screen I get the error message below appeared.  I continued on to play a song in iTunes.  The song played, but bypassed HQP 3 entirely.  The same thing happened with HQP 4.

 

I'm only using a MacBook Pro for everything.

 

Suggestions?

 

1353600769_ScreenShot2019-06-25at10_28_42AM.png.fcff34ca066c51e38c376a422be27c5f.png

Link to comment
On 6/24/2019 at 10:39 PM, Geoffrey Armstrong said:

I have re-written my iTunes front end to HQPlayer. This new version works with both HQPlayer4Desktop and HQPlayerDesktop (series3).

 

The first time you run this, please launch HQPlayer before launching my app. This will allow my app to correctly configure itself to the version of HQPlayer you are using. Then if you subsequently launch my app when HQPlayer is not running and request my app to launch HQPlayer, it will launch the last version that you ran.

 

For those of you who go between versions 3 an 4 of HQPlayer, you'll need to repeat this exercise (launch the version of HQPlayer you wish to use before launching my app) so again my app can correctly configure itself for the version of HQPlayer being used.

 

I will post this software on my own web-site once I've had some testing feedback here.

 

Thanks

 

Geoff

iTunes - HQPlayer Server.app.zip 7.48 MB · 8 downloads

 

Wherefore art thou Geoffrey 😇?

Link to comment
15 hours ago, DancingSea said:

 

Wherefore art thou Geoffrey 😇?

In case this is a reference to the fact that Apple is "killing off iTunes" as widely reported in the media; bear in mind the following:

 

1/ This applies from the forthcoming version of MacOS named Catalina.

2/ iTunes is not simply going to evaporate from Macs whilst they are running existing and previous versions.

3/ In Catalina there will be separate apps for Music, Podcasts …;etc. and (according to reports I've read) these will still be based on the current iTunes code. So that iTunes will effectively be split into several apps, each being dedicated to the media it's supposed to serve.

4/ As long as the "Music" app is based on iTunes and as long as Apple don't strip out the current iTunes Applescript support, as far as your music library is concerned, then my latest app should be fairly easy to adapt to the new "Music" app. Perhaps with only a change of reference to the app from "ITunes" to "MusisApp" or whatever it's called.

 

Apple appears to be letting Applescript decline and is no longer encouraging it in the way it did in the past. The real question is whether Apple still believes in the concept of providing APIs to its core apps. These have allowed developers to produce plug-ins to iTunes; etc. which is what my app is.

 

I would much prefer to be able to write such plug-ins in Swift in the future. I think this would make development far easier for such aspects as writing the GUI parts, for example.

 

If anyone has any more information on any of this, please feel free to chip in.

 

In the meantime, I also wrote an HQPlayer front end for Swinsian, which I will be posting here today. Writing that app, gave me ideas for improving the iTunes front end, which is close to a re-write from the ground up.

 

The Applescript dictionaries for Swinsian and iTunes are very similar. There are some significant differences, so it wasn't just a matter of a couple of search and replaces in the code. Hopefully Apple's forthcoming "Music" app will also be easy to adapt. We'll see.

 

For the moment this iTunes front end to HQPlayer is the only Mac native app I know of that provides remote control via IOS using Apple's remote app. 

 

James, the developer of Swinsian is supposedly working on a remote app; but couldn't provide me with a timeline for it.

 

I also asked him if he has any plans to support the Qobuz and Tidal streaming services. Unfortunately he does not.

 

Geoff

 

Owner of: Sound Galleries, High-End Audio Dealer, Monaco

Link to comment
34 minutes ago, Geoffrey Armstrong said:

Apple appears to be letting Applescript decline and is no longer encouraging it in the way it did in the past. The real question is whether Apple still believes in the concept of providing APIs to its core apps. These have allowed developers to produce plug-ins to iTunes; etc. which is what my app is.

I would much prefer to be able to write such plug-ins in Swift in the future. I think this would make development far easier for such aspects as writing the GUI parts, for example.

 

To run AppleScript commands from a Swift app, Scripting Bridge remains essentially unchanged since 2008, except for the addition of a Swift counterpart of the original ObjC framework:

 

https://developer.apple.com/library/archive/documentation/Cocoa/Conceptual/ScriptingBridgeConcepts/Introduction/Introduction.html

 

https://developer.apple.com/documentation/scriptingbridge

HQPlayer (on 3.8 GHz 8-core i7 iMac 2020) > NAA (on 2012 Mac Mini i7) > RME ADI-2 v2 > Benchmark AHB-2 > Thiel 3.7

Link to comment
5 minutes ago, Bob Stern said:

 

To run AppleScript commands from a Swift app, Scripting Bridge remains essentially unchanged since 2008, except for the addition of a Swift counterpart of the original ObjC framework:

 

https://developer.apple.com/library/archive/documentation/Cocoa/Conceptual/ScriptingBridgeConcepts/Introduction/Introduction.html

 

https://developer.apple.com/documentation/scriptingbridge

Thanks Bob. I am aware of that and am already making use of the scripting bridge.

 

What I was imagining was a scenario whereby Apple entirely replaces Applescript with Swift. After all, Swift is already a high enough level language that it sort of makes Applescript's English like syntax redundant, IMO.

 

For me the real question is; does Apple still want to encourage third party developers to extend its core apps as it once did?

Owner of: Sound Galleries, High-End Audio Dealer, Monaco

Link to comment

I've since moved onto Roon but I'm curious to try this anyway.

 

As for AppleScript, there is probably a lot more of it out there in legacy applications than most people realize, which is why Apple is bothering keeping compatibility with newer programming models.  There's been no indication or notice that it's being retired....it's just a mature technology that still has a purpose for some.  And AppleScript is pretty mature, with the tech dating back to the HyperCard days.

Link to comment
24 minutes ago, Sevenfeet said:

I've since moved onto Roon but I'm curious to try this anyway.

 

As for AppleScript, there is probably a lot more of it out there in legacy applications than most people realize, which is why Apple is bothering keeping compatibility with newer programming models.  There's been no indication or notice that it's being retired....it's just a mature technology that still has a purpose for some.  And AppleScript is pretty mature, with the tech dating back to the HyperCard days.

Well, I was partly going by this article:

https://eclecticlight.co/2016/11/18/goodbye-applescript/

…which is a bit old by now and you're right, Applescript is still here :)

 

Owner of: Sound Galleries, High-End Audio Dealer, Monaco

Link to comment
3 hours ago, Geoffrey Armstrong said:

Well, I was partly going by this article:

https://eclecticlight.co/2016/11/18/goodbye-applescript/

…which is a bit old by now and you're right, Applescript is still here :)

 

 

Hi Geoffrey,

 

Great news about Swinsian, looking forward to trying it.

 

Any advice on the error message below that I get when launching your latest iTunes/ HQP app?  

 

When I clicked "ok" on  your preference screen I get the error message below appeared.  I continued on to play a song in iTunes.  The song played, but bypassed HQP 3 entirely.  The same thing happened with HQP 4.  

 

Thanks.

Screen Shot 2019-07-02 at 7.28.53 AM.jpg

Link to comment

I think this is where my app is attempting to write to a log file in your music folder.

 

It isn’t critical to write to this file. It’s just for your info to help resolve any issues in your iTunes library. If it causes problems, I’ll remove or comment out the code.

 

Can you do a getInfo on your Music folder and tell me who has read and write permissions?

 

if you’re willing to open up those permissions to “everyone”, it may fix the problem.

 

The only other place where I write to files is within the app itself.

Owner of: Sound Galleries, High-End Audio Dealer, Monaco

Link to comment
27 minutes ago, Geoffrey Armstrong said:

I think this is where my app is attempting to write to a log file in your music folder.

 

It isn’t critical to write to this file. It’s just for your info to help resolve any issues in your iTunes library. If it causes problems, I’ll remove or comment out the code.

 

Can you do a getInfo on your Music folder and tell me who has read and write permissions?

 

if you’re willing to open up those permissions to “everyone”, it may fix the problem.

 

The only other place where I write to files is within the app itself.

 

My iTunes library is on an external hard drive as its 4TB in size.  I went through every folder related to iTunes music and changed the read/ write permissions to "everyone", all the way down to the folder than contains all of the actual music file folders in iTunes.  The error message still comes up.

 

But beyond that, iTunes is not sending music to HQP 3 or 4.  With your script, HQP, and iTunes all active, the music remains in iTunes.  Any ideas?

Link to comment

Ok, thanks for trying that. When you get that error message can you click on the “Edit” button? This should open the Applescript Editor, hopefully at the place that’s provoking the error.

 

Then if you can grab the Applescript editor window using command-shift-4 where it opens and post that here or send to me as a PM, it should help me resolve it.

Owner of: Sound Galleries, High-End Audio Dealer, Monaco

Link to comment
5 hours ago, Geoffrey Armstrong said:

OK, here's another version of the iTunes app, just to test if it cures that file permission error.

 

Please let me know. Thanks

 

 

iTunes - HQPlayer Server.app.zip 7.47 MB · 0 downloads

 

Unfortunately, same error, and same no sending itunes music to HQP 3...

 

I also disconnected my external hard drive and only used the iTunes library on my internal MacBook Pro solid state hard drive.  The same error appeared.  The error shows up before your script even launches iTunes.

Link to comment
  • 4 weeks later...

A few weeks ago when I posted my iTunes and Swinsian front ends to HQPlayer I made a stupid mistake! In trying to make both apps self contained (so all necessary files would be inside the apps themselves) I forgot something obvious; the .plist file which contains the apps preferences can only be written to by the person who's running the app, you!

 

Each time I released a version though, the permissions would default to me. In any case it doesn't make any sense for preferences to be written to a file within the app itself, because your preferences would be wiped, each time you install a new version.

 

This error was preventing anyone who tried these apps from passing 'go'.

 

These new versions for iTunes and Swinsian correct that error. The .plist files are now written to a sensible place: your library, scripts folder. (~/Library/Scripts).

 

Here is a screen shot of the default preferences in the app's dialog box

 

870851401_Defaultprefs.png.b090c034cf922b05ff076c0e93ee7b0d.png

 

This assumes you're running HQPlayer on the same Mac as iTunes. So the client is "localhost" which appears by default and the three fields which follow this don't need to be completed either.

 

The operating system of the client machine should also be set to "Mac" by default.

 

If temporary files need to be created, they can optionally be created on a Ram disk. You can choose a Ram disk of 50% or 75% of available Ram and if you do this, that Ram disk will be automatically created on your Mac.

 

The next field allows you to specify that temporary files will always be created (whether necessary or not). You may choose to do this for sound quality reasons.

 

The next field allows you to choose whether those temporary files are to be created in .flac or .wav format.

 

I’ve heard arguments in favour of each over the other. .wav because, normally it doesn’t have the overhead of containing any meta-data or embedded artwork. .flac because it still normally produces smaller files and these might be handled better by HQPlayer.

 

Finally you can choose whether the app should launch HQPlayer for you. Only do this after the first time you launch the app. On the first occasion you need to launch HQPlayer before launching my app. This is so my app can register which version of HQPlayer you are running (3 or 4) and where it's located.

 

So this is the simplest scenario. The most complex scenario is whereby you want to use a Mac as a server to HQPlayer running on a different machine.

 

Whichever machine HQPlayer is running on, will be the machine that does the "heavy lifting".

 

Under this next scenario, just about any Mac can be used, as long as it can run iTunes and my app.

 

Note: You will still need a version of HQPlayer running on this Mac. This is because the control app which is part of HQPlayer is used to communicate with the other client machine.

 

Here is an example screenshot of this scenario:

 

358503076_ScreenShot2019-07-07at9_22_33PM.png.9c925c5ceeac86e14c5038401421a5e3.png

 

The client machine, running HQPlayer is a Windows machine, and its IP address must be entered in the "Client Machine address" field.

 

You must have previously mapped your iTunes music folder to a mapped location (Drive letter on this Windows machine) and that music folder must be shared from your Mac over your LAN.

 

It's important to understand that the folder on your Mac which is mapped to this drive letter must be the folder which contains all the Artist folders, which in turn contain the albums of each of those artists. DO NOT MAP A HIGHER OR LOWER LEVEL FOLDER.

 

In this example the mapped drive is the single drive letter "t", which can be entered in upper or lower case.

 

The next field contains the location of where you want the temporary files created on this Windows client machine. YOU MUST SHARE THIS LOCATION FROM YOUR WINDOWS MACHINE over your LAN.

 

In the example this is "C:\SGMusic"

 

You must also have previously connected to the client machine from your Mac by going to the Finder -> Connect to Server and browsing to the client machine. The shared folder (in this case "SGMusic" must show up and you'll need to double click it, to make it accessible to your Mac.

 

The next field is the share name of that same folder as it appears on your Mac.

 

In the example "SGMusic".

 

As this is a Windows client you must select "Windows" as the operating system.

 

Ram disk doesn't apply as no Ram disk can be automatically created on the client machine.

 

Of course there's nothing to stop you creating a Ram disk on that machine and using it as the shared location where the temp files will be created.

 

The remaining fields are the same as in the first example.

 

So this is more complicated to set up initially. In my experience though, it yields the best sound quality, especially if temp files are always created.

 

The latest corrected version of my app is attached.

 

 

 

 

iTunes - HQPlayer Server.app.zip

Owner of: Sound Galleries, High-End Audio Dealer, Monaco

Link to comment
  • 9 months later...

Hi, Geoffrey, I decide to dive into this approach by using Swinsian.  I spent this evening with Swinsian and found it pretty straightforward to use.  I also read the entire thread this evening and I noticed that “iTune to HQP” only works for AIFF.  Unfortunately, I have ripped all my CD using Apple Lossless, all my files end with tag .m4a.  Will the script you developed work for .m4a?  If not, I can always convert m4a to FLAC and played it with Swinsian.  Again, very nice work from you on this, also on several other fronts as well.  I have recommended one of my friends who is on PC platform to look into your effort of “JRiver to HQP”

 

 

Link to comment
3 hours ago, Mahler and Bach on Computer said:

 I also read the entire thread this evening and I noticed that “iTune to HQP” only works for AIFF.  Unfortunately, I have ripped all my CD using Apple Lossless, all my files end with tag .m4a.  Will the script you developed work for .m4a?  If not, I can always convert m4a to FLAC and played it with Swinsian.  Again, very nice work from you on this, also on several other fronts as well.  I have recommended one of my friends who is on PC platform to look into your effort of “JRiver to HQP”

 

 

You've mis-understood here. My iTunes to HQPlayer app will work with any file type that is supported by iTunes, including Apple lossless. In fact it was designed to take any iTunes supported format and create temporary files in your choice of either flac or wav format. This will happen automatically for Apple lossless files in your iTunes lib.

 

The only limitations are in the file types that can be stored in the iTunes library itself. Because iTunes doesn't support flac or DSD. So for people who have ripped their CDs; etc. to flac, or have a lot of DSD, I recommend my Swinsian solution instead.

 

I hope I've made it clearer for you.

 

Thank for recommending my apps :)

 

Owner of: Sound Galleries, High-End Audio Dealer, Monaco

Link to comment
5 hours ago, Geoffrey Armstrong said:

You've mis-understood here. My iTunes to HQPlayer app will work with any file type that is supported by iTunes, including Apple lossless. In fact it was designed to take any iTunes supported format and create temporary files in your choice of either flac or wav format. This will happen automatically for Apple lossless files in your iTunes lib.

 

The only limitations are in the file types that can be stored in the iTunes library itself. Because iTunes doesn't support flac or DSD. So for people who have ripped their CDs; etc. to flac, or have a lot of DSD, I recommend my Swinsian solution instead.

 

I hope I've made it clearer for you.

 

Thank for recommending my apps :)

 

Hi, Geoffrey:  Thank you again for the help.  For Swinsian, it appears that people mentioned about memory issue.  Should I concern about it?  Except that I think it fits my need because I do have large collections of both RBCD and SACD, largely 3T for each, saved on a NAS.  While I love HQP, I will not go crazy with parameters - DSD 128 sounds way better than from JRiver.  

 

I did not see the pdf file for the instruction for the more recent development.  Which is your more updated post regarding the procedure of installation?

 

Thank you again!

Link to comment
8 hours ago, Geoffrey Armstrong said:

My most recent post for this is the one above 

The instructions for the Swinsian app are exactly the same as those for the iTunes/Music app.

Hi, Geoffrey: 

 

I have installed the app and it worked right a way.  Beautiful sounds coming out from those *.m4a with SQ which I never heard before. The only caveat is that, instead of Swinsian being started, the Catalina Music was started.  Fortunately, I had both Apple Music and Swinsian ready for this experiment.  Still, I feel excited at the results from your work!  So my first question is that, given both Apple Music and Swinsian installed on one computer, how to guide iTune-HQPlayer App to start the desired program?  Another speculation is the issue could arise from the fact that my Swinsian is still a trial version?

 

My second question is regarding which format of temp file is more preferable,  Flac vs. wav, from the perspective computational demand.  I assume the FLAC is more computational demanding because of compression?  The reason I post this question is that if I define the format of temp to be wav, will it give more power to HQPlayer for filter calculation?  Or this should not be my concern at all because I noticed that within 1 min, the conversion of a 75-min long album was completed and was queued under HQPlayer Desktop?

 

I found your more complicated configuration intriguing!  I am wondering how the computer that runs Apple Music/Swinsian can be connected with the Mac which runs HQPlayer Desktop.  Can this form of communication be WIFI-based which belongs to the same network where HQPlayer Desktop and the streamer where NAA is located such as SoTM sMS 200 are connected through Ethernet?

 

My last question is where the temp files is located?  I want to make sure they are cleaned.

 

Many thanks for an excellent effort!

 

BTW, Swinsian works great.  The library integration of close to 6T in size has been the least painful and the fastest in my memory.  

 

Best regards,  

 

 

David

 

 

Link to comment

Hi David,

 

Glad you're enjoying it!

 

I'll answer your questions below your quotes:

Quote

The only caveat is that, instead of Swinsian being started, the Catalina Music was started. 

 

I posted two different apps here; my Swinsian app and my iTunes/Music app. You need to run my Swinsian app when using Swinsian and my iTunes to HQP app when running either iTunes or the Catalina music app.

 

I can't recall the limitations of the Swinsian trial; but I don't think it should effect the operation of my app.

 

Quote

My second question is regarding which format of temp file is more preferable,  Flac vs. wav, from the perspective computational demand.  I assume the FLAC is more computational demanding because of compression?  The reason I post this question is that if I define the format of temp to be wav, will it give more power to HQPlayer for filter calculation?  Or this should not be my concern at all because I noticed that within 1 min, the conversion of a 75-min long album was completed and was queued under HQPlayer Desktop?

 

Well, that's a good question and one that's been heavily debated here. You really need to subjectively test both.

 

For what it's worth my own subjective impressions are that wav slightly emphasis leading edge transients; but is a little "flatter" and less 3 dimensional than flac. The arguments in favor of flac are, as you say that they don't need to be de-compressed in real-time, also they usually don't contain any meta-data, such as embedded album art.

 

On the other hand flac files are smaller and this might have benefits of HQPlayer. Only @Miska can really answer that.

 

 

 

You might even prefer flac for some music and wav for others.

 

Quote

I found your more complicated configuration intriguing!  I am wondering how the computer that runs Apple Music/Swinsian can be connected with the Mac which runs HQPlayer Desktop.  Can this form of communication be WIFI-based which belongs to the same network where HQPlayer Desktop and the streamer where NAA is located such as SoTM sMS 200 are connected through Ethernet?

 

This is actually thanks to @Miska since he provided the ability to control HQPlayer over a network. There is a network button on the HQPlayer Desktop interface and this must be activated for this to work.

 

Then you have to set up the client machine to be the ip address of the machine running HQPlayer and the locations for the temporary files to be written to on the Mac running Swinsian/Itunes/Music. That location must be shared over the network from the machine running HQPlayer. That machine's location for the same files must also be specified, so they can be loaded in HQP. It's a bit confusing. So I hope that's clear. Once it's set up it just works.

 

Quote

Can this form of communication be WIFI-based which belongs to the same network where HQPlayer Desktop and the streamer where NAA is located such as SoTM sMS 200 are connected through Ethernet?

 

Yes, as long as it's the same network.

 

Quote

My last question is where the temp files is located?  I want to make sure they are cleaned.

 

By default they are located in: "Users:<your username>:Music:HQP:Server temps"; but you can have my app create a Ram disk for you and have them created there. Might sound better!

 

Best regards

 

Geoff

Owner of: Sound Galleries, High-End Audio Dealer, Monaco

Link to comment
3 hours ago, Geoffrey Armstrong said:

Hi David,

 

Glad you're enjoying it!

 

I'll answer your questions below your quotes:

 

I posted two different apps here; my Swinsian app and my iTunes/Music app. You need to run my Swinsian app when using Swinsian and my iTunes to HQP app when running either iTunes or the Catalina music app.

 

I can't recall the limitations of the Swinsian trial; but I don't think it should effect the operation of my app.

 

 

Well, that's a good question and one that's been heavily debated here. You really need to subjectively test both.

 

For what it's worth my own subjective impressions are that wav slightly emphasis leading edge transients; but is a little "flatter" and less 3 dimensional than flac. The arguments in favor of flac are, as you say that they don't need to be de-compressed in real-time, also they usually don't contain any meta-data, such as embedded album art.

 

On the other hand flac files are smaller and this might have benefits of HQPlayer. Only @Miska can really answer that.

 

 

 

You might even prefer flac for some music and wav for others.

 

 

This is actually thanks to @Miska since he provided the ability to control HQPlayer over a network. There is a network button on the HQPlayer Desktop interface and this must be activated for this to work.

 

Then you have to set up the client machine to be the ip address of the machine running HQPlayer and the locations for the temporary files to be written to on the Mac running Swinsian/Itunes/Music. That location must be shared over the network from the machine running HQPlayer. That machine's location for the same files must also be specified, so they can be loaded in HQP. It's a bit confusing. So I hope that's clear. Once it's set up it just works.

 

 

Yes, as long as it's the same network.

 

 

By default they are located in: "Users:<your username>:Music:HQP:Server temps"; but you can have my app create a Ram disk for you and have them created there. Might sound better!

 

Best regards

 

Geoff

Hi, Geoffrey:

 

I apologize for my ignorance but I only found one App in your zip file posted the link you suggested.  I did it several times and condition remains the same.  
 

The other thing I noticed is that I kept generating two tracks for each individual track in the original album, and two tracks are side-by-side.

 

i will report my own experience on flac vs wav over the weekend.

 

Thank you again!

 

Best regards,

 

David

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...