ReClock и его применение для проигрывания музыки

Страницы :  1, 2, 3 ... 21, 22, 23  След.
Ответить
 

BalticX

Top Bonus 01* 300GB

Стаж: 15 лет 3 месяца

Сообщений: 1718

BalticX · 06-Фев-10 12:32 (14 лет 7 месяцев назад, ред. 07-Фев-10 14:22)

Я не то чтобы масштабно вопрос хочу поставить, а просто в других темах это возбуждает много флуда и флейма.
Суть в том, что кому надо уже давно выяснил, что есть такая програмулина как ReClock, которая при правильном использовании может дать положительный результат в решении некоторых вопросов.
Вопросы эти автором вообще-то сводились к синхронизации аппаратно-программных устройств ПК для нормального воспроизведения видео. Но ушлые юзеры просекли, как можно повернуть технологии продукта на эффективное, по их мнению, воспроизведени чисто аудио материала. Как можно предположить из выдержек описания продукта и обсуждений на авторском разделе форума, технология в таком случае сводится к некой опять же программно-аппратной синхронизации только уже в части аудио:
Цитата:
You also have the ability to disable completely the system and audio clocks adaptation using the checkbox “slave reference clock to audio”. Doing so, ReClock will work much like the default DirectSound audio renderer, but rate adaptation will still function and reference clock will be slaved to audio clock with a smooth algorithm
К тому же ReClock позволяет вывод звука организовать через Kernel Streaming и в настройке "для аудио" так прямо и пишет в окне мониторинга: kernel streaming, bit exact. Измерения, проведённые придирчивыми юзерами показали, что и впрямь цифра получается та же самая что и у настроенного на точное воспроизведение Foobar2000. Вот только при работе последнего (и других подобных проигрывателей) ничего не предпринимается для синхронизации - "ходьбы в ногу".
Есть, разумеется, разные проф карты, имеющие аппаратный механизм некой синхронизации - там ReClock может не дать эффекта или даже будет мешаться.
Преамбулу постарался оформить максимально корректно по отношению к "великим экзаменаторам", дабы дать им минимум повода. Тех же, кто готов непредвзято исследовать в поисках лучшего и верного, приглашаю к собственно исследованиям и обмену результатами, мнениями. Свои собственные слуховые впечатления могу охарактеризовать как исключительно положительные - лично мне ReClock позволил существенно продвинуться от Цифры к Музыке.
Для неискушенного читателя поясню, что ReClock это не проигрыватель, а программное устройство организации вывода звука. Можно использовать с такими медиапроигрывателями как MPC, KMPlayer и т.п.
Предварительную инструкцию с картинками и ссылками по установке-настройки можно посмотреть здесь.
авторское описание работы программы
ReClock by SlySoft, Inc.
Web site: http://www.slysoft.com
Please take time to test ReClock, and report success or failures to make it work with your PC. Have a look on changelog.txt and on my website for latest modifications.
----------------------------------------------------------------------------------------------------------------------------------------
----------------------------------------------------------------------------------------------------------------------------------------
What is ReClock?
----------------------------------------------------------------------------------------------------------------------------------------
Said simply the purpose of ReClock is to definitely get rid (I hope) of jerky playback of AVI and MPEG material on a PC (or a PC connected to a TV).
ReClock is born from my own frustration. I have a fast PC, a good video card, and when I play a DVD or DIVX on my brand new Home Cinema, I get dropped frames here and there for no reason, or a completely jerky and un-watch able movie. This is very annoying.
The following sections will give you a complete and I hope clear explanation of what cause jerky playback, and how ReClock will try to solve these problems.
The last section will give you the instructions on how to install and use ReClock.
----------------------------------------------------------------------------------------------------------------------------------------
The not so great history of frame rates
----------------------------------------------------------------------------------------------------------------------------------------
In basic terms, a video can be thought of as being made up of numerous snapshots, called frames. The frame rate is the number of frames displayed each second
As you know there exist 3 common broadcasting formats: cinema, TV, and computers
Cinema is the oldest. It is the format of the movies you see in your favourite theater. Cinema movies play at 24 frames per second ( fps). It’s very simple: every 1/24th of a second, your see a new frame. This is also called “progressive scan”.
A television, however, does not deal with video in terms of frames. Instead, it displays video using half-frames, called fields. Each frame contains exactly two fields. One field is made up of the odd horizontal lines in a frame. This is called the odd field or the top field since it contains the top line of the image. The other field is made up of the even horizontal lines in a frame. This is called the even field or bottom field. This way to broadcast video is called “interlaced scan”
Now there are three common TV standards: PAL, SECAM and NTSC. All of them use “interlaced scan”.
Let’s start with PAL, which is the European TV standard. It is also used for DVD and DIVX material. PAL material is played at 25 fps (or 50 fields per second). You see the first problem here: how can we play a 24 fps movie on a 50 fields per second PAL TV? Well first of all, we can present each movie frame two consecutive times to make the movie play at 48 fields per second. But playing the movie like this would give jerky playback every second because one movie picture would be missing. So the movie is just played 50/48 times faster to match 50 fields per second. So a cinema movie that has duration of 60mn plays on PAL in 57mn36 seconds. That’s why movies you watch on your PAL TV are always a bit shorter in time.
SECAM is the French brother of PAL and works exactly the same way. It is still used in France because it gives better colours when broadcasted by radio waves (less sensitive to noise).
And now here is NTSC, the American brother of PAL. NTSC is also used for DVD and DIVX material, and plays somewhere near 29.97 fps (to be exact it is 4.5 MHz/286/525). You see a bigger problem here. How can we play cinema movies on NTSC. Accelerate them? Sure no, because you would notice that the film plays much too fast (a 60mn movie would play in 48mn3s). So NTSC engineers came with a solution called “telecine” or “3:2 pulldown” which is quite complicated. To convert a film that runs at 24 fps to run at 29.97 fps, it is first necessary to slow down the video by 0.1% to 23.976 fps. Then approximately 6 frames are added to the video each second, bringing the frame rate to 29.97 fps. This is done by adding one extra frame to each group of 4 film frames. Although they could simply duplicate 1 out of every 4 frames to produce the extra frame, this method is not used. This is because the duplication of one frame would cause that frame to be displayed for twice as long as the other 3 frames, which leads to jerkier motion. Fortunately, film producers can make use of the field-based nature of video to more gradually introduce the extra frame. Instead of adding a whole new frame at once, 2 fields are introduced separately to each group of 4 film frames. Since 2 fields make up a frame, this method is equivalent to adding 1 new frame. However, since the 2 duplicated fields are not added at the same time, this reduces the jerkiness of the video.
Let’s finish with computers. Computers are quite simple, they just do work like cinema and use “progressive scan”. But they use many more frame rates: 60 Hz, 75 Hz, 85 Hz, 100 Hz when watching your monitor, 50 Hz when connected to a PAL TV, and 60 Hz when connected to a NTSC TV. To obtain a smooth playback on a PC you just have to make sure that your video card uses a refresh rate that is an exact multiple of the movie you play. You can already see that PAL can be played fine at 50 Hz, 75 Hz or 100 Hz, but NTSC cannot be played without begin jerky because all we have is 60 fps which is not a multiple of 29.97 fps.
----------------------------------------------------------------------------------------------------------------------------------------
The nightmare of badly born DIVX
----------------------------------------------------------------------------------------------------------------------------------------
DIVX for the most are created from DVD material, and DVD material generally comes from movie material.
DIVX created from PAL material are generally fine, because they were created from 24 fps material simply accelerated to 25 fps or from direct 25 fps material. PAL is a good guy.
And now you have telecine for NTSC. Since telecine can only be displayed correctly on “interlaced scan” hardware, it must be removed for PC playback. This operation is called “inverse telecine”. Doing this on a film will revert the frame rate of the movie to 23.976 fps. Funny, but … jerky on every PC you will use to play the movie.
Some people that create DIVX from NTSC don’t even know that inverse telecine must be done. So those DIVX stays at 29.97 fps and will have artefacts when watched on your PC because interlacing artefacts do not compress well at all.
And to add another thing to the story, some DIVX has sound and movie sync problems that are solved by … modifying the frame rate a little bit so the movie duration matches the sound track duration. This is a quick and dirty way to do it. Imagine a 25 fps DIVX that is modified to play at 25.001 fps; well every 1000 frames (that’s only 40 seconds) the playback will become jerky.
----------------------------------------------------------------------------------------------------------------------------------------
The bigger nightmare of PC hardware
----------------------------------------------------------------------------------------------------------------------------------------
When you connect your PAL DVD player to your TV, things are really simple. Your player read the movie from the disc at 25 fps, and sends the signal to the TV at 25 fps.
Now imagine that your player is a little too fast and send the movie to the TV at 25.01 fps. What will happen? Jerkiness? No … In fact your TV is smart, and will stay synchronised with your player as long at the player plays near 25 fps. To be more precise no player in the world plays the movie exactly at 25 fps because clocks are never accurate. So every player play the movie “near” 25 fps, but this is no problem for your TV since it is locked to the video signal it receive.
Now when you play a DIVX on your PC and watch it on your PC what happens? First of all, if the refresh rate of your monitor is not a multiple of the frame rate of your DIVX, jerkiness will happen for sure. Do you remember that DIVX can be 24 fps, 25 fps, 23.976 fps, 29.97 fps, or even 25.001 fps? This is the first and main cause of jerky playback.
The other source of jerkiness is much more subtle and harder to understand. Suppose you play a 25 fps movie on you PC. Well your PC isn’t smarter that any DVD player, it will play it “near” 25 fps because it uses its internal clock, which is inaccurate. But it should not be a problem because DVD players also do that? Bad luck, it is a very big problem, because your video card does not synchronise its speed with the speed of the movie like a TV would do with a DVD player. In a PC the clocks used in the video card (to show the video) and in the PC (to play the video) are completely distinct, thus there always is deviation between them, and then jerkiness is inevitable.
----------------------------------------------------------------------------------------------------------------------------------------
The better history of DirectShow
----------------------------------------------------------------------------------------------------------------------------------------
DirectShow is the DirectX component that plays or record video and audio on your PC. DirectShow contains many modules called “filters” and connect them in a “filter graph” to finally render the movie.
Let’s take an example, with the steps needed to play a DIVX movie:
- First you need to demux the audio and video from the AVI file: one filter will do that and will produce two streams (audio + video)
- Then you need to decode audio stream (MP3 for example): a MP3 decoder filter will do that
- You also need to decode video: a DIVX decoder filter will do that
- You must render the decoded movie in a window: a video renderer filter is needed
- You must play decoded audio: an audio renderer is used.
DirectShow was cleverly designed because it will automatically search and find what filters are the best to render a movie. For example, the audio and video renderers are completely generic (they are provided by Microsoft) and will eat the output of every decoder filter in the world.
That’s one reason why there exist many DIVX players out there. A player is only a nutshell where filter graphs are built and run.
Now, DirectShow has another interesting feature. When building a filter graph, it set up a “reference clock” that is used to provide a unique time to all the filters in the graph. All filters will play their stuff at the speed of the reference clock.
The default reference clock in DirectShow is provided by the Microsoft sound renderer. Why? Because in order to play sound correctly, your sound card must receive samples exactly at the speed they will be played. So the default reference clock is in fact synced to a hardware clock somewhere in your sound card. Video frames just follow this clock, making jerkiness inevitable.
You may ask why Microsoft made this choice. They could have chosen to sync the reference clock to the video and all would be nice. I suppose they didn’t for at least two reasons:
- Video cards do not have a high-resolution hardware timer available to make a clock.
- Sound playback would become problematic since the sound card would not receive its samples at the speed they would be played. So the sound would not stay synchronised with video
----------------------------------------------------------------------------------------------------------------------------------------
Here comes ReClock
----------------------------------------------------------------------------------------------------------------------------------------
Now I think you understand what does ReClock. It provides a reference clock that is synchronised with your video hardware. How? By replacing entirely the default sound renderer with a new rewritten DirectShow filter that is somehow cleverer.
But by doing so, ReClock must solve the two problems we saw in the last section:
- Video cards do not have a high-resolution hardware timer available to make a clock: well, this is not completely true, since many of them have something that will help us. ReClock provides a reference clock based on a high-resolution timer based on hardware on your motherboard or your processor. Let’s call this clock the “system clock”. Then, ReClock will correct the system clock with information gathered in real time from your video card if they are available. How it does that will be my little secret
- Sound playback would become problematic: this is true. How can we solve that? By varying the speed of the sound in real time to force the sound to stay in sync with the video. This is another reason why we replace the sound renderer with our own one. There are two ways to change sound speed: playback speed and pitch. Normally, ReClock will choose to change the pitch of the sound in real time by adjusting the audio clock because it’s quite easy to do and does not degrade too much sound quality. It also allows very fine tuning on the video vs. sound synchronisation. This will however change a little bit the sound you will hear, but your ears should not notice that with such a low correction. Starting with version 1.4, you can also ask ReClock to combine audio pitch change with audio time stretching witch allow to change the playback speed without noticeable pitch artefacts.
Another thing that does ReClock is to change the global playback rate of the movie in order to match its frame rate to a multiple of the refresh rate of your monitor. Here is how it does that:
- CINEMA mode is detected if the monitor has a refresh rate that is a multiple of 24 Hz (72 Hz, etc…) and if the movie has a frame rate between 23.75 and 24.25. Then the playback rate of the movie (including sound) is modified to match exactly 24 fps.
- PAL mode is detected if CINEMA mode wasn’t possible and if the monitor has a refresh rate that is a multiple of 25 Hz (50 Hz, 75 Hz, 100 Hz, etc…) and if the movie has a frame rate between 23.75 and 25.25. Then the playback rate of the movie (including sound) is modified to match exactly 25 fps.
- NTSC mode is detected if the monitor has a refresh rate that is a multiple of 30 Hz (60 Hz, 120 Hz, etc…). Then the playback rate of the movie (including sound) is modified to match exactly 30 fps.
- CUSTOM mode is detected when the frame rate of the movie +/- 2% is a multiple of the monitor refresh rate. Then the playback rate of the movie (including sound) is modified to match exactly a multiple of the monitor refresh rate.
Finally if nothing matched, ReClock will try to match the playback rate is not modified, but the reference clock is still synchronised to the video card in order to obtain a stable clock.
Side note: you may ask if NTSC will work well with TV since PC does 30 fps where the TV wants 29.97 fps. That’s a good question to which I do not have a complete response, but strangely I observed that when I use ReClock with the excellent TvTool in NTSC mode with a GeForce 3, I get a clock correction that make the reference clock work near … 29.97 fps. So it seems that when the PC uses TV out in NTSC mode, the refresh rate is not 60 Hz, but 29.97*2 Hz, but I’m not sure at all of that, since it may be a coincidence. Anyway playing NTSC at 30 fps on a NTSC TV should not be a problem; as you may know NTSC was originally a black/white standard at 30 Hz that became 29.97 Hz for technical reasons when colour appeared.
So by adjusting the reference clock to match your video card, adjusting the sound to stay in sync with picture, and modifying the global playback rate, ReClock should allow a smooth movie experience on your monitor and even on your TV.
But as I said before, ReClock will not work with all PC because it uses some functions that are not available on all of them. Firstly your PC must support high-resolution timers (nearly every modern PC has them). Secondly, your video card must support some special calls. I know that most nVidia, ATI, Intel i815 and Matrox G200 do support those calls, but some cheaper or older cards may not. If those functions are not supported, ReClock will not load at all or will display an error message and the Microsoft audio renderer will be used.
Moreover, ReClock has some constraints you need to understand:
- ReClock requires DirectX 9.0 or later.
- ReClock will load and work only if your movie has sound, because ReClock is an audio renderer.
- ReClock will not always find the frame rate of the material. For example streaming will never be supported.
- When your run ReClock for the first time for a specific resolution and refresh rate, the reference clock will be inaccurate during the first minutes of playback while being corrected. This can cause jerky playback at the beginning of the movie. The time to obtain an accurate clock will depend on many factors (initial error of clock, PC speed …). During this period, you will see a flashing yellow/red icon in the system tray. After this adjustment the icon will become green (or yellow), and ReClock will store the correction in the registry, so when you will open another media, the clock correction parameters will be retrieved.
- Changing the playback speed can be noticeable on sound especially when 23.976 fps material is up rated to 25 fps. Doing so will accelerate the sound by 4%, and sound will seem to be a little high pitched. If you don’t like that, you can enable the “audio time stretching” function (explained later in this document).
----------------------------------------------------------------------------------------------------------------------------------------
Let’s be a little more technical
----------------------------------------------------------------------------------------------------------------------------------------
Now that you know what DirectShow is and what does ReClock, I will explain here some technical knowledge that will be useful to fully use ReClock.
Originally, Microsoft designed one DirectShow audio renderer called the “WaveOut renderer”. This renderer was based on an old audio technology dating back to Windows 3.0 (let’s call it the Wave API). Later, when DirectX started to emerge, Microsoft designed a new audio renderer called the “DirectSound renderer” which is based on DirectSound technology (the DirectSound API). The later should provide better sound quality with less CPU overhead and less latency. On a “normal” PC with DirectX 9.0 or later, the “DirectSound renderer” is generally automatically used.
At the same time DirectSound emerged, PC started to be used to play DVD’s. As you know, nearly all DVD’s have a 5.1 Dolby or DTS soundtrack (i.e. 6 independent audio channels), that can be played on multiple speakers by your PC and the appropriate audio card, or send to an external AC3 decoder/amplifier with an SPDIF compatible soundcard. You can see those are two different ways to handle sound. When you play some media (MP3, DIVX, and DVD) and your soundcard provides directly the sound to the speakers, you are using PCM (Pulse Coded Modulation) sound, and I will call this “PCM mode”. When you are sending an AC3 or DTS stream over SPDIF to an external decoder/amplifier you’re doing AC3 pass-through mode, and I will call this “SPDIF mode”.
PCM and SPDIF modes are very different by nature:
- In PCM mode, ReClock receives the raw audio waves in digital form and transmits them to the audio card, but it can tweak them because it understands what is inside. So the sound can be reshaped (pitch or playback rate can be changed, and dynamic compression can be applied). Altering the playback rate allows ReClock to re sync the sound with the video. Playing a video at 25 fps with a sound that was “designed” to play at 24 fps is no problem.
- Now in SPDIF mode, ReClock receive a binary encoded AC3 or DTS stream and transmit it to the external decoder/amplifier via SPDIF link. But it can’t understand what is inside because this content needs to be decoded to be understood and played (that’s the purpose of an AC3 decoder). So how can ReClock alter the playback rate in SPDIF? Well, in fact it can’t do it nicely. AC3 frames are divided into chunks that have a sound duration of 32ms (a chunk is also called a frame or packet). Each frame is independent of the previous and of the next. To shorten the sound, ReClock drop frames, and to lengthen the sound, ReClock repeat frames. This is called the drop/repeat algorithm. Usually dropping or repeating an AC3 frame is not noticeable if it does not happen too often (remember a frame is only 32ms long), but it is not possible to play a media at a speed that is very far from its original speed (playing a 24 fps file at 25 fps would make a frame drop every 25 frame and it is very noticeable). That’s why in SPDIF mode, ReClock will only accept to alter the speed of media files very slightly (it won’t try to accelerate a 24 fps file to 25 fps).
Now DirectShow also have its oddities. When the “WaveOut renderer” was the only way to play sound, it was extended to handle SPDIF so it could take PCM or SPDIF input. When the “DirectSound renderer” appeared, it was plagued with problem in SPDIF handling, and many audio card manufacturers also had problems to handle SPDIF with DirectSound. So, this renderer is not commonly used to handle SPDIF. From this, you see that the best way to handle PCM sound is to use DirectSound and the best way to handle SPDIF sound is to use WaveOut. So, as ReClock needs to handle both PCM and SPDIF modes, it provides you the two worlds: WaveOut API and DirectSound API, so you have the choice. In this regard, ReClock is a hybrid audio renderer. Please have a look on a section “How to optimize SPDIF output” for a method that will allow you to minimize drop/repeats in SPDIF mode.
Version 1.6 also comes with a new audio renderer called "Kernel Streaming". This API is the lower one available in Windows to produce sound. It talks directly to audio WDM cards drivers, and has many advantages :
- lower possible audio latency
- complete bypass of the windows internal audio resampler that degrades sound quality
... and some disadvantages :
- no audio volume control
- will not work with every soundcard in ReClock especially when streaming AC3 sound
So if you want top notch audio quality, you can use Kernel Streaming with ReClock.
Let’s now speak about video renderers inside DirectShow. Just like for sound, Microsoft made with time different versions of video renderers:
- First the “Old renderer”: it uses old video technology is slow and should not be used anymore.
- Then the “Overlay mixer” came: this one uses “overlay” capability of video cards based on DirectDraw. Overlay is a technology that allows an application to display efficiently and with good quality pictures on screen but it has limitations: not all cards can do it, and you are limited to one video on screen (one overlay) at one time; also overlay can cause problems when using TV output. Besides its limitations, the overlay mixer is still widely used today
- When Windows XP came out, the Video Mixing Renderer appeared, also called the “VMR7”: this one is based on Direct3D, and has no limitations. But your card must be able to handle it (recent card and recent drivers). VMR7 is used by Windows Media Player on XP.
- And finally when DirectX 9.0 appeared, a second and distinct version of the VMR came out and this one is called the “VMR9”: it is an up rated VMR7 renderer with even more capabilities. You must use a good player if you want to try this one (for example Zoom Player)
- Some players like BSPlayer have their own video renderer (based on overlay for BSPlayer).
[Профиль]  [ЛС] 

