… | |
… | |
187 | |
187 | |
188 | As a rule of thumb, all data you pass to this module to be sent to F<mpv> |
188 | As a rule of thumb, all data you pass to this module to be sent to F<mpv> |
189 | is expected to be in unicode. To pass something that isn't, you need to |
189 | is expected to be in unicode. To pass something that isn't, you need to |
190 | escape it using C<escape_binary>. |
190 | escape it using C<escape_binary>. |
191 | |
191 | |
192 | Data received from C<$mpv>, however, is I<not> decoded to unicode, as data |
192 | Data received from F<mpv>, however, is I<not> decoded to unicode, as data |
193 | returned by F<mpv> is not generally encoded in unicode, and the encoding |
193 | returned by F<mpv> is not generally encoded in unicode, and the encoding |
194 | is usually unspecified. So if you receive data and expect it to be in |
194 | is usually unspecified. So if you receive data and expect it to be in |
195 | unicode, you need to first decode it from UTF-8, but note that this might |
195 | unicode, you need to first decode it from UTF-8, but note that this might |
196 | fail. This is not a limitation of this module - F<mpv> simply does not |
196 | fail. This is not a limitation of this module - F<mpv> simply does not |
197 | specify nor guarantee a specific encoding, or any encoding at all, in its |
197 | specify nor guarantee a specific encoding, or any encoding at all, in its |