Examples of RGBFormat


Examples of javax.media.format.RGBFormat

  {
    final Vector vTest = new Vector();

    assertCaptureDeviceInfoVectorEquals(vTest, CaptureDeviceManager.getDeviceList(null));
   
    final Format[] f1s = new Format[]{new RGBFormat()};
    assertNotEquals(new CaptureDeviceInfo("abc", null, new Format[]{}),
        new CaptureDeviceInfo("abc", null, new Format[]{}));
    assertNotEquals(new CaptureDeviceInfo("abc", null, f1s),
        new CaptureDeviceInfo("abc", null, f1s))// strange
   
    CaptureDeviceInfo i1 = new CaptureDeviceInfo("abc", null, f1s);
    assertNotEquals(i1, i1)// strange
   
   
   
    CaptureDeviceManager.addDevice(i1);
    vTest.add(i1);

    assertCaptureDeviceInfoVectorEquals(vTest, CaptureDeviceManager.getDeviceList(null));
    assertCaptureDeviceInfoVectorEquals(vTest, CaptureDeviceManager.getDeviceList(new RGBFormat()));

   
    CaptureDeviceManager.removeDevice(i1);
    vTest.remove(i1);
   
View Full Code Here

Examples of javax.media.format.RGBFormat

    PlugInManager.addPlugIn("com.sun.media.codec.video.cinepak.JavaDecoder",
      new Format[] {
        new VideoFormat("cvid", null, -1, Format.byteArray, -1.0f),
      },
      new Format[] {
        new RGBFormat(null, -1, Format.intArray, -1.0f, 32, 0xff, 0xff00, 0xff0000, 1, -1, 0, -1),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.ibm.media.codec.video.h263.JavaDecoder",
      new Format[] {
        new VideoFormat("h263", null, -1, Format.byteArray, -1.0f),
        new VideoFormat("h263/rtp", null, -1, Format.byteArray, -1.0f),
      },
      new Format[] {
        new RGBFormat(null, -1, null, -1.0f, -1, 0xffffffff, 0xffffffff, 0xffffffff, -1, -1, -1, -1),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.sun.media.codec.video.colorspace.JavaRGBConverter",
      new Format[] {
        new RGBFormat(null, -1, null, -1.0f, -1, 0xffffffff, 0xffffffff, 0xffffffff, -1, -1, -1, -1),
      },
      new Format[] {
        new RGBFormat(null, -1, null, -1.0f, -1, 0xffffffff, 0xffffffff, 0xffffffff, -1, -1, -1, -1),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.sun.media.codec.video.colorspace.JavaRGBToYUV",
      new Format[] {
        new RGBFormat(null, -1, Format.byteArray, -1.0f, 24, 0xffffffff, 0xffffffff, 0xffffffff, -1, -1, -1, -1),
        new RGBFormat(null, -1, Format.intArray, -1.0f, 32, 0xff0000, 0xff00, 0xff, 1, -1, -1, -1),
        new RGBFormat(null, -1, Format.intArray, -1.0f, 32, 0xff, 0xff00, 0xff0000, 1, -1, -1, -1),
      },
      new Format[] {
        new YUVFormat(null, -1, Format.byteArray, -1.0f, 2, -1, -1, -1, -1, -1),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.ibm.media.codec.audio.PCMToPCM",
      new Format[] {
        new AudioFormat("LINEAR", -1.0, 16, 1, -1, -1, -1, -1.0, Format.byteArray),
        new AudioFormat("LINEAR", -1.0, 16, 2, -1, -1, -1, -1.0, Format.byteArray),
        new AudioFormat("LINEAR", -1.0, 8, 1, -1, -1, -1, -1.0, Format.byteArray),
        new AudioFormat("LINEAR", -1.0, 8, 2, -1, -1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("LINEAR", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.ibm.media.codec.audio.rc.RCModule",
      new Format[] {
        new AudioFormat("LINEAR", -1.0, 16, 2, -1, -1, -1, -1.0, Format.byteArray),
        new AudioFormat("LINEAR", -1.0, 16, 1, -1, -1, -1, -1.0, Format.byteArray),
        new AudioFormat("LINEAR", -1.0, 8, 2, -1, -1, -1, -1.0, Format.byteArray),
        new AudioFormat("LINEAR", -1.0, 8, 1, -1, -1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("LINEAR", 8000.0, 16, 2, 0, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("LINEAR", 8000.0, 16, 1, 0, 1, -1, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.sun.media.codec.audio.rc.RateCvrt",
      new Format[] {
        new AudioFormat("LINEAR", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("LINEAR", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.sun.media.codec.audio.msadpcm.JavaDecoder",
      new Format[] {
        new AudioFormat("msadpcm", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("LINEAR", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.ibm.media.codec.audio.ulaw.JavaDecoder",
      new Format[] {
        new AudioFormat("ULAW", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("LINEAR", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.ibm.media.codec.audio.alaw.JavaDecoder",
      new Format[] {
        new AudioFormat("alaw", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("LINEAR", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.ibm.media.codec.audio.dvi.JavaDecoder",
      new Format[] {
        new AudioFormat("dvi/rtp", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("LINEAR", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.ibm.media.codec.audio.g723.JavaDecoder",
      new Format[] {
        new AudioFormat("g723", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
        new AudioFormat("g723/rtp", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("LINEAR", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.ibm.media.codec.audio.gsm.JavaDecoder",
      new Format[] {
        new AudioFormat("gsm", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
        new AudioFormat("gsm/rtp", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("LINEAR", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.ibm.media.codec.audio.gsm.JavaDecoder_ms",
      new Format[] {
        new AudioFormat("gsm/ms", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("LINEAR", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.ibm.media.codec.audio.ima4.JavaDecoder",
      new Format[] {
        new AudioFormat("ima4", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("LINEAR", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.ibm.media.codec.audio.ima4.JavaDecoder_ms",
      new Format[] {
        new AudioFormat("ima4/ms", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("LINEAR", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.ibm.media.codec.audio.ulaw.JavaEncoder",
      new Format[] {
        new AudioFormat("LINEAR", -1.0, 16, 1, -1, -1, -1, -1.0, Format.byteArray),
        new AudioFormat("LINEAR", -1.0, 16, 2, -1, -1, -1, -1.0, Format.byteArray),
        new AudioFormat("LINEAR", -1.0, 8, 1, -1, -1, -1, -1.0, Format.byteArray),
        new AudioFormat("LINEAR", -1.0, 8, 2, -1, -1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("ULAW", 8000.0, 8, 1, -1, -1, -1, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.ibm.media.codec.audio.dvi.JavaEncoder",
      new Format[] {
        new AudioFormat("LINEAR", -1.0, 16, 1, 0, 1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("dvi/rtp", -1.0, 4, 1, -1, -1, -1, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.ibm.media.codec.audio.gsm.JavaEncoder",
      new Format[] {
        new AudioFormat("LINEAR", -1.0, 16, 1, 0, 1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("gsm", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.ibm.media.codec.audio.gsm.JavaEncoder_ms",
      new Format[] {
        new AudioFormat("LINEAR", -1.0, 16, 1, 0, 1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new com.sun.media.format.WavAudioFormat("gsm/ms", -1.0, -1, -1, -1, -1, -1, -1, -1.0f, Format.byteArray, null),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.ibm.media.codec.audio.ima4.JavaEncoder",
      new Format[] {
        new AudioFormat("LINEAR", -1.0, 16, -1, 0, 1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("ima4", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.ibm.media.codec.audio.ima4.JavaEncoder_ms",
      new Format[] {
        new AudioFormat("LINEAR", -1.0, 16, -1, 0, 1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new com.sun.media.format.WavAudioFormat("ima4/ms", -1.0, -1, -1, -1, -1, -1, -1, -1.0f, Format.byteArray, null),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.sun.media.codec.audio.ulaw.Packetizer",
      new Format[] {
        new AudioFormat("ULAW", -1.0, 8, 1, -1, -1, 8, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("ULAW/rtp", -1.0, 8, 1, -1, -1, 8, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.sun.media.codec.audio.ulaw.DePacketizer",
      new Format[] {
        new AudioFormat("ULAW/rtp", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("ULAW", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.sun.media.codec.audio.mpa.Packetizer",
      new Format[] {
        new AudioFormat("mpeglayer3", 16000.0, -1, -1, -1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpeglayer3", 22050.0, -1, -1, -1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpeglayer3", 24000.0, -1, -1, -1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpeglayer3", 32000.0, -1, -1, -1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpeglayer3", 44100.0, -1, -1, -1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpeglayer3", 48000.0, -1, -1, -1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpegaudio", 16000.0, -1, -1, -1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpegaudio", 22050.0, -1, -1, -1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpegaudio", 24000.0, -1, -1, -1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpegaudio", 32000.0, -1, -1, -1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpegaudio", 44100.0, -1, -1, -1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpegaudio", 48000.0, -1, -1, -1, 1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("mpegaudio/rtp", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.sun.media.codec.audio.mpa.DePacketizer",
      new Format[] {
        new AudioFormat("mpegaudio/rtp", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("mpegaudio", 44100.0, 16, -1, 1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpegaudio", 48000.0, 16, -1, 1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpegaudio", 32000.0, 16, -1, 1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpegaudio", 22050.0, 16, -1, 1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpegaudio", 24000.0, 16, -1, 1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpegaudio", 16000.0, 16, -1, 1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpegaudio", 11025.0, 16, -1, 1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpegaudio", 12000.0, 16, -1, 1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpegaudio", 8000.0, 16, -1, 1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpeglayer3", 44100.0, 16, -1, 1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpeglayer3", 48000.0, 16, -1, 1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpeglayer3", 32000.0, 16, -1, 1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpeglayer3", 22050.0, 16, -1, 1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpeglayer3", 24000.0, 16, -1, 1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpeglayer3", 16000.0, 16, -1, 1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpeglayer3", 11025.0, 16, -1, 1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpeglayer3", 12000.0, 16, -1, 1, 1, -1, -1.0, Format.byteArray),
        new AudioFormat("mpeglayer3", 8000.0, 16, -1, 1, 1, -1, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.ibm.media.codec.audio.gsm.Packetizer",
      new Format[] {
        new AudioFormat("gsm", 8000.0, -1, 1, -1, -1, 264, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("gsm/rtp", 8000.0, -1, 1, -1, -1, 264, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.ibm.media.codec.audio.g723.Packetizer",
      new Format[] {
        new AudioFormat("g723", 8000.0, -1, 1, -1, -1, 192, -1.0, Format.byteArray),
      },
      new Format[] {
        new AudioFormat("g723/rtp", 8000.0, -1, 1, -1, -1, 192, -1.0, Format.byteArray),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.sun.media.codec.video.jpeg.Packetizer",
      new Format[] {
        new VideoFormat("jpeg", null, -1, Format.byteArray, -1.0f),
      },
      new Format[] {
        new VideoFormat("jpeg/rtp", null, -1, Format.byteArray, -1.0f),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.sun.media.codec.video.jpeg.DePacketizer",
      new Format[] {
        new VideoFormat("jpeg/rtp", null, -1, Format.byteArray, -1.0f),
      },
      new Format[] {
        new VideoFormat("jpeg", null, -1, Format.byteArray, -1.0f),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.sun.media.codec.video.mpeg.Packetizer",
      new Format[] {
        new VideoFormat("mpeg", null, -1, Format.byteArray, -1.0f),
      },
      new Format[] {
        new VideoFormat("mpeg/rtp", null, -1, Format.byteArray, -1.0f),
      },
      PlugInManager.CODEC);
    PlugInManager.addPlugIn("com.sun.media.codec.video.mpeg.DePacketizer",
      new Format[] {
        new VideoFormat("mpeg/rtp", null, -1, Format.byteArray, -1.0f),
      },
      new Format[] {
        new VideoFormat("mpeg", null, -1, Format.byteArray, -1.0f),
      },
      PlugInManager.CODEC);

//     PlugInManager.EFFECT:

//     PlugInManager.RENDERER:
    PlugInManager.addPlugIn("com.sun.media.renderer.audio.JavaSoundRenderer",
      new Format[] {
        new AudioFormat("LINEAR", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
        new AudioFormat("ULAW", -1.0, -1, -1, -1, -1, -1, -1.0, Format.byteArray),
      },
      new Format[] {},
      PlugInManager.RENDERER);
    PlugInManager.addPlugIn("com.sun.media.renderer.audio.SunAudioRenderer",
      new Format[] {
        new AudioFormat("ULAW", 8000.0, 8, 1, -1, -1, -1, -1.0, Format.byteArray),
      },
      new Format[] {},
      PlugInManager.RENDERER);
    PlugInManager.addPlugIn("com.sun.media.renderer.video.AWTRenderer",
      new Format[] {
        new RGBFormat(null, -1, Format.intArray, -1.0f, 32, 0xff0000, 0xff00, 0xff, 1, -1, 0, -1),
        new RGBFormat(null, -1, Format.intArray, -1.0f, 32, 0xff, 0xff00, 0xff0000, 1, -1, 0, -1),
      },
      new Format[] {},
      PlugInManager.RENDERER);
    PlugInManager.addPlugIn("com.sun.media.renderer.video.LightWeightRenderer",
      new Format[] {
        new RGBFormat(null, -1, Format.intArray, -1.0f, 32, 0xff0000, 0xff00, 0xff, 1, -1, 0, -1),
        new RGBFormat(null, -1, Format.intArray, -1.0f, 32, 0xff, 0xff00, 0xff0000, 1, -1, 0, -1),
      },
      new Format[] {},
      PlugInManager.RENDERER);
    PlugInManager.addPlugIn("com.sun.media.renderer.video.JPEGRenderer",
      new Format[] {
View Full Code Here

Examples of javax.media.format.RGBFormat

  }
 
  public void testBitMapInfo2()
  {
    {
      BitMapInfo b = new BitMapInfo(new RGBFormat());
      assertEquals(b.biBitCount, -1);
      assertEquals(b.biWidth, 320);
      assertEquals(b.biHeight, 240);
      assertEquals(b.biPlanes, 1);
      assertEquals(b.biSizeImage, -2);
View Full Code Here

Examples of javax.media.format.RGBFormat

    if (f == null)
      return "null";
    final Class c = f.getClass();
    if (c == RGBFormat.class)
    {
      final RGBFormat o = (RGBFormat) f;
      return "new RGBFormat(" +
      toLiteral(o.getSize()) +
      ", " + o.getMaxDataLength() +
      ", " + dataTypeToStr(o.getDataType()) +
      ", " + CGUtils.toLiteral(o.getFrameRate()) +
      ", " + o.getBitsPerPixel() +
      ", " + CGUtils.toHexLiteral(o.getRedMask()) +
      ", " + CGUtils.toHexLiteral(o.getGreenMask()) +
      ", " + CGUtils.toHexLiteral(o.getBlueMask()) +
      ", " + o.getPixelStride() +
      ", " + o.getLineStride() +
      ", " + o.getFlipped() +
      ", " + o.getEndian()
      + ")";
     
    }
    else if (c == YUVFormat.class)
    {
 
      final YUVFormat o = (YUVFormat) f;
      return "new YUVFormat(" +
      toLiteral(o.getSize()) +
      ", " + o.getMaxDataLength() +
      ", " + dataTypeToStr(o.getDataType()) +
      ", " + CGUtils.toLiteral(o.getFrameRate()) +
      ", " + o.getYuvType() // TODO: use constants
      ", " + o.getStrideY() +
      ", " + o.getStrideUV() +
      ", " + o.getOffsetY() +
      ", " + o.getOffsetU() +
      ", " + o.getOffsetV()
      + ")";
     
    }
    else if (c == JPEGFormat.class)
    {
 
      final JPEGFormat o = (JPEGFormat) f;
      return "new JPEGFormat(" +
      toLiteral(o.getSize()) +
      ", " + o.getMaxDataLength() +
      ", " + dataTypeToStr(o.getDataType()) +
      ", " + CGUtils.toLiteral(o.getFrameRate()) +
      ", " + o.getQFactor()
      ", " + o.getDecimation()
      + ")";

     
    }
    else if (c == IndexedColorFormat.class)
    {
 

      final IndexedColorFormat o = (IndexedColorFormat) f;
      return "new IndexedColorFormat(" +
      toLiteral(o.getSize()) +
      ", " + o.getMaxDataLength() +
      ", " + dataTypeToStr(o.getDataType()) +
      ", " + CGUtils.toLiteral(o.getFrameRate()) +
      ", " + o.getLineStride() // TODO: use constants
      ", " + o.getMapSize() +
      ", " + CGUtils.toLiteral(o.getRedValues()) +
      ", " + CGUtils.toLiteral(o.getGreenValues()) +
      ", " + CGUtils.toLiteral(o.getBlueValues())
      + ")";

     
    }
    else if (c == H263Format.class)
    {

      final H263Format o = (H263Format) f;
      return "new H263Format(" +
      toLiteral(o.getSize()) +
      ", " + o.getMaxDataLength() +
      ", " + dataTypeToStr(o.getDataType()) +
      ", " + CGUtils.toLiteral(o.getFrameRate()) +
      ", " + o.getAdvancedPrediction()
      ", " + o.getArithmeticCoding() +
      ", " + o.getErrorCompensation() +
      ", " + o.getHrDB() +
      ", " + o.getPBFrames() +
      ", " + o.getUnrestrictedVector()
      + ")";

     
    }
    else if (c == H261Format.class)
    {
 
      final H261Format o = (H261Format) f;
      return "new H261Format(" +
      toLiteral(o.getSize()) +
      ", " + o.getMaxDataLength() +
      ", " + dataTypeToStr(o.getDataType()) +
      ", " + CGUtils.toLiteral(o.getFrameRate()) +
      ", " + o.getStillImageTransmission()
      + ")";

     
    }
    else if (c == AudioFormat.class)
    {
      final AudioFormat o = (AudioFormat) f;
      return "new AudioFormat(" +
      CGUtils.toLiteral(o.getEncoding()) +
      ", " + CGUtils.toLiteral(o.getSampleRate()) +
      ", " + CGUtils.toLiteral(o.getSampleSizeInBits()) +
      ", " + CGUtils.toLiteral(o.getChannels()) +
      ", " + CGUtils.toLiteral(o.getEndian()) +
      ", " + CGUtils.toLiteral(o.getSigned()) +
      ", " + CGUtils.toLiteral(o.getFrameSizeInBits()) +
      ", " + CGUtils.toLiteral(o.getFrameRate()) +
      ", " + dataTypeToStr(o.getDataType())
      + ")";

     
    }
    else if (c == VideoFormat.class)
    {
     
      final VideoFormat o = (VideoFormat) f;
      return "new VideoFormat(" +
      CGUtils.toLiteral(o.getEncoding()) +
      ", " + toLiteral(o.getSize()) +
      ", " + o.getMaxDataLength() +
      ", " + dataTypeToStr(o.getDataType()) +
      ", " + CGUtils.toLiteral(o.getFrameRate())
      + ")";

     
    }
    else if (c == Format.class)
    {
 
      final Format o = (Format) f;
      return "new Format(" +
      CGUtils.toLiteral(o.getEncoding()) +
      ", " + dataTypeToStr(o.getDataType())
      + ")";

     
    }
    else if (c == FileTypeDescriptor.class)
    {
      final FileTypeDescriptor o = (FileTypeDescriptor) f;
      return "new FileTypeDescriptor(" +
      CGUtils.toLiteral(o.getEncoding())
      + ")";
    }
    else if (c == ContentDescriptor.class)
    {
      final ContentDescriptor o = (ContentDescriptor) f;
      return "new ContentDescriptor(" +
      CGUtils.toLiteral(o.getEncoding())
      + ")";
    }
    else if (c == com.sun.media.format.WavAudioFormat.class)
    {
      // TODO: are the parameters correct?
      final com.sun.media.format.WavAudioFormat o = (com.sun.media.format.WavAudioFormat) f;
      return "new com.sun.media.format.WavAudioFormat(" +
      CGUtils.toLiteral(o.getEncoding()) +
      ", " + CGUtils.toLiteral(o.getSampleRate()) +
      //", -1" + // int arg TODO - what is this?
      ", " + CGUtils.toLiteral(o.getSampleSizeInBits()) +
      ", " + CGUtils.toLiteral(o.getChannels()) +
      ", " + CGUtils.toLiteral(o.getFrameSizeInBits()) +
      ", " + CGUtils.toLiteral(o.getAverageBytesPerSecond()) +
      ", " + CGUtils.toLiteral(o.getEndian()) +
      ", " + CGUtils.toLiteral(o.getSigned()) +
      ", " + CGUtils.toLiteral((float) o.getFrameRate()) +
      ", " + dataTypeToStr(o.getDataType()) +
      ", " + CGUtils.toLiteral(o.getCodecSpecificHeader())
      + ")";
    }
    else
    throw new IllegalArgumentException("" + f.getClass());
      //System.err.println(f.getClass());
View Full Code Here

Examples of javax.media.format.RGBFormat

//       
//      }
     
      if (b.fourcc.equals("RGB"))
      {
        final RGBFormat f;
       
        if (b.biWidth == 0)
          continue;
        if (b.biHeight == 0)
          continue;
       
        try
        {
          if (j == 0)
            f = (RGBFormat) b.createVideoFormat(classes[i]);
          else
            f = (RGBFormat) b.createVideoFormat(classes[i], frameRates[j]);
        }
        catch (ArithmeticException e)
        {
          e.printStackTrace();
          continue;
        }
        assertEquals(f.getEncoding(), b.fourcc.toLowerCase());
        assertEquals(f.getBitsPerPixel(), b.biBitCount);
        assertEquals(f.getDataType(), classes[i]);
        assertEquals(f.getFrameRate(), j == 0 ? -1.f : frameRates[j]);
        //assertEquals(f.getMaxDataLength(), -2);  // TODO: sometimes -1, sometimes -2
        assertEquals(f.getSize(), new Dimension(b.biWidth, b.biHeight));
       
        if (f.getBitsPerPixel() == 24)
        {  assertEquals(f.getBlueMask(), 1)
          assertEquals(f.getGreenMask(), 2);
          assertEquals(f.getRedMask(), 3);
          if (classes[i] == byte[].class)
          {  assertEquals(f.getPixelStride(), 3);
            assertEquals(f.getLineStride(), f.getPixelStride() * b.biWidth);
         
            assertEquals(f.getMaxDataLength(), b.biSizeImage);
           

          }
          else if (classes[i] == short[].class)
          {  assertEquals(f.getPixelStride(), 1);
//            if (f.getLineStride() != b.biWidth)
//              System.out.println(b.biWidth);
//            assertEquals(f.getLineStride(), b.biWidth);  // 1, 2, or 3...
//          assertEquals(f.getLineStride(), f.getPixelStride() * b.biWidth); // TODO
         
            assertEquals(f.getMaxDataLength(), b.biSizeImage / 2);
            if (b.biSizeImage == 0)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 1)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 2)
              assertEquals(f.getMaxDataLength(), 1);
            else if (b.biSizeImage == 3)
              assertEquals(f.getMaxDataLength(), 1);
            else if (b.biSizeImage == 6)
              assertEquals(f.getMaxDataLength(), 3);
            else if (b.biSizeImage == 12)
              assertEquals(f.getMaxDataLength(), 6);
            else
              System.out.println(b.biSizeImage);
         
         
         

          }
          else if (classes[i] == int[].class)
          {  assertEquals(f.getPixelStride(), 0);
          //assertEquals(f.getLineStride(), f.getPixelStride() * b.biWidth); // TODO
          //assertEquals(f.getMaxDataLength(), 0);
         
            assertEquals(f.getMaxDataLength(), b.biSizeImage / 4);
            if (b.biSizeImage == 0)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 1)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 2)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 3)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 6)
              assertEquals(f.getMaxDataLength(), 1);
            else if (b.biSizeImage == 12)
              assertEquals(f.getMaxDataLength(), 3);
            else
              System.out.println(b.biSizeImage);

          }
         

        }
        else if (f.getBitsPerPixel() == 32)
        {
          if (classes[i] == byte[].class)
          {  assertEquals(f.getBlueMask(), 1)
            assertEquals(f.getGreenMask(), 2);
            assertEquals(f.getRedMask(), 3);
           
            assertEquals(f.getPixelStride(), 4);
            assertEquals(f.getLineStride(), f.getPixelStride() * b.biWidth);
           
            assertEquals(f.getMaxDataLength(), b.biSizeImage);

 
          }
          else if (classes[i] == int[].class)
          {  assertEquals(f.getBlueMask(), 0xFF)
            assertEquals(f.getGreenMask(), 0xFF00);
            assertEquals(f.getRedMask(), 0xFF0000);
           
            assertEquals(f.getPixelStride(), 1);
            assertEquals(f.getLineStride(), f.getPixelStride() * b.biWidth);
           
            assertEquals(f.getMaxDataLength(), b.biSizeImage / 4);
           
            if (b.biSizeImage == 0)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 1)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 2)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 3)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 6)
              assertEquals(f.getMaxDataLength(), 1);
            else if (b.biSizeImage == 12)
              assertEquals(f.getMaxDataLength(), 3);
            else
              System.out.println(b.biSizeImage);
           
 
          }
          else if (classes[i] == short[].class)
          {  assertEquals(f.getBlueMask(), 1)
            assertEquals(f.getGreenMask(), 2);
            assertEquals(f.getRedMask(), 3);
            assertEquals(f.getPixelStride(), 2);
            assertEquals(f.getLineStride(), f.getPixelStride() * b.biWidth);
           
            assertEquals(f.getMaxDataLength(), b.biSizeImage / 2);
            if (b.biSizeImage == 0)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 1)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 2)
              assertEquals(f.getMaxDataLength(), 1);
            else if (b.biSizeImage == 3)
              assertEquals(f.getMaxDataLength(), 1);
            else if (b.biSizeImage == 6)
              assertEquals(f.getMaxDataLength(), 3);
            else if (b.biSizeImage == 12)
              assertEquals(f.getMaxDataLength(), 6);
            else
              System.out.println(b.biSizeImage);
          }
        }
        else if (f.getBitsPerPixel() == 16)
        {
          assertEquals(f.getBlueMask(), 31)
          assertEquals(f.getGreenMask(), 992);
          assertEquals(f.getRedMask(), 31744);
         
          if (classes[i] == byte[].class)
          {
            assertEquals(f.getPixelStride(), 2);
           
            assertEquals(f.getMaxDataLength(), b.biSizeImage);
            if (b.biSizeImage == 0)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 1)
              assertEquals(f.getMaxDataLength(), 1);
            else if (b.biSizeImage == 2)
              assertEquals(f.getMaxDataLength(), 2);
            else if (b.biSizeImage == 3)
              assertEquals(f.getMaxDataLength(), 3);
            else if (b.biSizeImage == 6)
              assertEquals(f.getMaxDataLength(), 6);
            else if (b.biSizeImage == 12)
              assertEquals(f.getMaxDataLength(), 12);
            else
              System.out.println(b.biSizeImage);
           
          }
          else if (classes[i] == short[].class)
          {
           
            assertEquals(f.getPixelStride(), 1);
           
            assertEquals(f.getMaxDataLength(), b.biSizeImage / 2);
            if (b.biSizeImage == 0)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 1)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 2)
              assertEquals(f.getMaxDataLength(), 1);
            else if (b.biSizeImage == 3)
              assertEquals(f.getMaxDataLength(), 1);
            else if (b.biSizeImage == 6)
              assertEquals(f.getMaxDataLength(), 3);
            else if (b.biSizeImage == 12)
              assertEquals(f.getMaxDataLength(), 6);
            else
              System.out.println(b.biSizeImage);
             
           
           
          }
          else if (classes[i] == int[].class)
          {
           
            assertEquals(f.getPixelStride(), 0);
           
            assertEquals(f.getMaxDataLength(), b.biSizeImage / 4);
            if (b.biSizeImage == 0)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 1)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 2)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 3)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 6)
              assertEquals(f.getMaxDataLength(), 1);
            else if (b.biSizeImage == 12)
              assertEquals(f.getMaxDataLength(), 3);
            else
              System.out.println(b.biSizeImage);
          }
         
        }
        else if (f.getBitsPerPixel() == 8 || f.getBitsPerPixel() == 12)
        {
          assertEquals(f.getBlueMask(), -1)
          assertEquals(f.getGreenMask(), -1);
          assertEquals(f.getRedMask(), -1);
         
          if (classes[i] == byte[].class)
          {
            assertEquals(f.getPixelStride(), 1);
           
            assertEquals(f.getMaxDataLength(), b.biSizeImage);
            // same as 16-bit
            if (b.biSizeImage == 0)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 1)
              assertEquals(f.getMaxDataLength(), 1);
            else if (b.biSizeImage == 2)
            {  //dump(b);
              assertEquals(f.getMaxDataLength(), 2);
            }
            else if (b.biSizeImage == 3)
              assertEquals(f.getMaxDataLength(), 3);
            else if (b.biSizeImage == 6)
              assertEquals(f.getMaxDataLength(), 6);
            else if (b.biSizeImage == 12)
              assertEquals(f.getMaxDataLength(), 12);
            else
              System.out.println(b.biSizeImage);
          }
          else if (classes[i] == short[].class)
          {
            assertEquals(f.getPixelStride(), 0);
           
//             same as 16-bit: ??
           
            assertEquals(f.getMaxDataLength(), b.biSizeImage / 2);
            if (b.biSizeImage == 0)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 1)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 2)
              assertEquals(f.getMaxDataLength(), 1);
            else if (b.biSizeImage == 3)
              assertEquals(f.getMaxDataLength(), 1);
            else if (b.biSizeImage == 6)
              assertEquals(f.getMaxDataLength(), 3);
            else if (b.biSizeImage == 12)
              assertEquals(f.getMaxDataLength(), 6);
            else
              System.out.println(b.biSizeImage);
             
          }
          else if (classes[i] == int[].class)
          {
            assertEquals(f.getPixelStride(), 0);
           
            assertEquals(f.getMaxDataLength(), b.biSizeImage / 4);
            // same as 16-bit:
            if (b.biSizeImage == 0)
            { 
              //dump(b);
              assertEquals(f.getMaxDataLength(), 0);
            }
            else if (b.biSizeImage == 1)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 2)
            { 
              //dump(b);
              assertEquals(f.getMaxDataLength(), 0);
            }
            else if (b.biSizeImage == 3)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 6)
              assertEquals(f.getMaxDataLength(), 1);
            else if (b.biSizeImage == 12)
              assertEquals(f.getMaxDataLength(), 3);
            else
              System.out.println(b.biSizeImage);
          }
         
        }
        else
        assertEquals(f.getBlueMask(), -1)
          assertEquals(f.getGreenMask(), -1);
          assertEquals(f.getRedMask(), -1);
         
          assertEquals(f.getPixelStride(), 0)// TODO: 0 or 1
          //assertEquals(f.getMaxDataLength(), -2); // TODO: -1 or -2

          if (classes[i] == byte[].class)
          {
           
            assertEquals(f.getMaxDataLength(), b.biSizeImage);
           
            // same as 16-bit, except -2 case is new
            if (b.biSizeImage == 0)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 1)
              assertEquals(f.getMaxDataLength(), 1);
            else if (b.biSizeImage == 2)
              assertEquals(f.getMaxDataLength(), 2);
            else if (b.biSizeImage == 3)
              assertEquals(f.getMaxDataLength(), 1);
            else if (b.biSizeImage == 6)
              assertEquals(f.getMaxDataLength(), 3);
            else if (b.biSizeImage == 12)
              assertEquals(f.getMaxDataLength(), 6);
            else if (b.biSizeImage == -2)
              assertEquals(f.getMaxDataLength(), -2);
            else
              System.out.println(b.biSizeImage);
          }
          else if (classes[i] == short[].class)
          {
            assertEquals(f.getMaxDataLength(), b.biSizeImage / 2);
//             same as 16-bit:
            assertEquals(f.getMaxDataLength(), -1);
          }
          else if (classes[i] == int[].class)
          {
           
            assertEquals(f.getMaxDataLength(), b.biSizeImage / 4);
           
            // same as 16-bit:, except -2 case is new
            if (b.biSizeImage == 0)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 1)
              assertEquals(f.getMaxDataLength(), 0);
            else if (b.biSizeImage == 2)
              assertEquals(f.getMaxDataLength(), 1);
            else if (b.biSizeImage == 3)
              assertEquals(f.getMaxDataLength(), 1);
            else if (b.biSizeImage == 6)
              assertEquals(f.getMaxDataLength(), 3);
            else if (b.biSizeImage == 12)
              assertEquals(f.getMaxDataLength(), 6);
            else if (b.biSizeImage == -2)
              assertEquals(f.getMaxDataLength(), 0);
            else
              System.out.println("X" + b.biSizeImage);
          }
             
 
        }
        assertEquals(f.getEndian(), 1);
        assertEquals(f.getFlipped(), 1);
        //assertEquals(f.getLineStride(), -40);  // TODO: varies, sometimes -40, sometimes -20
     
       
       
      }
      else if (b.fourcc.equals("YV12"))
      {
        final YUVFormat f;
        if (j == 0)
          f = (YUVFormat) b.createVideoFormat(classes[i]);
        else
          f = (YUVFormat) b.createVideoFormat(classes[i], frameRates[j]);
       
        assertEquals(f.getEncoding(), "yuv");
        assertEquals(f.getYuvType(), YUVFormat.YUV_420);
        assertEquals(f.getDataType(), byte[].class);
        assertEquals(f.getFrameRate(), j == 0 ? -1.f : frameRates[j]);
        assertEquals(f.getSize(), new Dimension(b.biWidth, b.biHeight));
       
        assertEquals(f.getMaxDataLength(), b.biSizeImage); // sometimes 0
        assertEquals(f.getOffsetY(), 0);
        assertEquals(f.getOffsetU(), b.biWidth *  b.biHeight + (b.biWidth *  b.biHeight) / 4)// empirically determined
        //320x240: 96000
        // 96000 - 76800 = 19200.  96000 / 76800 = 1.25
        //
        assertEquals(f.getOffsetV(), b.biWidth *  b.biHeight);
       
        assertEquals(f.getStrideUV(), b.biWidth / 2);
        assertEquals(f.getStrideY(), b.biWidth)
       
      }
      else
      {
        final com.sun.media.format.AviVideoFormat f;
        if (j == 0)
          f = (com.sun.media.format.AviVideoFormat) b.createVideoFormat(classes[i]);
        else
          f = (com.sun.media.format.AviVideoFormat) b.createVideoFormat(classes[i], frameRates[j]);
        assertEquals(f.getEncoding(), b.fourcc);
        assertEquals(f.getBitsPerPixel(), b.biBitCount);
        assertEquals(f.getClrImportant(), b.biClrImportant);
        assertEquals(f.getClrUsed(), b.biClrUsed);
        assertEquals(f.getCodecSpecificHeader(), b.extraBytes);
        assertEquals(f.getDataType(), classes[i]);
        assertEquals(f.getFrameRate(), j == 0 ? -1.f : frameRates[j]);
        assertEquals(f.getImageSize(), b.biSizeImage);
        assertEquals(f.getMaxDataLength(), b.biSizeImage);
        assertEquals(f.getPlanes(), b.biPlanes);
        assertEquals(f.getSize(), new Dimension(b.biWidth, b.biHeight));
        assertEquals(f.getXPelsPerMeter(), b.biXPelsPerMeter);
        assertEquals(f.getYPelsPerMeter(), b.biYPelsPerMeter);
      }
    }
   

  }
View Full Code Here

Examples of javax.media.format.RGBFormat

    synchronized (javax.media.PlugInManager.class// so that tests that modify the plugins don't conflict.
    {
    assertPlugInManagersEqual();

    {
      final Format in = new RGBFormat();
      final Format out = new RGBFormat();
     
      final Vector v1 = javax.media.PlugInManager.getPlugInList(in, out, javax.media.PlugInManager.DEMULTIPLEXER);
      final Vector v2 = net.sf.fmj.test.compat.plugins.PlugInManager.getPlugInList(in, out, javax.media.PlugInManager.DEMULTIPLEXER);
     
     
View Full Code Here

Examples of javax.media.format.RGBFormat

    final MyBasicCodec c = new MyBasicCodec();
    assertEquals(c.doCheckFormat(null), true);
    assertEquals(c.doCheckFormat(new Format(null)), true);
    assertEquals(c.doCheckFormat(new Format("xyz")), true);
   
    c.setInputFormat(new RGBFormat());
    assertEquals(c.doCheckFormat(null), true);
    assertEquals(c.doCheckFormat(new YUVFormat()), true);
 
 
    c.setInputFormats(new Format[]{new RGBFormat()});
    assertEquals(c.doCheckFormat(null), true);
    assertEquals(c.doCheckFormat(new YUVFormat()), true);
   
    c.setOutputFormats(new Format[]{new RGBFormat()});
    assertEquals(c.doCheckFormat(null), true);
    assertEquals(c.doCheckFormat(new YUVFormat()), true);

    c.setOutputFormat(new RGBFormat());
    assertEquals(c.doCheckFormat(null), true);
    assertEquals(c.doCheckFormat(new YUVFormat()), true);
   
    {
      final TracingFormat f = new TracingFormat("zzz");
View Full Code Here

Examples of javax.media.format.RGBFormat

    {
      final MyBasicCodec c = new MyBasicCodec();
      final Buffer b = new Buffer();
      final Format f = new YUVFormat();
      b.setFormat(f);
      c.setInputFormat(new RGBFormat());
     
      assertEquals(c.doCheckInputBuffer(b), true);
    }
   
    {
      final MyBasicCodec c = new MyBasicCodec();
      final Buffer b = new Buffer();
      final Format f = new Format(null);
      b.setFormat(f);
      b.setLength(-1);
      b.setOffset(-1);
      b.setEOM(true);
      b.setDuration(-1L);
     
      c.setInputFormat(new RGBFormat());
     
      assertEquals(c.doCheckInputBuffer(b), true);
    }
 
    {
View Full Code Here

Examples of javax.media.format.RGBFormat

        list.add(floatToStr(vf.getFrameRate()));
       
      }
      else if (f.getClass() == RGBFormat.class)
      {
        final RGBFormat rf = (RGBFormat) vf;
        list.add(dimensionToStr(vf.getSize()));
        list.add(intToStr(vf.getMaxDataLength()));
        if (vf.getDataType() != null && vf.getDataType() != Format.byteArray)
          list.add(dataTypeToStr(vf.getDataType()));
        list.add(floatToStr(vf.getFrameRate()));
        list.add(intToStr(rf.getBitsPerPixel()));
        list.add(intToStr(rf.getRedMask()))// TODO: hex?
        list.add(intToStr(rf.getGreenMask()));
        list.add(intToStr(rf.getBlueMask()));
        list.add(intToStr(rf.getPixelStride()));
        list.add(intToStr(rf.getLineStride()));
        list.add(intToStr(rf.getFlipped()));    // TODO: use a string code for this?
        list.add(rgbFormatEndianToStr(rf.getEndian()));

      }
      else
        throw new IllegalArgumentException("Unknown or unsupported format: " + f);
    }
View Full Code Here

Examples of javax.media.format.RGBFormat

        final int lineStride = t.nextInt();
        final int flipped = t.nextInt();
        final int endian = t.nextRGBFormatEndian();
             
        if (pixelStride == -1 && lineStride == -1 && flipped == -1 && endian == -1)
          return new RGBFormat(size, maxDataLength, dataType, frameRate, bitsPerPixel, red, green, blue);

        return new RGBFormat(size, maxDataLength, dataType, frameRate, bitsPerPixel, red, green, blue, pixelStride, lineStride, flipped, endian);
      }
     
//      public RGBFormat(java.awt.Dimension size, int maxDataLength,
//          Class dataType, float frameRate, int bitsPerPixel,
//          int red, int green, int blue, int pixelStride, int lineStride,
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.