Make NextInt less slow

About a 5% speedup on loading an arbitrary test file.
Make NextInt even less slow
Mark stuff not used outside of STS.cpp as static
Make the check for blank lines less horribly slow
Update CSRI name
Re-add the .sub extension for MicroDVD
DirectVobSubFilter: Fix a deadlock, Pt.1

File reloader thread causes a dead lock if

 a. the deconstruction of the filter is going, and its thread
    holds the critical section

..and...

 b. the file reloader thread can not yet finish setup and is
    blocked by the critical section.
BaseVideoFilter: Fix unwanted reconnection with input when output failed

Fixes an unwanted reconnection with input pin when output pin
connection failed to complete.

This often happens when connecting to Video Mixing Renderer.
BaseVideoFilter: Always return a list of output color spaces

Return a list of output color spaces even when we fail to get
upstream's preferred order.
DirectVobSubFilter: Reset the colorspace list when connection breaks

Is this correct to do when we're reconnecting?
BaseVideoFilter: Accept only those output colorspaces that are listed upstream.
BaseVideoFilter: Reject colorspace changes from downstream for now
BaseVideoFilter: Refactor CheckTransform
DVobSubFilter/STS: Fix colormatrix guessing in case of non set

Used to default to BT.601, now defaults to BT.709 or BT.601
depending on the resolution.
Pass through dwTypeSpecificFlags and dwInterlaceFlags
BVF/VSFilter: Pass through and actually use colorimetry information

This enables the usage of colorimetry information passed down the
filter chain from the decoder. Also sets range and colormatrix
from this information if available.

Currently limited to a white list of filters:
 - VMR7,9
 - EVR
 - madVR
BugFix: 32 bit int overflow.
 VSFilter: Fix and update the blacklist.

- Ensure the blacklisting is applied as soon as possible when VSFilter tries to join the graph.
- Fix the incorrect string comparisons, the application name is always lowercase.
- Add some apps that are known to have incompatibility with VSFilter.

This commit is based on a patch by clsid.

Backport of MPC-HC commit 1836020
VobSubFile: Use TRACE for debug messages

We don't want to spam the users with probably useless error messages.

Thanks to clsid.

Backport of MPC-HC commit 9f504fc
Subtitles: Make both DVD subtitles show in case of overlap

Makes behavior consistent with VLC and mplayer/libavcodec DVD
subtitle implementations. Sets the StopTime of the subtitle
before the same as the StartTime of the currently added DVD
subtitle.

Backport of MPC-HC commit f478e57