PDA

View Full Version : Improve reading from HDD


togliatti
03-22-2008, 07:00 PM
I've discovered KMPlayer recently and I find it very very good. Best of all other players I've used before.
But I have some problem with the playback of High Definition Video files.
Since I think I've found out the general reason of the problem, maybe this post can be of help to other users.
The problem is that at the very beginning (after about 5 secs) there are many dropped frames (80-160). After that the playback resumes smoothly. If I re-play the same file there is no problem.
After many experiments I've found that the problem is not with the configuration (renderer, filters) but should be with the reading of the file from the hard-disk.
The same file (wmv HDV) played from another hard disk (Samsung HD400LJ - more recent and supposedly more perfomant) is ok.

So I imagine that at the beginning there is much reading and paging of the file and the reading speed from some hard disk is not enough to keep up with the frame rate.

Anyhow Windows Media Player doesn't have this problem. The file is ok with no dropped frames with WMP, I suppose that WMP has some sort of reading ahead and buffering that avoid the massive hard disk access at the beginning.

So I think there could be some improvement in KMPlayer if some sort of file accessing method (buffering or something like that) could be implemented



Mu hardware configuration:
Core2 6700 @2.66GHz CPU
2 GB of Ram

This Hard disk has problems

Maxtor 6B300SO
Capacity 300 GB
Interface Serial ATA
Spindle Speed 7200 RPM
External Data Transfer Rate 150 MBps
Seek Time 9 ms
Buffer Size 16 MB
Average Latency 4.17 ms
Interface Serial ATA



This Hard disk has no problem

Samsung HD400LJ
Buffer DRAM Size 8 Mbytes
Bytes per Sector 512
Serial ATA 3.0
Read Seek Time (typical)
- Track to Track 0.8 ms
- Average 8.9 ms
- Full Stroke 18 ms
- Average Latency 4.17 ms
- Rotational Speed 7,200 rpm
Data Transfer Rate
- Media to/from Buffer (max.) 400/1000 Mbits/sec
- Buffer to/from Host(max.) 100 or 300 MB/sec
- Drive Ready Time (typical) 10 sec

togliatti
03-28-2008, 12:06 AM
After some experimenting I've found that the hdd features are not what causes the problem.
So the hdd characteristics in the previous post are not important.

The problem arises when the video file (high definition, that is a big file or a file requiring a high rate of transfer) is on the same hdd of the O.S. (Windows XP).
So as a general suggestion, if you have more than 1 hdd, keep the video files on the "data" hdd (the one in which there isn't the O.S.).

I suppose that at the beginning of a file played with KMPlayer there must be concurrent readings from both the video data and from the program (kmplayer) or from the o.s. These files are in different positions on the hdd and the reading head must move from one position to another and the reading rate can't keep up with the required data transfer.

Anyhow the feature request to improve KMPlayer file reading remains as Windows Media Player can manage it without showing any dropped frame (probably by moving the program or o.s. relevant parts or part of the video file in the ram).