Иван Баттхэдхарма

Стаж: 14 лет 9 месяцев

Сообщений: 347

Иван Баттхэдхарма · 06-Фев-10 13:03 (спустя 31 мин.)

Ага.. Появилась темка..
Итак, непонятки - нахрена этот реклок нужен, если есть синхрокоды для совмещения аудио+видео, а для аудиоаппаратуры существуют экстендовые клоки\вордклоки?
Все эти линии давно существуют в профи девайсах и легко портируются.. нахрена огород городить со всякой "кухонной" самопальщиной?
[Профиль]  [ЛС] 

G-Man90

Стаж: 15 лет 2 месяца

Сообщений: 1574

G-Man90 · 06-Фев-10 13:13 (спустя 9 мин.)

BalticX писал(а):
К тому же ReClock позволяет вывод звука организовать через Kernel Streaming и в настройке "для аудио" так прямо и пишет в окне мониторинга: kernel streaming, bit exact. Измерения, проведённые придирчивыми юзерами показали, что и впрямь цифра получается та же самая что и у настроенного на точное воспроизведение Foobar2000. Вот только при работе последнего (и других подобных проигрывателей) ничего не предпринимается для синхронизации - "ходьбы в ногу".
тогда вопрос: в ASIO 2.0 предпринимаются какие-либо действия для синхронизации?
[Профиль]  [ЛС] 

