Package javax.media

Examples of javax.media.Format.matches()


      {
        Format f2 = f2s[i];
        assertTrue(f1.equals(f2));
        assertTrue(f1.matches(f2));
        assertTrue(f2.equals(f1));
        assertTrue(f2.matches(f1));
      }
    }
   
    // not equal and not match:
    {
View Full Code Here


        Format f2 = f2s[i];
        //System.out.println(f2);
        assertFalse(f1.equals(f2));
        assertFalse(f1.matches(f2));
        assertFalse(f2.equals(f1));
        assertFalse(f2.matches(f1));
      }
    }

    // not equal but match:
    {     
View Full Code Here

        Format f2 = f2s[i];
        //System.out.println(f2);
        assertFalse(f1.equals(f2));
        assertTrue(f1.matches(f2));
        assertFalse(f2.equals(f1));
        assertTrue(f2.matches(f1));
      }
    }
  }
 
  public void testEqualsMatches()
View Full Code Here

      final Format f1 = new Format("abc");
      final Format f2 = new VideoFormat("abc");
      assertFalse(f1.equals(f2));
      assertFalse(f2.equals(f1));
      assertTrue(f1.matches(f2));
      assertTrue(f2.matches(f2));
         
    }
   
    {
      final Format f1 = new Format(VideoFormat.MPEG);
View Full Code Here

      final Format f1 = new Format(VideoFormat.MPEG);
      final Format f2 = new VideoFormat(VideoFormat.MPEG, new Dimension(0, 0), 1000, Format.byteArray, 1.f);
      assertFalse(f1.equals(f2));
      assertFalse(f2.equals(f1));
      assertTrue(f1.matches(f2));
      assertTrue(f2.matches(f2));
         
    }
    {
      final Format f1 = new Format("abc", Format.byteArray);
      final Format f2 = f1.relax();
View Full Code Here

   
    {
      final VideoFormat f1 = new VideoFormat(VideoFormat.MPEG, new Dimension(0, 0), 1000, Format.byteArray, 1.f);
      final VideoFormat f2 = new VideoFormat(VideoFormat.MPEG, new Dimension(1, 0), 1000, Format.byteArray, 1.f);
      assertFalse(f1.matches(f2));
      assertFalse(f2.matches(f1));
    }

    {
      final VideoFormat f1 = new VideoFormat(VideoFormat.MPEG.toLowerCase(), new Dimension(0, 0), 1000, Format.byteArray, 1.f);
      final VideoFormat f2 = new VideoFormat(VideoFormat.MPEG.toUpperCase(), new Dimension(0, 0), 1000, Format.byteArray, 1.f);
View Full Code Here

    {
      final VideoFormat f1 = new VideoFormat(VideoFormat.MPEG.toLowerCase(), new Dimension(0, 0), 1000, Format.byteArray, 1.f);
      final VideoFormat f2 = new VideoFormat(VideoFormat.MPEG.toUpperCase(), new Dimension(0, 0), 1000, Format.byteArray, 1.f);
      assertTrue(f1.matches(f2));
      assertTrue(f2.matches(f1));
      assertTrue(f1.equals(f2));
      assertTrue(f2.equals(f1));

    }
   
View Full Code Here

   
    {
      final VideoFormat f1 = new VideoFormat(VideoFormat.MPEG, new Dimension(0, 0), 1000, Format.byteArray, 1.f);
      final VideoFormat f2 = new VideoFormat(VideoFormat.MPEG, null, 1000, Format.byteArray, 1.f);
      assertTrue(f1.matches(f2));
      assertTrue(f2.matches(f1));
    }
   
    {
      final VideoFormat f1 = new VideoFormat(VideoFormat.MPEG, new Dimension(0, 0), 1000, Format.byteArray, 1.f);
      final VideoFormat f2 = new VideoFormat(VideoFormat.MPEG, new Dimension(0, 0), 1001, Format.byteArray, 1.f);
View Full Code Here

   
    {
      final VideoFormat f1 = new VideoFormat(VideoFormat.MPEG, new Dimension(0, 0), 1000, Format.byteArray, 1.f);
      final VideoFormat f2 = new VideoFormat(VideoFormat.MPEG, new Dimension(0, 0), 1001, Format.byteArray, 1.f);
      assertTrue(f1.matches(f2));
      assertTrue(f2.matches(f1));
    }
   
    {
      final VideoFormat f1 = new VideoFormat(VideoFormat.MPEG, new Dimension(0, 0), 1000, Format.byteArray, 1.f);
      final VideoFormat f2 = new VideoFormat(VideoFormat.MPEG, new Dimension(0, 0), Format.NOT_SPECIFIED, Format.byteArray, 1.f);
View Full Code Here

   
    {
      final VideoFormat f1 = new VideoFormat(VideoFormat.MPEG, new Dimension(0, 0), 1000, Format.byteArray, 1.f);
      final VideoFormat f2 = new VideoFormat(VideoFormat.MPEG, new Dimension(0, 0), Format.NOT_SPECIFIED, Format.byteArray, 1.f);
      assertTrue(f1.matches(f2));
      assertTrue(f2.matches(f1));
    }
   
    {
      final VideoFormat f1 = new VideoFormat(VideoFormat.MPEG, new Dimension(0, 0), 1000, Format.byteArray, 1.f);
      final VideoFormat f2 = new VideoFormat(null, new Dimension(0, 0), 1000, Format.byteArray, 1.f);
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.