Tabnine Logo
FrameBuffer$RenderBuffer.<init>
Code IndexAdd Tabnine to your IDE (free)

How to use
com.jme3.texture.FrameBuffer$RenderBuffer
constructor

Best Java code snippets using com.jme3.texture.FrameBuffer$RenderBuffer.<init> (Showing top 20 results out of 315)

origin: jMonkeyEngine/jmonkeyengine

/**
 * Add a color buffer without a texture bound to it.
 * If MRT is enabled, then each subsequently added texture or buffer can be
 * rendered to through a shader that writes to the array <code>gl_FragData</code>.
 * If MRT is not enabled, then the index set with {@link FrameBuffer#setTargetIndex(int) }
 * is rendered to by the shader.
 * 
 * @param format the format of the color buffer
 * @see #addColorTexture(com.jme3.texture.Texture2D) 
 */
public void addColorBuffer(Image.Format format){
  if (id != -1)
    throw new UnsupportedOperationException("FrameBuffer already initialized.");
  if (format.isDepthFormat())
    throw new IllegalArgumentException("Color buffer format must be color/luminance.");
  
  RenderBuffer colorBuf = new RenderBuffer();
  colorBuf.slot = colorBufs.size();
  colorBuf.format = format;
  
  colorBufs.add(colorBuf);
}

origin: jMonkeyEngine/jmonkeyengine

/**
 * Enables the use of a color buffer for this <code>FrameBuffer</code>.
 * 
 * @param format The format to use for the color buffer.
 * @throws IllegalArgumentException If <code>format</code> is not a color format.
 */
public void setColorBuffer(Image.Format format){
  if (id != -1)
    throw new UnsupportedOperationException("FrameBuffer already initialized.");
  if (format.isDepthFormat())
    throw new IllegalArgumentException("Color buffer format must be color/luminance.");
  
  RenderBuffer colorBuf = new RenderBuffer();
  colorBuf.slot = 0;
  colorBuf.format = format;
  
  colorBufs.clear();
  colorBufs.add(colorBuf);
}
origin: jMonkeyEngine/jmonkeyengine

/**
 * Enables the use of a depth buffer for this <code>FrameBuffer</code>.
 * 
 * @param format The format to use for the depth buffer.
 * @throws IllegalArgumentException If <code>format</code> is not a depth format.
 */
public void setDepthBuffer(Image.Format format){
  if (id != -1)
    throw new UnsupportedOperationException("FrameBuffer already initialized.");
  if (!format.isDepthFormat())
    throw new IllegalArgumentException("Depth buffer format must be depth.");
    
  depthBuf = new RenderBuffer();
  depthBuf.slot = format.isDepthStencilFormat() ?  SLOT_DEPTH_STENCIL : SLOT_DEPTH;
  depthBuf.format = format;
}
origin: org.jmonkeyengine/jme3-core

/**
 * Add a color texture array to use for this framebuffer.
 * If MRT is enabled, then each subsequently added texture can be
 * rendered to through a shader that writes to the array <code>gl_FragData</code>.
 * If MRT is not enabled, then the index set with {@link FrameBuffer#setTargetIndex(int) }
 * is rendered to by the shader.
 * 
 * @param tex The texture array to add.
 */
public void addColorTexture(TextureArray tex, int layer) {
  if (id != -1)
    throw new UnsupportedOperationException("FrameBuffer already initialized.");
  Image img = tex.getImage();
  checkSetTexture(tex, false);
  RenderBuffer colorBuf = new RenderBuffer();
  colorBuf.slot = colorBufs.size();
  colorBuf.tex = tex;
  colorBuf.format = img.getFormat();
  colorBuf.layer = layer;
  colorBufs.add(colorBuf);
}

origin: info.projectkyoto/mms-engine

/**
 * Enables the use of a color buffer for this <code>FrameBuffer</code>.
 * 
 * @param format The format to use for the color buffer.
 * @throws IllegalArgumentException If <code>format</code> is not a color format.
 */
public void setColorBuffer(Image.Format format){
  if (id != -1)
    throw new UnsupportedOperationException("FrameBuffer already initialized.");
  if (format.isDepthFormat())
    throw new IllegalArgumentException("Color buffer format must be color/luminance.");
  
  RenderBuffer colorBuf = new RenderBuffer();
  colorBuf.slot = 0;
  colorBuf.format = format;
  
  colorBufs.clear();
  colorBufs.add(colorBuf);
}
origin: org.jmonkeyengine/jme3-core

/**
 * Enables the use of a color buffer for this <code>FrameBuffer</code>.
 * 
 * @param format The format to use for the color buffer.
 * @throws IllegalArgumentException If <code>format</code> is not a color format.
 */
public void setColorBuffer(Image.Format format){
  if (id != -1)
    throw new UnsupportedOperationException("FrameBuffer already initialized.");
  if (format.isDepthFormat())
    throw new IllegalArgumentException("Color buffer format must be color/luminance.");
  
  RenderBuffer colorBuf = new RenderBuffer();
  colorBuf.slot = 0;
  colorBuf.format = format;
  
  colorBufs.clear();
  colorBufs.add(colorBuf);
}
origin: info.projectkyoto/mms-engine

