Skip to content

add dvdnav_get_disk_region_mask

Provides a way of getting the reported region mask advertised by the current disk. Can be used to set the region code of the virtual machine via dvdnav_set_region_mask if so desired

I am a bit unsure if this is actually needed (or if the makes any difference - I can play all my discs without forcing the region) but as I personally don't see any harm in having this available - decided to submit anyway.

In Kodi we have two choices regarding dvd region codes and dvd playback:

  • Auto mode (0)
  • Forced dvd region (1-8)

When in auto mode Kodi first obtains the region mask advertised by the disk and then forces the vm into that region mask using dvdnav_set_region_mask. In forced region mode it forces the user provided region (regions 1-8). As a last resort (not likely to ever get there) it enables all regions (0xff):

I couldn't find any similar implementation in vlc or mpv, both seem not to force the region code ever and likely use the default value in the register (0x01). Regardless of this, the region mask is currently logged by libdvdnav on initialization but cannot (at least I couldn't find any way) be obtained from the client code.

Edited by Miguel Borges de Freitas

Merge request reports