slog3-s-gamut3.cine_to_s709
时间: 2024-01-26 21:00:37 浏览: 23
slog3-s-gamut3.cine_to_s709是Sony相机的一种色彩空间转换功能,它可以将采用S-Log3和S-Gamut3.Cine拍摄的视频素材转换为标准的Rec.709色彩空间,以便在常见的电视、显示器和投影设备上进行观看和编辑。
S-Log3是Sony相机的一种Log曲线,它具有更宽的动态范围和更丰富的细节表现能力,适合用于后期调色和特效处理。而S-Gamut3.Cine是Sony相机的一种色彩空间,它提供了更广的色彩表现范围,可以捕捉更多的色彩细节和更丰富的色彩层次。
当我们需要在电视、显示器或投影设备上展示或编辑这些素材时,使用slog3-s-gamut3.cine_to_s709功能可以方便地将这些高动态范围和广色域的素材转换为标准的Rec.709色彩空间,以确保画面在不同设备上的呈现效果一致,同时也更容易进行后期调色和编辑工作。
总之,slog3-s-gamut3.cine_to_s709是一项方便实用的功能,能够帮助用户在不同设备上更好地展示和编辑采用S-Log3和S-Gamut3.Cine拍摄的视频素材,提高了工作效率和色彩表现质量。
相关问题
android 原生frameworks 判断 android.permission.FOREGROUND_SERVICE
在 Android 原生 Framework 中,可以使用以下方式来判断是否具有 FOREGROUND_SERVICE 权限:
1. 在 PackageManagerService.java 中,可以找到 checkPermission() 方法,该方法用于检查应用程序是否具有指定的权限。在该方法中,可以查找 FOREGROUND_SERVICE 权限并返回相应的结果,代码如下:
```
private int checkPermission(String perm, int uid, int callingPid, int callingUid) {
// ...
if (perm.equals(Manifest.permission.FOREGROUND_SERVICE)) {
if (mAppOpsService.noteOperation(AppOpsManager.OP_RUN_FOREGROUND, uid, packageName) == AppOpsManager.MODE_ALLOWED) {
granted = PackageManager.PERMISSION_GRANTED;
}
}
// ...
return granted;
}
```
在该方法中,通过调用 AppOpsManager.noteOperation() 方法来检查应用程序是否具有 FOREGROUND_SERVICE 权限。如果应用程序具有该权限,则返回 PackageManager.PERMISSION_GRANTED;否则返回 PackageManager.PERMISSION_DENIED。
2. 在 ActivityManagerService.java 中,可以找到 checkForegroundServicePermission() 方法,该方法用于检查应用程序是否具有 FOREGROUND_SERVICE 权限以及是否可以启动前台服务。在该方法中,可以先检查应用程序是否具有 FOREGROUND_SERVICE 权限,如果有,则再检查应用程序是否可以启动前台服务,代码如下:
```
private int checkForegroundServicePermission(int uid, String packageName, int callingPid, int callingUid, int startId, boolean lastStartForeground) {
// ...
if (checkPermission(Manifest.permission.FOREGROUND_SERVICE, uid, callingPid, callingUid) != PackageManager.PERMISSION_GRANTED) {
Slog.w(TAG, "startForegroundService not allowed due to lack of FOREGROUND_SERVICE permission");
return START_NOT_STICKY;
}
final long origId = Binder.clearCallingIdentity();
boolean fgServiceAllowed = false;
try {
fgServiceAllowed = mBatteryStatsService.noteStartForeground(packageName, uid, lastStartForeground);
} catch (RemoteException e) {
Slog.w(TAG, "Failed to note battery stats for startForegroundService", e);
} finally {
Binder.restoreCallingIdentity(origId);
}
if (!fgServiceAllowed) {
Slog.w(TAG, "startForegroundService not allowed due to battery stats");
return START_NOT_STICKY;
}
// ...
return START_SUCCESS;
}
```
在该方法中,首先调用 checkPermission() 方法来检查应用程序是否具有 FOREGROUND_SERVICE 权限。如果应用程序没有该权限,则返回 START_NOT_STICKY。如果应用程序具有该权限,则调用 BatteryStatsService.noteStartForeground() 方法来检查应用程序是否可以启动前台服务。如果可以,则返回 START_SUCCESS;否则返回 START_NOT_STICKY。
android 原生 frameworks 判断 android.permission.FOREGROUND_SERVICE
在 Android 原生框架中,可以使用以下方式来判断是否具有 FOREGROUND_SERVICE 权限:
1. 在 PackageManagerService.java 中,可以找到 checkPermission() 方法,该方法用于检查应用程序是否具有指定的权限。在该方法中,可以查找 FOREGROUND_SERVICE 权限并返回相应的结果,代码如下:
```
private int checkPermission(String perm, int uid, int callingPid, int callingUid) {
// ...
if (perm.equals(Manifest.permission.FOREGROUND_SERVICE)) {
if (mAppOpsService.noteOperation(AppOpsManager.OP_RUN_FOREGROUND, uid, packageName) == AppOpsManager.MODE_ALLOWED) {
granted = PackageManager.PERMISSION_GRANTED;
}
}
// ...
return granted;
}
```
在该方法中,通过调用 AppOpsManager.noteOperation() 方法来检查应用程序是否具有 FOREGROUND_SERVICE 权限。如果应用程序具有该权限,则返回 PackageManager.PERMISSION_GRANTED;否则返回 PackageManager.PERMISSION_DENIED。
2. 在 ActivityManagerService.java 中,可以找到 checkForegroundServicePermission() 方法,该方法用于检查应用程序是否具有 FOREGROUND_SERVICE 权限以及是否可以启动前台服务。在该方法中,可以先检查应用程序是否具有 FOREGROUND_SERVICE 权限,如果有,则再检查应用程序是否可以启动前台服务,代码如下:
```
private int checkForegroundServicePermission(int uid, String packageName, int callingPid, int callingUid, int startId, boolean lastStartForeground) {
// ...
if (checkPermission(Manifest.permission.FOREGROUND_SERVICE, uid, callingPid, callingUid) != PackageManager.PERMISSION_GRANTED) {
Slog.w(TAG, "startForegroundService not allowed due to lack of FOREGROUND_SERVICE permission");
return START_NOT_STICKY;
}
final long origId = Binder.clearCallingIdentity();
boolean fgServiceAllowed = false;
try {
fgServiceAllowed = mBatteryStatsService.noteStartForeground(packageName, uid, lastStartForeground);
} catch (RemoteException e) {
Slog.w(TAG, "Failed to note battery stats for startForegroundService", e);
} finally {
Binder.restoreCallingIdentity(origId);
}
if (!fgServiceAllowed) {
Slog.w(TAG, "startForegroundService not allowed due to battery stats");
return START_NOT_STICKY;
}
// ...
return START_SUCCESS;
}
```
在该方法中,首先调用 checkPermission() 方法来检查应用程序是否具有 FOREGROUND_SERVICE 权限。如果应用程序没有该权限,则返回 START_NOT_STICKY。如果应用程序具有该权限,则调用 BatteryStatsService.noteStartForeground() 方法来检查应用程序是否可以启动前台服务。如果可以,则返回 START_SUCCESS;否则返回 START_NOT_STICKY。