Иван Баттхэдхарма

Стаж: 14 лет 9 месяцев

Сообщений: 347

Иван Баттхэдхарма · 06-Фев-10 13:15 (спустя 1 мин.)

G-Man90 писал(а):
действия для синхронизации
синхронизации чего с чем?
[Профиль]  [ЛС] 

G-Man90

Стаж: 15 лет 2 месяца

Сообщений: 1574

G-Man90 · 06-Фев-10 13:19 (спустя 3 мин.)

Иван Баттхэдхарма писал(а):
синхронизации чего с чем?
это не ко мне вопрос.
BalticX писал(а):
Вот только при работе последнего (и других подобных проигрывателей) ничего не предпринимается для синхронизации - "ходьбы в ногу".
[Профиль]  [ЛС] 

Иван Баттхэдхарма

Стаж: 14 лет 9 месяцев

Сообщений: 347

Иван Баттхэдхарма · 06-Фев-10 13:21 (спустя 2 мин.)

G-Man90 писал(а):
не ко мне вопрос
так а про что ты спрашивал?
что с чем синхронить собираешься?
[Профиль]  [ЛС] 

G-Man90

Стаж: 15 лет 2 месяца

Сообщений: 1574

G-Man90 · 06-Фев-10 13:29 (спустя 7 мин., ред. 06-Фев-10 13:29)

Иван Баттхэдхарма
да я-то пока только пытаюсь разобраться.
А вот уважаемый BalticX явно преподносит эту самую возможность "синхронизации" как преимущество ReClock'а перед "foobar2000 и другими подобными проигрывателями", в которых такой возможности нет.
Т.е. имеется ввиду сравнение foobar2000+KS вывод и ReClock+KS вывод. А как быть с foobar2000+ASIO? (вопрос к BalticX)
[Профиль]  [ЛС] 

BalticX

Top Bonus 01* 300GB

Стаж: 15 лет 3 месяца

Сообщений: 1718

BalticX · 06-Фев-10 13:31 (спустя 2 мин.)

Думаю, тут самый верный путь - попробовать в правильном конфиге и решить для себя: нужен-не нужен. Если не нужен, так и забыть, а нужен - разбираться.
Обладатели профи девайсов тоже, кстати, пользуют. Только они пытаются совместить - усидеть на двух стульях сразу: видео и аудио.
скрытый текст
Now, DirectShow has another interesting feature. When building a filter graph, it set up a “reference clock” that is used to provide a unique time to all the filters in the graph. All filters will play their stuff at the speed of the reference clock.
The default reference clock in DirectShow is provided by the Microsoft sound renderer. Why? Because in order to play sound correctly, your sound card must receive samples exactly at the speed they will be played. So the default reference clock is in fact synced to a hardware clock somewhere in your sound card. Video frames just follow this clock, making jerkiness inevitable.
You may ask why Microsoft made this choice. They could have chosen to sync the reference clock to the video and all would be nice. I suppose they didn’t for at least two reasons:
- Video cards do not have a high-resolution hardware timer available to make a clock.
- Sound playback would become problematic since the sound card would not receive its samples at the speed they would be played. So the sound would not stay synchronised with video
Now I think you understand what does ReClock. It provides a reference clock that is synchronised with your video hardware. How? By replacing entirely the default sound renderer with a new rewritten DirectShow filter that is somehow cleverer.
But by doing so, ReClock must solve the two problems we saw in the last section:
- Video cards do not have a high-resolution hardware timer available to make a clock: well, this is not completely true, since many of them have something that will help us. ReClock provides a reference clock based on a high-resolution timer based on hardware on your motherboard or your processor. Let’s call this clock the “system clock”. Then, ReClock will correct the system clock with information gathered in real time from your video card if they are available. How it does that will be my little secret
- Sound playback would become problematic: this is true. How can we solve that? By varying the speed of the sound in real time to force the sound to stay in sync with the video. This is another reason why we replace the sound renderer with our own one. There are two ways to change sound speed: playback speed and pitch. Normally, ReClock will choose to change the pitch of the sound in real time by adjusting the audio clock because it’s quite easy to do and does not degrade too much sound quality. It also allows very fine tuning on the video vs. sound synchronisation. This will however change a little bit the sound you will hear, but your ears should not notice that with such a low correction. Starting with version 1.4, you can also ask ReClock to combine audio pitch change with audio time stretching witch allow to change the playback speed without noticeable pitch artefacts.
Another thing that does ReClock is to change the global playback rate of the movie in order to match its frame rate to a multiple of the refresh rate of your monitor. Here is how it does that:
- CINEMA mode is detected if the monitor has a refresh rate that is a multiple of 24 Hz (72 Hz, etc…) and if the movie has a frame rate between 23.75 and 24.25. Then the playback rate of the movie (including sound) is modified to match exactly 24 fps.
- PAL mode is detected if CINEMA mode wasn’t possible and if the monitor has a refresh rate that is a multiple of 25 Hz (50 Hz, 75 Hz, 100 Hz, etc…) and if the movie has a frame rate between 23.75 and 25.25. Then the playback rate of the movie (including sound) is modified to match exactly 25 fps.
- NTSC mode is detected if the monitor has a refresh rate that is a multiple of 30 Hz (60 Hz, 120 Hz, etc…). Then the playback rate of the movie (including sound) is modified to match exactly 30 fps.
- CUSTOM mode is detected when the frame rate of the movie +/- 2% is a multiple of the monitor refresh rate. Then the playback rate of the movie (including sound) is modified to match exactly a multiple of the monitor refresh rate.
Finally if nothing matched, ReClock will try to match the playback rate is not modified, but the reference clock is still synchronised to the video card in order to obtain a stable clock
[Профиль]  [ЛС] 

Иван Баттхэдхарма

Стаж: 14 лет 9 месяцев

Сообщений: 347

Иван Баттхэдхарма · 06-Фев-10 13:34 (спустя 3 мин.)

BalticX писал(а):
усидеть на двух стульях сразу: видео и аудио
что за чепуха?
а для кого синхрокоды придуманы?
[Профиль]  [ЛС] 

BalticX

Top Bonus 01* 300GB

Стаж: 15 лет 3 месяца

Сообщений: 1718

BalticX · 06-Фев-10 13:45 (спустя 10 мин., ред. 06-Фев-10 13:45)

сразу предупреждаю - я не энциклопедия, чтобы давать ответы на все вопросы.
Что делает ASIO можно посмотреть в wiki. Я вообще у себя не пользуюсь ASIO, т.к. на моей Essence ST "фирменное" ASIO от производителя режет частоту на уровне 44.1. Возможно, и многие другие удивятся, когда померяют свои "асио". ASIO4ALL так же режет на уровне 44 или 48 (не помню). И уж звучат они все точно не лучше R/KS на аппаратуре без clock sync, каковая у большинства юзеров.
G-Man90 писал(а):
А вот уважаемый BalticX явно преподносит эту самую возможность "синхронизации" как преимущество ReClock'а перед "foobar2000
это гипотеза, раз уже некоторые предпочитают требовать "доказательств", чем взять да послушать.
читайте не меня, а мануал и комментируйте конкретные цитаты оттуда, если там кому видится чепуха.
[Профиль]  [ЛС] 

