001: /*
002: * Copyright 1990-2007 Sun Microsystems, Inc. All Rights Reserved.
003: * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER
004: *
005: * This program is free software; you can redistribute it and/or
006: * modify it under the terms of the GNU General Public License version
007: * 2 only, as published by the Free Software Foundation.
008: *
009: * This program is distributed in the hope that it will be useful, but
010: * WITHOUT ANY WARRANTY; without even the implied warranty of
011: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
012: * General Public License version 2 for more details (a copy is
013: * included at /legal/license.txt).
014: *
015: * You should have received a copy of the GNU General Public License
016: * version 2 along with this work; if not, write to the Free Software
017: * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
018: * 02110-1301 USA
019: *
020: * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa
021: * Clara, CA 95054 or visit www.sun.com if you need additional
022: * information or have any questions.
023: */
024: package com.sun.mmedia;
025:
026: import javax.microedition.media.MediaException;
027: import javax.microedition.media.Control;
028:
029: /**
030: * Description of the Class
031: *
032: * @created January 17, 2005
033: */
034: public abstract class VideoRenderer {
035: // Frame types
036: /**
037: * Description of the Field
038: */
039: public final static int RGB565 = 1;
040: // short []
041: /**
042: * Description of the Field
043: */
044: public final static int RGB888 = 2;
045: // byte []
046: /**
047: * Description of the Field
048: */
049: public final static int XRGB888 = 3;
050: // int []
051: /**
052: * Description of the Field
053: */
054: public final static int XBGR888 = 4;
055: // int []
056: /**
057: * Description of the Field
058: */
059: public final static int RGBX888 = 5;
060: // int []
061: /**
062: * Description of the Field
063: */
064: public final static int YUV420_PLANAR = 6;
065: // byte []
066: /**
067: * Description of the Field
068: */
069: public final static int YUV422_PLANAR = 7;
070: // byte []
071: /**
072: * Description of the Field
073: */
074: public final static int YUYV = 8;
075: // byte []
076: /**
077: * Description of the Field
078: */
079: public final static int UYVY = 9;
080: // byte []
081: /**
082: * Description of the Field
083: */
084: public final static int YVYU = 10;
085: // byte []
086: /**
087: * Description of the Field
088: */
089: public final static int NATIVE_RENDER = 128;
090: // to be ORed with above
091: /**
092: * Description of the Field
093: */
094: public final static int USE_ALPHA = 256;
095:
096: public abstract void initRendering(int mode, int width, int height);
097:
098: public abstract void render(int[] rgbData);
099:
100: public abstract void close();
101:
102: public abstract Control getVideoControl();
103: }
|