avformat/microdvd: skip BOM properly

The BOM is already skipped in the probe function, but not the header
read function. This could cause the header to be misparsed, such as
not interpreting the FPS line.
avformat/microdvd: export the declared frame rate

MicroDVD files are normally frame-based (i.e. there are no absolute
timestamps), but can have an optional frame rate header. If this
header is missing, the timestamps depend on the frame rate of the
video they were created for.

The demuxer will use a fallback frame rate if it's missing from the
header. Currently, applications using libavformat can't know whether
the time base is based on the fallback value, or if a frame rate
header was present.

This commit introduces a subfps AVOption for MicroDVD, and the
demuxer sets it if and only if a frame rate header was present.

Signed-off-by: Clément Bœsch <u@pkh.me>
lavu/log: add device categories

Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
lavd: add categories to device implementations

Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
lavd/avdevice: add device iterators

Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
avcodec/h263dec: Workaround H263 end padding bug

Fixes: H263PaddingBugFixVID_6647.MOV

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Merge remote-tracking branch 'lukaszmluki/master'

* lukaszmluki/master:
  lavd/avdevice: add device iterators
  lavd: add categories to device implementations
  lavu/log: add device categories

Merged-by: Michael Niedermayer <michaelni@gmx.at>
vf_frei0r: adjust error messages
vf_frei0r: prevent a segfault when filter parameters are not set
vf_frei0r: refactor library loading from env variable

strtok_r is not needed any more, so remove it from configure.
mathops: move macro to the only place it is used

This helps in disentangling lavf and lavc too.
Merge commit '8accddeb5806cd98e3803b4ddf2a2ef576d0e4d9'

* commit '8accddeb5806cd98e3803b4ddf2a2ef576d0e4d9':
  vf_frei0r: adjust error messages

Conflicts:
	libavfilter/vf_frei0r.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
Merge commit '4e0be9c86f2003dd3ba2eb8fad01e8d0e538075e'

* commit '4e0be9c86f2003dd3ba2eb8fad01e8d0e538075e':
  vf_frei0r: prevent a segfault when filter parameters are not set

Merged-by: Michael Niedermayer <michaelni@gmx.at>
Merge commit '61b323ce7c7cdc101eadfd7de2203922b8a39e8d'

* commit '61b323ce7c7cdc101eadfd7de2203922b8a39e8d':
  vf_frei0r: refactor library loading from env variable

Conflicts:
	configure
	libavfilter/vf_frei0r.c

Not merged, we use av_strtok() which leads to simpler code

Merged-by: Michael Niedermayer <michaelni@gmx.at>
Merge commit '5397386effba2e53e4ff82852a86f6be4d59e9c1'

* commit '5397386effba2e53e4ff82852a86f6be4d59e9c1':
  mathops: move macro to the only place it is used

Merged-by: Michael Niedermayer <michaelni@gmx.at>