Иван Баттхэдхарма

Стаж: 14 лет 9 месяцев

Сообщений: 347

Иван Баттхэдхарма · 06-Фев-10 13:49 (спустя 4 мин.)

BalticX писал(а):
Essence ST
ты ещё бы реалтек заюзал..
ф помойку, ибо к звуку он не имеет никакого отношения..
BalticX писал(а):
ASIO от производителя режет частоту
ещё раз - он не создан для звука, как и все прочие асусы..
BalticX писал(а):
комментируйте конкретные цитаты оттуда
там нет технических подробностей, что камментить?
[Профиль]  [ЛС] 

G-Man90

Стаж: 15 лет 2 месяца

Сообщений: 1574

G-Man90 · 06-Фев-10 13:52 (спустя 2 мин., ред. 06-Фев-10 14:12)

BalticX писал(а):
на аппаратуре без clock sync, каковая у большинства юзеров.
это можно как-то проверить? Т.е. наличие clock sync
BalticX писал(а):
режет частоту на уровне 44.1
режет частоту на 44.1 кГц или на уровне аудио с частотой дискретизации 44.1 (т.е на 22.05 кц)?
[Профиль]  [ЛС] 

megane68

Стаж: 16 лет 5 месяцев

Сообщений: 19966

megane68 · 06-Фев-10 14:01 (спустя 9 мин., ред. 06-Фев-10 16:23)

BalticX
Создать тему надо было уже давно. Я всегда готов к конструктивному и продуктивному сотрудничеству. Однако пока я никаких перспектив, по крайрей мере для себя не вижу. Не из за того, что у меня проф карта с синхронизатором. Можно например использовать технологию на ноуте или где то еще, когда нет профессионального оборудования, но не буду забегать вперед.
G-Man90 писал(а): писал(а):
megane68 извиняюсь, что не в тему
Тему уже создали по RC - это хорошо. Решил все- таки перенести свой пост из обсуждения foobar2000, что бы изложить свою точку зрения. Надеюсь никто не против.
Уже говорилось, что нет хоть мало мальски понятного описания работы RC, это и дало повод для того, что бы усомниться в корректности заявлений о синхронизации. Я так понимаю, что пощупать и проверить это всегда можно только опытным путем. А именно на сколько корректно это делается.
Так вот самая важная проблема проявилась как и предполагалось со звуком при прослушивании.
Обнаружилось следующее:
При воспроизведении разных форматов, RC меняет звучание, естественно если сравнивать его с тем же треком, того же формата без него. Так вот не буду рассусоливать, в этом может убедится любой, кто заинтересуется RC, на личном опыте.
У меня есть возможность не переключая туда сюда провода и не тратя понапрасну время, в этом убедится.
Есть еще одна заморочка: на всех форматах наблюдается нечто подобие нормализации, то есть при прослушивании классики например, режутся пиковые моменты в тех местах, где идет резкий всплеск всего оркестра.
Не буду утомлять долгими рассказами, убедитесь сами. Мне же, все перечисленное дает повод сомневаться в корректности работы данного устройства, потому что при синхронизации звук не должен меняться. Он должен приобретать скорее чистоту звучания и объем, чего в lossless через RC вообще не наблюдается.
Отсюда следует, что сама задумка может быть для каких- то целей и хорошая, но не данный "агрегат".
Для любого любителя музыки, ее звучание должно быть максимально приближенным к тому, которое было записано на CDDA (если мы говорим о прослушивании такового). RC же эту функцию не выполняет, меняя звучание CDDA, и это совершенно точно.
BalticX
Не говорите ничего о том, откуда я типа взял, что звучание должно быть именно таким как я считаю. Уж поверьте, в данном случае на слово, что у меня есть CDDA, которые я знаю как должны звучать, хотя бы потому, что сам участвовал в записи таковых.
P.S. Задумка может быть и хорошая, но реализация явно хромает, а в таких случаях когда нет никаких документальных подтверждений о работе устройства, я полагаюсь только на свой слух и качество аппаратуры.
[Профиль]  [ЛС] 

BalticX

Top Bonus 01* 300GB

Стаж: 15 лет 3 месяца

Сообщений: 1718

BalticX · 06-Фев-10 14:14 (спустя 12 мин., ред. 06-Фев-10 14:18)

Иван Баттхэдхарма писал(а):
там нет технических подробностей, что камментить?
принципы работы там изложены
Цитата:
ты ещё бы реалтек заюзал
не все могут на феррари ездить. Полторы штуки на линксту я выкидывать не собираюсь. Как и большинство. Тема не для проф карт, говорил уже.
G-Man90 писал(а):
это можно как-то проверить? Т.е. наличие clock sync
сперва хотелось бы понять в точности о чём речь, потом засечь - для того и топик. Кабы я всё знал, так просто балдел бы втихомолку.
Цитата:
режет частоту на 44.1 кГц или на уровне аудио с частотой длискретизации 44.1 (т.е на 22.05 кц)?
второе.
даже хуже
megane68 писал(а):
Для любого любителя музыки, ее звучание должно быть максимально приближенным к тому, которое было записано на CDDA (если мы говорим о прослушивании такового). RC же эту функцию не выполняет, меняя звучание CDDA, и это совершенно точно
не сходится с
G-Man90 писал(а):
Ну что он воспроизводит Bit Exact - это точно, только что проверил.
megane68 писал(а):
в таких случаях когда нет никаких документальных подтверждений о работе устройства
собственно, топик как раз для того, чтобы выяснить инструментально технические аспекты работы.
Я в этом не достаточно опытен, увы - особенностей архитектуры IBM PC толком не знаю, как и в программных средствах измерения не искушен.
[Профиль]  [ЛС] 

G-Man90

Стаж: 15 лет 2 месяца

