Skip to content

update oppo sdk. #19864

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 26, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file modified cocos/platform/android/java/libs/oppoSDK.jar
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -31,27 +31,27 @@ of this software and associated documentation files (the "Software"), to deal
import com.oppo.oiface.engine.OifaceGameEngineManager;

public class Cocos2dxDataManager {
public static void setOptimise(String thing, float value){
public static void setOptimise(String thing, String value){
String jsonStr = "{\"" + thing + "\":" + String.valueOf(value) + "}";
OifaceGameEngineManager.getInstance().updateGameEngineInfo(jsonStr);
}

public static void setProcessID(int pid){
setOptimise("render_pid", pid);
setOptimise("render_pid", String.valueOf(pid));
}
public static void setFrameSize(int width, int height){
setOptimise("buffer_size", width * height);
setOptimise("buffer_size", String.valueOf(width * height));
}
public static void onSceneLoaderBegin(){
setOptimise("load_scene", 1);
setOptimise("load_scene", String.valueOf(1));
}
public static void onSceneLoaderEnd(){
setOptimise("load_scene", 0);
setOptimise("load_scene", String.valueOf(0));
}
public static void onShaderLoaderBegin(){
setOptimise("shader_compile", 1);
setOptimise("shader_compile", String.valueOf(1));
}
public static void onShaderLoaderEnd(){
setOptimise("shader_compile", 0);
setOptimise("shader_compile", String.valueOf(0));
}
}