mirror of
https://github.com/samsonjs/media.git
synced 2026-04-27 15:07:40 +00:00
Support setting properties on MediaDrm
This commit is contained in:
parent
5ca5df0bb2
commit
1469f11aa3
1 changed files with 24 additions and 0 deletions
|
|
@ -213,6 +213,18 @@ public class StreamingDrmSessionManager implements DrmSessionManager {
|
||||||
return mediaDrm.getPropertyString(key);
|
return mediaDrm.getPropertyString(key);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Provides access to {@link MediaDrm#setPropertyString(String, String)}.
|
||||||
|
* <p>
|
||||||
|
* This method may be called when the manager is in any state.
|
||||||
|
*
|
||||||
|
* @param key The property to write.
|
||||||
|
* @param value The value to write.
|
||||||
|
*/
|
||||||
|
public final void setPropertyString(String key, String value) {
|
||||||
|
mediaDrm.setPropertyString(key, value);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Provides access to {@link MediaDrm#getPropertyByteArray(String)}.
|
* Provides access to {@link MediaDrm#getPropertyByteArray(String)}.
|
||||||
* <p>
|
* <p>
|
||||||
|
|
@ -225,6 +237,18 @@ public class StreamingDrmSessionManager implements DrmSessionManager {
|
||||||
return mediaDrm.getPropertyByteArray(key);
|
return mediaDrm.getPropertyByteArray(key);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Provides access to {@link MediaDrm#setPropertyByteArray(String, byte[])}.
|
||||||
|
* <p>
|
||||||
|
* This method may be called when the manager is in any state.
|
||||||
|
*
|
||||||
|
* @param key The property to write.
|
||||||
|
* @param value The value to write.
|
||||||
|
*/
|
||||||
|
public final void setPropertyByteArray(String key, byte[] value) {
|
||||||
|
mediaDrm.setPropertyByteArray(key, value);
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void open(DrmInitData drmInitData) {
|
public void open(DrmInitData drmInitData) {
|
||||||
if (++openCount != 1) {
|
if (++openCount != 1) {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue