INTERACT FORUM

Please login or register.

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

Author Topic: Album View: Question for users who want internal Images  (Read 1439 times)

RhinoBanga

  • Citizen of the Universe
  • *****
  • Posts: 1703
  • Developer
Album View: Question for users who want internal Images
« on: April 26, 2002, 01:52:05 am »

Friends,

A lot of you have expressed a desire for me to implement internal images.

Well I'll do it but are you willing to live with the fact that:

1)  It'll be slow viewing a track for the first time (then it's cached).
2)  If you view an artist, each album's first track is queried to get the artwork.
3)  If you go to the overview screen every album's (or completed album's) first track will be queried.


To give you an idea of performance it took just under 6 minutes for MJ to scan 3000 files on my 1.55ghz AMD machine ... which roughly equates to 8 files a second ... so if you have 300 albums it will take roughly 37 seconds to extract the images.   That's on my machine ... your mileage will definately vary.

Remember these timings are just to ask MJ to scan for the image ... there will be additional overhead in actually loading/caching the image and maintaining my data structures.

Of course I'll be intelligent and only ask MJ for the internal image if there is no external image (for thumbnails) but I will have to ask MJ for the internal image on the track details screen as that's the whole point of the screen.

So my question again ... are you *sure* you want it.
Logged

dragyn

  • Guest
RE:Album View: Question for users who want internal Images
« Reply #1 on: April 26, 2002, 01:57:41 am »

I'll try anything...Next Page
Logged

Cmagic

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 1196
  • Enjoying life with a little music....
RE:Album View: Question for users who want internal Images
« Reply #2 on: April 26, 2002, 02:56:48 am »

Rhino,

I'l also try any solution you'll implement as I'm confident they'll end up
as good implementations.

Regarding the internal images scanning time, I was positively surprised
when I tried version 0.1.0 of the plugin on my 5000|PLS| database, it was less
than a minute (Athlon 700Mhz / 512MB) to retrieve the internal images.
Logged
Until the color of a man's skin is of no more significance
than the color of his eyes.
Bob Marley (War)

RhinoBanga

  • Citizen of the Universe
  • *****
  • Posts: 1703
  • Developer
RE:Album View: Question for users who want internal Images
« Reply #3 on: April 26, 2002, 03:02:44 am »

LOL ... that was before I coded it "properly" Next Page

I wish I had that source code to see what I did Next Page

I'm going to wait a bit more to hear other people's thoughts before I make the decision ... plus it gives me time to get 0.2.3b sorted.
Logged

Fretwalker

  • Guest
RE:Album View: Question for users who want internal Images
« Reply #4 on: April 26, 2002, 04:40:27 am »

Hi again,
what about an option to load them on demand (not automatically on startup)just in the overview tree but NOT in the synchronize-mode - is it possible to load them one by one when the corresponding track is playing?

Sure you'll make it somehow (-;

E.
Logged

RhinoBanga

  • Citizen of the Universe
  • *****
  • Posts: 1703
  • Developer
RE:Album View: Question for users who want internal Images
« Reply #5 on: April 26, 2002, 04:49:48 am »

All images are on demand already.

When you view an artist in the album details screen I load up the thumbnail image for each album ... it's then cached.   So for an artist with more than 8 albums it would take over a second to get the images on my machine.   It doesn't sound a lot but it's a visible slowdown.

The worse case scenario is when you go to the overview screens and it has to load up all the images.

I suppose I could implement an on demand thumbnail viewer but that's a pain having to work out if a particular thumbnail is viewable.

I'll see what I can come up with.

Beta 0.3.0 isn't going to have the export/assign stuff now ... I'm going to get internal images sorted ... one way or another Next Page

Mike is going to kill me ... I still haven't implemented the fonts stuff Next Page
Logged

claudio

  • Regular Member
  • Galactic Citizen
  • ****
  • Posts: 265
RE:Album View: Question for users who want internal Images
« Reply #6 on: April 26, 2002, 06:11:12 am »

Hi Rhino,

I have one suggestion for how to make the scanning less "visible" to the user. I do this quite a bit in my vb code when I need guaranteed interactivity, and the task to perform is inherently slow but still breakable in a number of steps.

You could program the scanning asyncronously using a timer: initially load the deafult image as you do now and then start the timer. The timer routine would then update the images incrementaly one scan at the time, while the user could continue to interact normally with AV. You have to make sure in the timer routine you give control to other ui task (DoEvents) and you also need know if other "heavy" activity is going on (some class method, propriety whatever ), and in that case just do nothing and wait fot the next timer cycle to avoid interference.

The only drawback is that the incremental update is obviosly very visible (ie.e images will "pop up" continuosly until finished), but in my experience this is a tradeoff that people normally accept if it lets them continue interacting undisturbed and prevent a huge initial wait

Hope this help

Claudio
Logged

RhinoBanga

  • Citizen of the Universe
  • *****
  • Posts: 1703
  • Developer
RE:Album View: Question for users who want internal Images
« Reply #7 on: April 26, 2002, 06:18:54 am »

Claudio,

That's an Idea I will consider.

At the moment I don't actually do any visible progress while loading thumbnails.

I set the mouse pointer ot an hourglass, switch off redraw, load the images then invalidate the rect or (redraw the container window) then put the mouse pointer back.

The only progress is during the scan ... and you can switch that off with 0.2.3b ... that gains around .2 of a second on my machine.

The biggest gain I have gotten so far is physically removing my runtime debugging from the code ... that gained an additional .5 of a second.

So I think people will be impressed with how fast this new version is.
Logged

Doof

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 5908
  • Farm Animal Stupid
RE:Album View: Question for users who want internal Images
« Reply #8 on: April 26, 2002, 06:31:46 am »

I'd be willing to give it a try.

Are you saying this 5-6 minute delay would only happen once? Or every time I went to overview mode, or ?

For some reason, MJ crashes every time I exit when I have AV installed.
Logged

RhinoBanga

  • Citizen of the Universe
  • *****
  • Posts: 1703
  • Developer
RE:Album View: Question for users who want internal Images
« Reply #9 on: April 26, 2002, 06:35:30 am »

Doof,

It would be a once only hit ... or to be more exact ... every time you scan the MJ database.
But that's a worse case scenario ... I have some ideas on how to minimize the impact.

The only problem I have now is I need to start assigning internal images to my tracks so I get some test data ... I'm looking forward to that ... not!

And the crashing problem should be fixed in 0.2.3b which I am about to upload ... I'm just doing some last minute testing.
Logged

scub

  • Guest
RE:Album View: Question for users who want internal Images
« Reply #10 on: April 26, 2002, 06:43:58 am »

I would be willing to wait.
Logged

RhinoBanga

  • Citizen of the Universe
  • *****
  • Posts: 1703
  • Developer
RE:Album View: Question for users who want internal Images
« Reply #11 on: April 26, 2002, 09:43:33 am »

Oooo ... some timings for you guys.

I have quickly patched internal images back in and opening the overview screen showing all images (300) takes 40 seconds on my machine Next Page
Logged
Pages: [1]   Go Up