/**
 * Add a color texture to use for this framebuffer.
 * If MRT is enabled, then each subsequently added texture can be
 * rendered to through a shader that writes to the array <code>gl_FragData</code>.
 * If MRT is not enabled, then the index set with {@link FrameBuffer#setTargetIndex(int) }
 * is rendered to by the shader.
 * 
 * @param tex The texture to add.
 */
public void addColorTexture(Texture2D tex) {
  if (id != -1)
    throw new UnsupportedOperationException("FrameBuffer already initialized.");
  Image img = tex.getImage();
  checkSetTexture(tex, false);
  RenderBuffer colorBuf = new RenderBuffer();
  colorBuf.slot = colorBufs.size();
  colorBuf.tex = tex;
  colorBuf.format = img.getFormat();
  colorBufs.add(colorBuf);
}
origin: org.jmonkeyengine/jme3-core

/**
 * Set the depth texture to use for this framebuffer.
 * 
 * @param tex The color texture to set.
 */
public void setDepthTexture(Texture2D tex){
  if (id != -1)
    throw new UnsupportedOperationException("FrameBuffer already initialized.");
  Image img = tex.getImage();
  checkSetTexture(tex, true);
  
  depthBuf = new RenderBuffer();
  depthBuf.slot = img.getFormat().isDepthStencilFormat() ?  SLOT_DEPTH_STENCIL : SLOT_DEPTH;
  depthBuf.tex = tex;
  depthBuf.format = img.getFormat();
}
public void setDepthTexture(TextureArray tex, int layer){
origin: info.projectkyoto/mms-engine

/**
 * Set the depth texture to use for this framebuffer.
 * 
 * @param tex The color texture to set.
 */
public void setDepthTexture(Texture2D tex){
  if (id != -1)
    throw new UnsupportedOperationException("FrameBuffer already initialized.");
  Image img = tex.getImage();
  checkSetTexture(tex, true);
  
  depthBuf = new RenderBuffer();
  depthBuf.slot = -100; // indicates GL_DEPTH_ATTACHMENT
  depthBuf.tex = tex;
  depthBuf.format = img.getFormat();
}
origin: info.projectkyoto/mms-engine

/**
 * Enables the use of a depth buffer for this <code>FrameBuffer</code>.
 * 
 * @param format The format to use for the depth buffer.
 * @throws IllegalArgumentException If <code>format</code> is not a depth format.
 */
public void setDepthBuffer(Image.Format format){
  if (id != -1)
    throw new UnsupportedOperationException("FrameBuffer already initialized.");
  if (!format.isDepthFormat())
    throw new IllegalArgumentException("Depth buffer format must be depth.");
    
  depthBuf = new RenderBuffer();
  depthBuf.slot = -100; // -100 == special slot for DEPTH_BUFFER
  depthBuf.format = format;
}
origin: org.jmonkeyengine/jme3-core

/**
 * Enables the use of a depth buffer for this <code>FrameBuffer</code>.
 * 
 * @param format The format to use for the depth buffer.
 * @throws IllegalArgumentException If <code>format</code> is not a depth format.
 */
public void setDepthBuffer(Image.Format format){
  if (id != -1)
    throw new UnsupportedOperationException("FrameBuffer already initialized.");
  if (!format.isDepthFormat())
    throw new IllegalArgumentException("Depth buffer format must be depth.");
    
  depthBuf = new RenderBuffer();
  depthBuf.slot = format.isDepthStencilFormat() ?  SLOT_DEPTH_STENCIL : SLOT_DEPTH;
  depthBuf.format = format;
}
origin: org.jmonkeyengine/jme3-core

public void setDepthTexture(TextureArray tex, int layer){
  if (id != -1)
    throw new UnsupportedOperationException("FrameBuffer already initialized.");
  Image img = tex.getImage();
  checkSetTexture(tex, true);
  
  depthBuf = new RenderBuffer();
  depthBuf.slot = img.getFormat().isDepthStencilFormat() ?  SLOT_DEPTH_STENCIL : SLOT_DEPTH;
  depthBuf.tex = tex;
  depthBuf.format = img.getFormat();
  depthBuf.layer = layer;
}

origin: org.jmonkeyengine/jme3-core

public RenderBuffer createDestructableClone(){
  if (tex != null){
    return null;
  }else{
    RenderBuffer destructClone =  new RenderBuffer();
    destructClone.id = id;
    return destructClone;
  }
}
origin: info.projectkyoto/mms-engine

public RenderBuffer createDestructableClone(){
  if (tex != null){
    return null;
  }else{
    RenderBuffer destructClone =  new RenderBuffer();
    destructClone.id = id;
    return destructClone;
  }
}
origin: jMonkeyEngine/jmonkeyengine

/**
 * Add a color texture to use for this framebuffer.
 * If MRT is enabled, then each subsequently added texture can be
 * rendered to through a shader that writes to the array <code>gl_FragData</code>.
 * If MRT is not enabled, then the index set with {@link FrameBuffer#setTargetIndex(int) }
 * is rendered to by the shader.
 * 
 * @param tex The texture to add.
 * @see #addColorBuffer(com.jme3.texture.Image.Format) 
 */
public void addColorTexture(Texture2D tex) {
  if (id != -1)
    throw new UnsupportedOperationException("FrameBuffer already initialized.");
  Image img = tex.getImage();
  checkSetTexture(tex, false);
  RenderBuffer colorBuf = new RenderBuffer();
  colorBuf.slot = colorBufs.size();
  colorBuf.tex = tex;
  colorBuf.format = img.getFormat();
  colorBufs.add(colorBuf);
}

origin: jMonkeyEngine/jmonkeyengine

 /**
 * Add a color texture to use for this framebuffer.
 * If MRT is enabled, then each subsequently added texture can be
 * rendered to through a shader that writes to the array <code>gl_FragData</code>.
 * If MRT is not enabled, then the index set with {@link FrameBuffer#setTargetIndex(int) }
 * is rendered to by the shader.
 *
 * @param tex The cube-map texture to add.
 * @param face The face of the cube-map to render to.
 */
public void addColorTexture(TextureCubeMap tex, TextureCubeMap.Face face) {
  if (id != -1)
    throw new UnsupportedOperationException("FrameBuffer already initialized.");
  Image img = tex.getImage();
  checkSetTexture(tex, false);
  RenderBuffer colorBuf = new RenderBuffer();
  colorBuf.slot = colorBufs.size();
  colorBuf.tex = tex;
  colorBuf.format = img.getFormat();
  colorBuf.face = face.ordinal();
  colorBufs.add(colorBuf);
}
origin: jMonkeyEngine/jmonkeyengine

/**
 * Add a color texture array to use for this framebuffer.
 * If MRT is enabled, then each subsequently added texture can be
 * rendered to through a shader that writes to the array <code>gl_FragData</code>.
 * If MRT is not enabled, then the index set with {@link FrameBuffer#setTargetIndex(int) }
 * is rendered to by the shader.
 * 
 * @param tex The texture array to add.
 */
public void addColorTexture(TextureArray tex, int layer) {
  if (id != -1)
    throw new UnsupportedOperationException("FrameBuffer already initialized.");
  Image img = tex.getImage();
  checkSetTexture(tex, false);
  RenderBuffer colorBuf = new RenderBuffer();
  colorBuf.slot = colorBufs.size();
  colorBuf.tex = tex;
  colorBuf.format = img.getFormat();
  colorBuf.layer = layer;
  colorBufs.add(colorBuf);
}

origin: jMonkeyEngine/jmonkeyengine

/**
 * Set the depth texture to use for this framebuffer.
 * 
 * @param tex The color texture to set.
 */
public void setDepthTexture(Texture2D tex){
  if (id != -1)
    throw new UnsupportedOperationException("FrameBuffer already initialized.");
  Image img = tex.getImage();
  checkSetTexture(tex, true);
  
  depthBuf = new RenderBuffer();
  depthBuf.slot = img.getFormat().isDepthStencilFormat() ?  SLOT_DEPTH_STENCIL : SLOT_DEPTH;
  depthBuf.tex = tex;
  depthBuf.format = img.getFormat();
}
public void setDepthTexture(TextureArray tex, int layer){
origin: jMonkeyEngine/jmonkeyengine

public void setDepthTexture(TextureArray tex, int layer){
  if (id != -1)
    throw new UnsupportedOperationException("FrameBuffer already initialized.");
  Image img = tex.getImage();
  checkSetTexture(tex, true);
  
  depthBuf = new RenderBuffer();
  depthBuf.slot = img.getFormat().isDepthStencilFormat() ?  SLOT_DEPTH_STENCIL : SLOT_DEPTH;
  depthBuf.tex = tex;
  depthBuf.format = img.getFormat();
  depthBuf.layer = layer;
}

origin: jMonkeyEngine/jmonkeyengine

public RenderBuffer createDestructableClone(){
  if (tex != null){
    return null;
  }else{
    RenderBuffer destructClone =  new RenderBuffer();
    destructClone.id = id;
    return destructClone;
  }
}
com.jme3.textureFrameBuffer$RenderBuffer<init>

Popular methods of FrameBuffer$RenderBuffer

  • getId
    Do not use.
  • getSlot
    Do not use.
  • getFormat
  • getTexture
  • getFace
  • resetObject
  • setId
    Do not use.
  • getLayer

Popular in Java

  • Running tasks concurrently on multiple threads
  • requestLocationUpdates (LocationManager)
  • getSharedPreferences (Context)
  • findViewById (Activity)
  • InetAddress (java.net)
    An Internet Protocol (IP) address. This can be either an IPv4 address or an IPv6 address, and in pra
  • Path (java.nio.file)
  • Permission (java.security)
    Legacy security code; do not use.
  • Date (java.sql)
    A class which can consume and produce dates in SQL Date format. Dates are represented in SQL as yyyy
  • ZipFile (java.util.zip)
    This class provides random read access to a zip file. You pay more to read the zip file's central di
  • JLabel (javax.swing)
  • Github Copilot alternatives
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now