本文整理匯總了Java中com.jme.image.Texture2D.setMinificationFilter方法的典型用法代碼示例。如果您正苦於以下問題:Java Texture2D.setMinificationFilter方法的具體用法?Java Texture2D.setMinificationFilter怎麽用?Java Texture2D.setMinificationFilter使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類com.jme.image.Texture2D
的用法示例。
在下文中一共展示了Texture2D.setMinificationFilter方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: CaptureQuad
import com.jme.image.Texture2D; //導入方法依賴的package包/類
public CaptureQuad(String name, int camWidth, int camHeight, float frameRate) {
super(name);
try {
image = new QtCaptureImage();
image.initializeCamera(camWidth, camHeight, frameRate);
tex = new Texture2D();
tex.setMinificationFilter(MinificationFilter.Trilinear);
tex.setMagnificationFilter(MagnificationFilter.Bilinear);
tex.setImage(image);
tex.setApply(ApplyMode.Replace);
TextureState ts = DisplaySystem.getDisplaySystem().getRenderer().createTextureState();
ts.setEnabled(true);
ts.setTexture(tex);
setRenderState(ts);
updateRenderState();
} catch (Exception e) {
e.printStackTrace();
}
start();
// could, at this point, resize to fit height to current width?
}
示例2: loadVideo
import com.jme.image.Texture2D; //導入方法依賴的package包/類
private void loadVideo(URL videoResource) {
try {
image = new JMFVideoImage(videoResource, true, JMFVideoImage.SCALE_MAXIMIZE);
tex = new Texture2D();
tex.setMinificationFilter(MinificationFilter.Trilinear);
tex.setMagnificationFilter(MagnificationFilter.Bilinear);
tex.setImage(image);
tex.setApply(ApplyMode.Replace);
TextureState ts = DisplaySystem.getDisplaySystem().getRenderer().createTextureState();
ts.setEnabled(true);
ts.setTexture(tex);
setRenderState(ts);
updateRenderState();
} catch (Exception e) {
e.printStackTrace();
}
start();
// could, at this point, resize to fit height to current width?
}