use of android.renderscript.RenderScriptGL in project android_frameworks_base by ParanoidAndroid.
the class Renderable method setTransform.
public void setTransform(Transform t) {
mTransform = t;
if (mField != null) {
RenderScriptGL rs = SceneManager.getRS();
updateFieldItem(rs);
mField.set(mData, 0, true);
}
}
use of android.renderscript.RenderScriptGL in project android_frameworks_base by ParanoidAndroid.
the class LightBase method getRSData.
ScriptField_Light_s getRSData() {
if (mField != null) {
return mField;
}
RenderScriptGL rs = SceneManager.getRS();
if (rs == null) {
return null;
}
if (mField == null) {
mField = new ScriptField_Light_s(rs, 1);
mFieldData = new ScriptField_Light_s.Item();
}
updateRSData();
return mField;
}
use of android.renderscript.RenderScriptGL in project android_frameworks_base by ParanoidAndroid.
the class LightBase method updateRSData.
protected void updateRSData() {
if (mField == null) {
return;
}
RenderScriptGL rs = SceneManager.getRS();
mFieldData.transformMatrix = mTransform.getRSData().getAllocation();
mFieldData.name = getNameAlloc(rs);
mFieldData.color = mColor;
mFieldData.intensity = mIntensity;
initLocalData();
mField.set(mFieldData, 0, true);
}
use of android.renderscript.RenderScriptGL in project android_frameworks_base by ParanoidAndroid.
the class Renderable method setRenderState.
public void setRenderState(RenderState renderState) {
mRenderState = renderState;
if (mField != null) {
RenderScriptGL rs = SceneManager.getRS();
updateFieldItem(rs);
mField.set(mData, 0, true);
}
}
use of android.renderscript.RenderScriptGL in project android_frameworks_base by ParanoidAndroid.
the class ShaderParam method getRSData.
public ScriptField_ShaderParamData_s getRSData() {
if (mField != null) {
return mField;
}
RenderScriptGL rs = SceneManager.getRS();
mField = new ScriptField_ShaderParamData_s(rs, 1);
if (mParamName != null) {
mData.paramName = SceneManager.getCachedAlloc(mParamName);
if (mData.paramName == null) {
mData.paramName = SceneManager.getStringAsAllocation(rs, mParamName);
SceneManager.cacheAlloc(mParamName, mData.paramName);
}
}
initLocalData();
mData.timestamp = 1;
mField.set(mData, 0, true);
return mField;
}
Aggregations