Сообщений: 1574

G-Man90 · 06-Фев-10 14:16 (спустя 1 мин.)

G-Man90 писал(а):
BalticX писал(а):на аппаратуре без clock sync, каковая у большинства юзеров.
это можно как-то проверить? Т.е. наличие clock sync
BalticX писал(а):
сперва хотелось бы понять в точности о чём речь
т.е. Вы сами не знаете что подразумевается под clock sync?? или как это понимать?
[Профиль]  [ЛС] 

Иван Баттхэдхарма

Стаж: 14 лет 9 месяцев

Сообщений: 347

Иван Баттхэдхарма · 06-Фев-10 14:17 (спустя 1 мин.)

BalticX писал(а):
принципы работы там изложены
плевать на принципы...
нужны блок-схемы, конкретности.. а их нет..
[Профиль]  [ЛС] 

megane68

Стаж: 16 лет 5 месяцев

Сообщений: 19966

megane68 · 06-Фев-10 14:24 (спустя 6 мин., ред. 06-Фев-10 14:24)

BalticX писал(а):
не сходится с
Конечно не сходится, а почему никто толком не объяснял еще. Одно могу сказать, что я буду очень благодарен человеку, который это объяснит. На мой взгляд на то есть причины, если есть изменение в звуке.
скрытый текст
Мне умельцы одни левую винду на спор так подогнали, что все контрольные суммы стали как на оригинальном образе. Для меня это не понятно, а для них раз плюнуть. Может они фокусники? От этого винда не стала "оригинальной".
[Профиль]  [ЛС] 

BalticX

Top Bonus 01* 300GB

Стаж: 15 лет 3 месяца

Сообщений: 1718

BalticX · 06-Фев-10 14:27 (спустя 3 мин.)

Господа, ещё раз - экзамены сдавать никому не собираюсь. Если бы я сам начал требовать объяснений от автора, он бы в лучшем случае послал меня, и я с чистой совестью остался бы... с чистой совестью. Полагаю, это глупо. Автор имеет право не раскрывать сви know how
G-Man90
я выше привёл график для ASIO/KS моей карты
megane68 писал(а):
Мне умельцы одни левую винду на спор так подогнали, что все контрольные суммы стали как на оригинальном образе
автор не ставил целью звук подгонять. Как уже писал выше - цель была согласовать видео, звук был вторичен (но kS, к счастью, предусмотрен)
[Профиль]  [ЛС] 

Иван Баттхэдхарма

Стаж: 14 лет 9 месяцев

Сообщений: 347

Иван Баттхэдхарма · 06-Фев-10 14:38 (спустя 10 мин.)

BalticX писал(а):
Автор имеет право не раскрывать сви know how
но принципиальными и блок-схемами он обязан делиться и открывать их..
[Профиль]  [ЛС] 

G-Man90

Стаж: 15 лет 2 месяца

Сообщений: 1574

G-Man90 · 06-Фев-10 14:41 (спустя 2 мин.)

В общем, что как работает и почему ReClock лучше foobar2000 с любыми интерфейсами вывода - объяснять никто не будет. И почему лично я разницы на X-Fi XtremeMusic не слышу - тоже никто не объяснит.
Извините, но мне такое не нужно. Я лучше буду юзать foobar2000 с выводом через ASIO (он на моей карте к счастью не кривой) а не заморачиваться со всякими видеоплеерами-фильтрами дающими сомнительный выигрыш в качестве.
Кто слышит разницу - удачи, заморачивайтесь дальше, если эта разница важнее удобства воспроизведения музыки.
[Профиль]  [ЛС] 

megane68

Стаж: 16 лет 5 месяцев

Сообщений: 19966

megane68 · 06-Фев-10 15:27 (спустя 45 мин., ред. 06-Фев-10 15:27)

BalticX писал(а):
автор не ставил целью звук подгонять. Как уже писал выше - цель была согласовать видео, звук был вторичен (но kS, к счастью, предусмотрен)
Без обид, что бы не понеслось....
Я и другие не старались тебя экзаменовать, просто им важна суть использования RC. Раз они в этой теме, то наверное хотят истину выяснить. Если, как писал G-Man, поток совершенно идентичен с foobar2000 и звук он не портит и не улучшает, то зачем его использовать? Если же он влияет на качество звука, то в какую сторону?
Согласен, что вопросы может и не к тебе... Ну а кого спрашивать, если автор такой молчун? Или боится, что его на чистую воду выведут? (Всего лишь предположение.)
Я убедился на личном опыте, что звук он меняет относительно самого носителя, а из этого следует, что он портит его, а не улучшает.
То, что смог, сделал и сказал по поводу работы RC. Кому нужно будет проверить правдивость моих слов, может сам в этом убедиться.
G-Man90
По поводу синхронизации в твоей карте. Наличие таковой у тебя должно быть прописано в паспорте или спецификации. Если нет, то нет.
скрытый текст
http://www. СПАМ
На сколько я понял нет!
[Профиль]  [ЛС] 

G-Man90

Стаж: 15 лет 2 месяца

Сообщений: 1574

G-Man90 · 06-Фев-10 15:29 (спустя 1 мин.)

megane68 писал(а):
На сколько я понял нет!
где ты там это увидел?
[Профиль]  [ЛС] 

BalticX

Top Bonus 01* 300GB

Стаж: 15 лет 3 месяца

Сообщений: 1718

BalticX · 06-Фев-10 15:39 (спустя 10 мин.)

G-Man90 писал(а):
заморачивайтесь дальше, если эта разница важнее удобства воспроизведения музыки
для меня именно так, но я не транс слушаю, правда.
megane68 писал(а):
Если же он влияет на качество звука, то в какую сторону?
послушал сейчас ещё раз через Foobar/KS. Звук заметно упрощённей, грубее. Выдёргивал из рипов видеоконцертов АС3 дороги, чтобы заресемплить как следует в 96. Слушал в распакованном в wave оригинальном виде в Фубаре - просто безнадёжно неслушабельно. В тоже время МРС/R даёт вполне комфортный и более живой звук с АС3 дороги при воспроизведении самого рипа (ReClock в режиме Slave to audio).
Короче, резюме будет следующее: всё это hardware depends - аппаратно зависимо. Ну ещё может зависеть от музыкального репертуара и тренировки слуха.
[Профиль]  [ЛС] 

G-Man90

Стаж: 15 лет 2 месяца

Сообщений: 1574

G-Man90 · 06-Фев-10 15:43 (спустя 3 мин., ред. 06-Фев-10 15:46)

BalticX писал(а):
для меня именно так, но я не транс слушаю, правда.
когда надо определить разницу в качестве, я сравниваю на различных музыкальных жанрах естественно, так что подобные намеки тут неуместны
BalticX писал(а):
Короче, резюме будет следующее: всё это hardware depends - аппаратно зависимо.
ну это с самого начала понятно было. Вопрос в другом - как определить, на каком устройстве ReClock может дать улучшение, а на каком - совершенно бесполезен.
[Профиль]  [ЛС] 

Иван Баттхэдхарма

Стаж: 14 лет 9 месяцев

Сообщений: 347

Иван Баттхэдхарма · 06-Фев-10 15:44 (спустя 47 сек.)

BalticX писал(а):
Выдёргивал из рипов видеоконцертов АС3 дороги, чтобы заресемплить как следует в 96. Слушал в распакованном в wave оригинальном виде в Фубаре - просто безнадёжно неслушабельно
ты ещё мп3 128 пересэмплируй..
или хотел взять гавно, разжать его и получить конфетку? бред какой..
[Профиль]  [ЛС] 

megane68

Стаж: 16 лет 5 месяцев

Сообщений: 19966

megane68 · 06-Фев-10 15:59 (спустя 15 мин., ред. 06-Фев-10 15:59)

G-Man90 писал(а):
где ты там это увидел?
Там об этом не написано, поэтому предположил. Если у тебя есть более подробное описание (спецификация к ней), то посмотри там. Если там не прописано, то скорее всего ее нет. А можно еще у производителя или у специалистов узнать. У тебя в ней есть же режим для проф записи!
G-Man90 писал(а):
ну это с самого начала понятно было. Вопрос в другом - как определить, на каком устройстве ReClock может дать улучшение, а на каком - совершенно бесполезен.
Я могу со 100%- ой уверенностью сказать, что ни на каком. Это мое мнение...
[Профиль]  [ЛС] 

Foxbatat

Стаж: 15 лет 1 месяц

Сообщений: 121

Foxbatat · 06-Фев-10 16:17 (спустя 18 мин.)

G-Man90 писал(а):
когда надо определить разницу в качестве, я сравниваю на различных музыкальных жанрах естественно, так что намеки тут неуместны
Я с ReClock'ом лучше различаю отдельные музыкальные инструменты. А для вас этот параметр может иметь значение, любитель транса?
megane68 писал(а):
G-Man90 писал(а):
Вопрос в другом - как определить, на каком устройстве ReClock может дать улучшение, а на каком - совершенно бесполезен.
Я могу со 100%- ой уверенностью сказать, что ни на каком. Это мое мнение...
Может из-за ReClock что-то теряется, чего я и так не услышу на тракте моего уровня. Пусть в этой неслышимой области ReClock творит что хочет, если в слышимой изменения радуют слух.
[Профиль]  [ЛС] 

BalticX

Top Bonus 01* 300GB

Стаж: 15 лет 3 месяца

Сообщений: 1718

BalticX · 06-Фев-10 16:18 (спустя 21 сек.)

G-Man90 писал(а):
Вопрос в другом - как определить, на каком устройстве ReClock может дать улучшение, а на каком - совершенно бесполезен
для этого надо расшифровать фразу "rate adaptation will still function and reference clock will be slaved to audio clock with a smooth algorithm"
авторское понятие reference clock
Now, DirectShow has another interesting feature. When building a filter graph, it set up a “reference clock” that is used to provide a unique time to all the filters in the graph. All filters will play their stuff at the speed of the reference clock.
The default reference clock in DirectShow is provided by the Microsoft sound renderer. Why? Because in order to play sound correctly, your sound card must receive samples exactly at the speed they will be played. So the default reference clock is in fact synced to a hardware clock somewhere in your sound card. Video frames just follow this clock, making jerkiness inevitable
что можно в данном случае считать за "rate adaptation"?
[Профиль]  [ЛС] 

Иван Баттхэдхарма

Стаж: 14 лет 9 месяцев

Сообщений: 347

Иван Баттхэдхарма · 06-Фев-10 16:31 (спустя 13 мин.)

BalticX писал(а):
sound card must receive samples exactly at the speed they will be played. So the default reference clock is in fact synced to a hardware clock somewhere in your sound card
ну правильно.. и херли тут реклочить?
разве в аудиоинтерфейсах не предусмотрены буфера, типа fifo и иных?
смысл этой кухни с реклоком?
всё это напоминает какой-то МЛМ - мтоды и представление девайса одинаковые..
- Чем ваш стиральный порошок лучше, чем магазинный?
- Он лучше!
[Профиль]  [ЛС] 

BalticX

Top Bonus 01* 300GB

Стаж: 15 лет 3 месяца

Сообщений: 1718

BalticX · 06-Фев-10 16:53 (спустя 22 мин., ред. 06-Фев-10 16:53)

Иван Баттхэдхарма
вы внимательней меня, я не прочитал на скорую руку. Тогда получается, что никакой специальной синхронизации Р не делает, а та, что упоминается, и так работает по дефолту.
Собственно, в окне монитора при работе видно, что корректировок клоков при работе в режиме аудио ноль (это меня всегда и смущало). Короче, гипотезу с синхронизацией можно окончательно отбросить.
Остаётся только организация внутренней буферизации, насколько я понимаю, а это уже привычный тупик, т.к. на выходе тот же bit exact, что и у прочих.
А сравнивал "битекзакты" только один человек, насколько мне известно, имеющий соответствующее дорогое оборудование Measuring XXHighEnd ...
[Профиль]  [ЛС] 
 
Ответить
Loading...
Error