summaryrefslogtreecommitdiffstats
path: root/media
diff options
context:
space:
mode:
Diffstat (limited to 'media')
-rw-r--r--media/java/android/media/AmrInputStream.java2
-rw-r--r--media/java/android/media/AsyncPlayer.java2
-rw-r--r--media/java/android/media/AudioFormat.java3
-rw-r--r--media/java/android/media/AudioManager.java1
-rw-r--r--media/java/android/media/AudioRecord.java12
-rw-r--r--media/java/android/media/AudioService.java12
-rw-r--r--media/java/android/media/AudioTrack.java2
-rw-r--r--media/java/android/media/EncoderCapabilities.java1
-rw-r--r--media/java/android/media/ExifInterface.java2
-rw-r--r--media/java/android/media/Image.java12
-rw-r--r--media/java/android/media/ImageReader.java3
-rw-r--r--media/java/android/media/MediaDrm.java2
-rw-r--r--media/java/android/media/MediaFile.java5
-rw-r--r--media/java/android/media/MediaFocusControl.java1
-rw-r--r--media/java/android/media/MediaMetadataEditor.java1
-rw-r--r--media/java/android/media/MediaPlayer.java3
-rw-r--r--media/java/android/media/MediaRecorder.java31
-rw-r--r--media/java/android/media/Metadata.java1
-rw-r--r--media/java/android/media/MiniThumbFile.java1
-rw-r--r--media/java/android/media/Rating.java1
-rw-r--r--media/java/android/media/RemoteControlClient.java2
-rw-r--r--media/java/android/media/RemoteController.java5
-rw-r--r--media/java/android/media/ResampleInputStream.java2
-rw-r--r--media/java/android/media/RingtoneManager.java1
-rw-r--r--media/java/android/media/SoundPool.java1
-rw-r--r--media/java/android/media/SubtitleData.java1
-rw-r--r--media/java/android/media/ThumbnailUtils.java6
-rw-r--r--media/java/android/media/WebVttRenderer.java14
-rw-r--r--media/java/android/media/audiofx/AudioEffect.java1
-rw-r--r--media/java/android/media/audiofx/BassBoost.java7
-rw-r--r--media/java/android/media/audiofx/EnvironmentalReverb.java8
-rw-r--r--media/java/android/media/audiofx/Equalizer.java7
-rw-r--r--media/java/android/media/audiofx/PresetReverb.java8
-rw-r--r--media/java/android/media/audiofx/Virtualizer.java7
-rw-r--r--media/java/android/media/audiofx/Visualizer.java1
-rw-r--r--media/java/android/media/videoeditor/MediaArtistNativeHelper.java1
-rwxr-xr-xmedia/java/android/mtp/MtpDatabase.java2
-rw-r--r--media/java/android/mtp/MtpDevice.java2
-rw-r--r--media/java/android/mtp/MtpPropertyGroup.java1
-rw-r--r--media/jni/Android.mk4
-rw-r--r--media/jni/android_media_MediaRecorder.cpp21
-rw-r--r--media/jni/android_mtp_MtpDatabase.cpp76
-rw-r--r--media/lib/java/com/android/media/remotedisplay/RemoteDisplay.java1
-rw-r--r--media/mca/effect/java/android/media/effect/EffectContext.java3
-rw-r--r--media/mca/effect/java/android/media/effect/EffectFactory.java1
-rw-r--r--media/mca/effect/java/android/media/effect/FilterEffect.java3
-rw-r--r--media/mca/effect/java/android/media/effect/FilterGraphEffect.java4
-rw-r--r--media/mca/effect/java/android/media/effect/SingleFilterEffect.java3
-rw-r--r--media/mca/effect/java/android/media/effect/SizeChangeEffect.java6
-rw-r--r--media/mca/effect/java/android/media/effect/effects/CropEffect.java1
-rw-r--r--media/mca/filterfw/java/android/filterfw/FilterFunctionEnvironment.java1
-rw-r--r--media/mca/filterfw/java/android/filterfw/core/AsyncRunner.java8
-rw-r--r--media/mca/filterfw/java/android/filterfw/core/Filter.java1
-rw-r--r--media/mca/filterfw/java/android/filterfw/core/Frame.java1
-rw-r--r--media/mca/filterfw/java/android/filterfw/core/NativeFrame.java2
-rw-r--r--media/mca/filterfw/java/android/filterfw/core/OneShotScheduler.java1
-rw-r--r--media/mca/filterfw/java/android/filterfw/core/SerializedFrame.java4
-rw-r--r--media/mca/filterfw/java/android/filterfw/core/SimpleFrame.java2
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/base/CallbackFilter.java5
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/base/FrameBranch.java1
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/base/FrameFetch.java2
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/base/FrameStore.java1
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/base/GLTextureSource.java3
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/base/GLTextureTarget.java3
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/base/InputStreamSource.java1
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/base/NullFilter.java2
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/base/ObjectSource.java3
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/base/OutputStreamTarget.java1
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/base/RetargetFilter.java2
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/AlphaBlendFilter.java9
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/AutoFixFilter.java3
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/BitmapOverlayFilter.java6
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/BitmapSource.java6
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/BlackWhiteFilter.java3
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/BlendFilter.java9
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/BrightnessFilter.java5
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/ColorTemperatureFilter.java4
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/ContrastFilter.java7
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/CropFilter.java6
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/CropRectFilter.java5
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/CrossProcessFilter.java5
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/DocumentaryFilter.java3
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/DrawOverlayFilter.java6
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/DrawRectFilter.java3
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/DuotoneFilter.java3
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/FillLightFilter.java4
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/FisheyeFilter.java6
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/FixedRotationFilter.java1
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/FlipFilter.java4
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/GrainFilter.java5
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/ImageCombineFilter.java6
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/ImageEncoder.java5
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/ImageSlicer.java2
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/ImageStitcher.java4
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/Invert.java4
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/LomoishFilter.java3
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/NegativeFilter.java3
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/PosterizeFilter.java3
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/RedEyeFilter.java5
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/ResizeFilter.java3
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/RotateFilter.java5
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/SaturateFilter.java3
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/SepiaFilter.java3
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/SharpenFilter.java5
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/SimpleImageFilter.java6
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/StraightenFilter.java5
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/TintFilter.java3
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/ToGrayFilter.java9
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/ToPackedGrayFilter.java2
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/ToRGBAFilter.java5
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/ToRGBFilter.java5
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/imageproc/VignetteFilter.java3
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/text/StringSource.java2
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/ui/SurfaceRenderFilter.java8
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/ui/SurfaceTargetFilter.java8
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/videoproc/BackDropperFilter.java2
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/videosink/MediaEncoderFilter.java9
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/videosink/MediaRecorderStopException.java1
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/videosrc/CameraSource.java7
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/videosrc/MediaSource.java8
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/videosrc/SurfaceTextureSource.java11
-rw-r--r--media/mca/filterpacks/java/android/filterpacks/videosrc/SurfaceTextureTarget.java10
122 files changed, 133 insertions, 470 deletions
diff --git a/media/java/android/media/AmrInputStream.java b/media/java/android/media/AmrInputStream.java
index e2115e4..f90f1e2 100644
--- a/media/java/android/media/AmrInputStream.java
+++ b/media/java/android/media/AmrInputStream.java
@@ -16,8 +16,6 @@
package android.media;
-import android.util.Log;
-
import java.io.InputStream;
import java.io.IOException;
diff --git a/media/java/android/media/AsyncPlayer.java b/media/java/android/media/AsyncPlayer.java
index 804528e..14b199e 100644
--- a/media/java/android/media/AsyncPlayer.java
+++ b/media/java/android/media/AsyncPlayer.java
@@ -22,8 +22,6 @@ import android.os.PowerManager;
import android.os.SystemClock;
import android.util.Log;
-import java.io.IOException;
-import java.lang.IllegalStateException;
import java.util.LinkedList;
/**
diff --git a/media/java/android/media/AudioFormat.java b/media/java/android/media/AudioFormat.java
index 49f498e..26e9cc5 100644
--- a/media/java/android/media/AudioFormat.java
+++ b/media/java/android/media/AudioFormat.java
@@ -31,7 +31,8 @@ public class AudioFormat {
public static final int ENCODING_INVALID = 0;
/** Default audio data format */
public static final int ENCODING_DEFAULT = 1;
- // These two values must be kept in sync with JNI code for AudioTrack, AudioRecord
+
+ // These two values must be kept in sync with core/jni/android_media_AudioFormat.h
/** Audio data format: PCM 16 bit per sample. Guaranteed to be supported by devices. */
public static final int ENCODING_PCM_16BIT = 2;
/** Audio data format: PCM 8 bit per sample. Not guaranteed to be supported by devices. */
diff --git a/media/java/android/media/AudioManager.java b/media/java/android/media/AudioManager.java
index d652cae..8ae06e0 100644
--- a/media/java/android/media/AudioManager.java
+++ b/media/java/android/media/AudioManager.java
@@ -26,7 +26,6 @@ import android.content.Context;
import android.content.Intent;
import android.media.RemoteController.OnClientUpdateListener;
import android.os.Binder;
-import android.os.Build;
import android.os.Handler;
import android.os.IBinder;
import android.os.Looper;
diff --git a/media/java/android/media/AudioRecord.java b/media/java/android/media/AudioRecord.java
index f49ef2e..53afb6b 100644
--- a/media/java/android/media/AudioRecord.java
+++ b/media/java/android/media/AudioRecord.java
@@ -186,6 +186,9 @@ public class AudioRecord
//--------------------
/**
* Class constructor.
+ * Though some invalid parameters will result in an {@link IllegalArgumentException} exception,
+ * other errors do not. Thus you should call {@link #getState()} immediately after construction
+ * to confirm that the object is usable.
* @param audioSource the recording source. See {@link MediaRecorder.AudioSource} for
* recording source definitions.
* @param sampleRateInHz the sample rate expressed in Hertz. 44100Hz is currently the only
@@ -239,7 +242,7 @@ public class AudioRecord
// Convenience method for the constructor's parameter checks.
- // This is where constructor IllegalArgumentException-s are thrown
+ // This and audioBuffSizeCheck are where constructor IllegalArgumentException-s are thrown
// postconditions:
// mRecordSource is valid
// mChannelCount is valid
@@ -247,7 +250,8 @@ public class AudioRecord
// mAudioFormat is valid
// mSampleRate is valid
private void audioParamCheck(int audioSource, int sampleRateInHz,
- int channelConfig, int audioFormat) {
+ int channelConfig, int audioFormat)
+ throws IllegalArgumentException {
//--------------
// audio source
@@ -311,7 +315,7 @@ public class AudioRecord
// mAudioFormat is AudioFormat.ENCODING_PCM_8BIT OR AudioFormat.ENCODING_PCM_16BIT
// postcondition:
// mNativeBufferSizeInBytes is valid (multiple of frame size, positive)
- private void audioBuffSizeCheck(int audioBufferSize) {
+ private void audioBuffSizeCheck(int audioBufferSize) throws IllegalArgumentException {
// NB: this section is only valid with PCM data.
// To update when supporting compressed formats
int frameSizeInBytes = mChannelCount
@@ -800,7 +804,7 @@ public class AudioRecord
//--------------------
private native final int native_setup(Object audiorecord_this,
- int recordSource, int sampleRate, int nbChannels, int audioFormat,
+ int recordSource, int sampleRate, int channelMask, int audioFormat,
int buffSizeInBytes, int[] sessionId);
private native final void native_finalize();
diff --git a/media/java/android/media/AudioService.java b/media/java/android/media/AudioService.java
index b836f50..46b74da 100644
--- a/media/java/android/media/AudioService.java
+++ b/media/java/android/media/AudioService.java
@@ -21,20 +21,17 @@ import static android.media.AudioManager.RINGER_MODE_NORMAL;
import static android.media.AudioManager.RINGER_MODE_SILENT;
import static android.media.AudioManager.RINGER_MODE_VIBRATE;
-import android.app.Activity;
import android.app.ActivityManager;
import android.app.ActivityManagerNative;
import android.app.AppOpsManager;
import android.app.KeyguardManager;
import android.app.PendingIntent;
-import android.app.PendingIntent.CanceledException;
import android.bluetooth.BluetoothA2dp;
import android.bluetooth.BluetoothAdapter;
import android.bluetooth.BluetoothClass;
import android.bluetooth.BluetoothDevice;
import android.bluetooth.BluetoothHeadset;
import android.bluetooth.BluetoothProfile;
-import android.content.ActivityNotFoundException;
import android.content.BroadcastReceiver;
import android.content.ComponentName;
import android.content.ContentResolver;
@@ -48,10 +45,8 @@ import android.content.res.XmlResourceParser;
import android.database.ContentObserver;
import android.media.MediaPlayer.OnCompletionListener;
import android.media.MediaPlayer.OnErrorListener;
-import android.net.Uri;
import android.os.Binder;
import android.os.Build;
-import android.os.Bundle;
import android.os.Environment;
import android.os.Handler;
import android.os.IBinder;
@@ -66,9 +61,6 @@ import android.os.UserHandle;
import android.os.Vibrator;
import android.provider.Settings;
import android.provider.Settings.System;
-import android.speech.RecognizerIntent;
-import android.telephony.PhoneStateListener;
-import android.telephony.TelephonyManager;
import android.text.TextUtils;
import android.util.Log;
import android.view.KeyEvent;
@@ -88,13 +80,11 @@ import java.lang.reflect.Field;
import java.util.ArrayList;
import java.util.concurrent.ConcurrentHashMap;
import java.util.HashMap;
-import java.util.HashSet;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
import java.util.NoSuchElementException;
import java.util.Set;
-import java.util.Stack;
/**
* The implementation of the volume manager service.
@@ -1019,7 +1009,7 @@ public class AudioService extends IAudioService.Stub {
(flags & AudioManager.FLAG_BLUETOOTH_ABS_VOLUME) == 0) {
synchronized (mA2dpAvrcpLock) {
if (mA2dp != null && mAvrcpAbsVolSupported) {
- mA2dp.setAvrcpAbsoluteVolume(index);
+ mA2dp.setAvrcpAbsoluteVolume(index / 10);
}
}
}
diff --git a/media/java/android/media/AudioTrack.java b/media/java/android/media/AudioTrack.java
index 78a37c5..8756806 100644
--- a/media/java/android/media/AudioTrack.java
+++ b/media/java/android/media/AudioTrack.java
@@ -1319,7 +1319,7 @@ public class AudioTrack
//--------------------
private native final int native_setup(Object audiotrack_this,
- int streamType, int sampleRate, int nbChannels, int audioFormat,
+ int streamType, int sampleRate, int channelMask, int audioFormat,
int buffSizeInBytes, int mode, int[] sessionId);
private native final void native_finalize();
diff --git a/media/java/android/media/EncoderCapabilities.java b/media/java/android/media/EncoderCapabilities.java
index 71cb1b3..332e360 100644
--- a/media/java/android/media/EncoderCapabilities.java
+++ b/media/java/android/media/EncoderCapabilities.java
@@ -18,7 +18,6 @@ package android.media;
import java.util.List;
import java.util.ArrayList;
-import android.util.Log;
/**
* The EncoderCapabilities class is used to retrieve the
diff --git a/media/java/android/media/ExifInterface.java b/media/java/android/media/ExifInterface.java
index 20eb356..9db35fc 100644
--- a/media/java/android/media/ExifInterface.java
+++ b/media/java/android/media/ExifInterface.java
@@ -98,7 +98,7 @@ public class ExifInterface {
private static SimpleDateFormat sFormatter;
static {
- System.loadLibrary("exif_jni");
+ System.loadLibrary("jhead_jni");
sFormatter = new SimpleDateFormat("yyyy:MM:dd HH:mm:ss");
sFormatter.setTimeZone(TimeZone.getTimeZone("UTC"));
}
diff --git a/media/java/android/media/Image.java b/media/java/android/media/Image.java
index 23abce7..a346e17 100644
--- a/media/java/android/media/Image.java
+++ b/media/java/android/media/Image.java
@@ -21,7 +21,8 @@ import java.lang.AutoCloseable;
/**
* <p>A single complete image buffer to use with a media source such as a
- * {@link MediaCodec}.</p>
+ * {@link MediaCodec} or a
+ * {@link android.hardware.camera2.CameraDevice CameraDevice}.</p>
*
* <p>This class allows for efficient direct application access to the pixel
* data of the Image through one or more
@@ -82,6 +83,15 @@ public abstract class Image implements AutoCloseable {
* plane (4:2:0 subsampling). Each pixel sample in each plane has 8 bits.
* Each plane has its own row stride and pixel stride.</td>
* </tr>
+ * <tr>
+ * <td>{@link android.graphics.ImageFormat#RAW_SENSOR RAW_SENSOR}</td>
+ * <td>1</td>
+ * <td>A single plane of raw sensor image data, with 16 bits per color
+ * sample. The details of the layout need to be queried from the source of
+ * the raw sensor data, such as
+ * {@link android.hardware.camera2.CameraDevice CameraDevice}.
+ * </td>
+ * </tr>
* </table>
*
* @see android.graphics.ImageFormat
diff --git a/media/java/android/media/ImageReader.java b/media/java/android/media/ImageReader.java
index d454c42..1bd32c4 100644
--- a/media/java/android/media/ImageReader.java
+++ b/media/java/android/media/ImageReader.java
@@ -32,7 +32,8 @@ import java.nio.ByteOrder;
* rendered into a {@link android.view.Surface}</p>
*
* <p>Several Android media API classes accept Surface objects as targets to
- * render to, including {@link MediaPlayer}, {@link MediaCodec}, and
+ * render to, including {@link MediaPlayer}, {@link MediaCodec},
+ * {@link android.hardware.camera2.CameraDevice}, and
* {@link android.renderscript.Allocation RenderScript Allocations}. The image
* sizes and formats that can be used with each source vary, and should be
* checked in the documentation for the specific API.</p>
diff --git a/media/java/android/media/MediaDrm.java b/media/java/android/media/MediaDrm.java
index f5a703b..7170ffb 100644
--- a/media/java/android/media/MediaDrm.java
+++ b/media/java/android/media/MediaDrm.java
@@ -16,7 +16,6 @@
package android.media;
-import android.media.MediaDrmException;
import java.lang.ref.WeakReference;
import java.util.UUID;
import java.util.HashMap;
@@ -24,7 +23,6 @@ import java.util.List;
import android.os.Handler;
import android.os.Looper;
import android.os.Message;
-import android.os.Bundle;
import android.os.Parcel;
import android.util.Log;
diff --git a/media/java/android/media/MediaFile.java b/media/java/android/media/MediaFile.java
index 761ecca..526656a 100644
--- a/media/java/android/media/MediaFile.java
+++ b/media/java/android/media/MediaFile.java
@@ -16,17 +16,12 @@
package android.media;
-import android.content.ContentValues;
-import android.provider.MediaStore.Audio;
-import android.provider.MediaStore.Images;
-import android.provider.MediaStore.Video;
import android.media.DecoderCapabilities;
import android.media.DecoderCapabilities.VideoDecoder;
import android.media.DecoderCapabilities.AudioDecoder;
import android.mtp.MtpConstants;
import java.util.HashMap;
-import java.util.Iterator;
import java.util.List;
import java.util.Locale;
diff --git a/media/java/android/media/MediaFocusControl.java b/media/java/android/media/MediaFocusControl.java
index 34008bb..25ab99d 100644
--- a/media/java/android/media/MediaFocusControl.java
+++ b/media/java/android/media/MediaFocusControl.java
@@ -51,7 +51,6 @@ import android.util.Log;
import android.util.Slog;
import android.view.KeyEvent;
-import java.io.FileDescriptor;
import java.io.PrintWriter;
import java.util.ArrayList;
import java.util.Iterator;
diff --git a/media/java/android/media/MediaMetadataEditor.java b/media/java/android/media/MediaMetadataEditor.java
index 373ba11..3bfdb5a 100644
--- a/media/java/android/media/MediaMetadataEditor.java
+++ b/media/java/android/media/MediaMetadataEditor.java
@@ -18,7 +18,6 @@ package android.media;
import android.graphics.Bitmap;
import android.os.Bundle;
-import android.os.Parcel;
import android.os.Parcelable;
import android.util.Log;
import android.util.SparseIntArray;
diff --git a/media/java/android/media/MediaPlayer.java b/media/java/android/media/MediaPlayer.java
index 706258a..0e6e8b1 100644
--- a/media/java/android/media/MediaPlayer.java
+++ b/media/java/android/media/MediaPlayer.java
@@ -31,18 +31,15 @@ import android.os.Looper;
import android.os.Message;
import android.os.Parcel;
import android.os.Parcelable;
-import android.os.ParcelFileDescriptor;
import android.os.Process;
import android.os.PowerManager;
import android.util.Log;
import android.view.Surface;
import android.view.SurfaceHolder;
-import android.graphics.Bitmap;
import android.graphics.SurfaceTexture;
import android.media.AudioManager;
import android.media.MediaFormat;
import android.media.MediaTimeProvider;
-import android.media.MediaTimeProvider.OnMediaTimeListener;
import android.media.SubtitleController;
import android.media.SubtitleData;
diff --git a/media/java/android/media/MediaRecorder.java b/media/java/android/media/MediaRecorder.java
index 8dcbd6b..7b7c06c 100644
--- a/media/java/android/media/MediaRecorder.java
+++ b/media/java/android/media/MediaRecorder.java
@@ -124,6 +124,18 @@ public class MediaRecorder
public native void setCamera(Camera c);
/**
+ * Gets the surface to record from when using SURFACE video source.
+ * <p>
+ * Should only be called after prepare(). Frames rendered before start()
+ * will be discarded.
+ * </p>
+ * @throws IllegalStateException if it is called before prepare(), after
+ * stop() or is called when VideoSource is not set to SURFACE.
+ * @see android.media.MediaRecorder.VideoSource
+ */
+ public native Surface getSurface();
+
+ /**
* Sets a Surface to show a preview of recorded media (video). Calls this
* before prepare() to make sure that the desirable preview display is
* set. If {@link #setCamera(Camera)} is used and the surface has been
@@ -225,10 +237,23 @@ public class MediaRecorder
*/
private VideoSource() {}
public static final int DEFAULT = 0;
- /** Camera video source */
+ /** Camera video source
+ * <p>
+ * Using android.hardware.Camera as video source.
+ * </p>
+ */
public static final int CAMERA = 1;
- /** @hide */
- public static final int GRALLOC_BUFFER = 2;
+ /** Surface video source
+ * <p>
+ * Using a Surface as video source.
+ * </p><p>
+ * This flag must be used when recording from an
+ * android.hardware.camera2.CameraDevice source.
+ * </p><p>
+ * When using this video source type, use {@link MediaRecorder#getSurface()}
+ * to retrieve the surface created by MediaRecorder.
+ */
+ public static final int SURFACE = 2;
}
/**
diff --git a/media/java/android/media/Metadata.java b/media/java/android/media/Metadata.java
index b566653..eb543b4 100644
--- a/media/java/android/media/Metadata.java
+++ b/media/java/android/media/Metadata.java
@@ -16,7 +16,6 @@
package android.media;
-import android.graphics.Bitmap;
import android.os.Parcel;
import android.util.Log;
diff --git a/media/java/android/media/MiniThumbFile.java b/media/java/android/media/MiniThumbFile.java
index 63b149c..23c3652 100644
--- a/media/java/android/media/MiniThumbFile.java
+++ b/media/java/android/media/MiniThumbFile.java
@@ -16,7 +16,6 @@
package android.media;
-import android.graphics.Bitmap;
import android.net.Uri;
import android.os.Environment;
import android.util.Log;
diff --git a/media/java/android/media/Rating.java b/media/java/android/media/Rating.java
index 82c0392..b94db18 100644
--- a/media/java/android/media/Rating.java
+++ b/media/java/android/media/Rating.java
@@ -16,7 +16,6 @@
package android.media;
-import android.graphics.Bitmap;
import android.os.Parcel;
import android.os.Parcelable;
import android.util.Log;
diff --git a/media/java/android/media/RemoteControlClient.java b/media/java/android/media/RemoteControlClient.java
index 0c00aba..c2c61d3 100644
--- a/media/java/android/media/RemoteControlClient.java
+++ b/media/java/android/media/RemoteControlClient.java
@@ -24,13 +24,11 @@ import android.graphics.Bitmap;
import android.graphics.Canvas;
import android.graphics.Paint;
import android.graphics.RectF;
-import android.media.MediaMetadataRetriever;
import android.os.Bundle;
import android.os.Handler;
import android.os.IBinder;
import android.os.Looper;
import android.os.Message;
-import android.os.Parcelable;
import android.os.RemoteException;
import android.os.ServiceManager;
import android.os.SystemClock;
diff --git a/media/java/android/media/RemoteController.java b/media/java/android/media/RemoteController.java
index 6dbb3cd..cd3ce1f 100644
--- a/media/java/android/media/RemoteController.java
+++ b/media/java/android/media/RemoteController.java
@@ -16,7 +16,6 @@
package android.media;
-import android.Manifest;
import android.app.ActivityManager;
import android.app.PendingIntent;
import android.app.PendingIntent.CanceledException;
@@ -29,8 +28,6 @@ import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import android.os.Message;
-import android.os.RemoteException;
-import android.os.ServiceManager;
import android.os.SystemClock;
import android.util.DisplayMetrics;
import android.util.Log;
@@ -404,7 +401,7 @@ public final class RemoteController
* @throws IllegalArgumentException
*/
public boolean setSynchronizationMode(int sync) throws IllegalArgumentException {
- if ((sync != POSITION_SYNCHRONIZATION_NONE) || (sync != POSITION_SYNCHRONIZATION_CHECK)) {
+ if ((sync != POSITION_SYNCHRONIZATION_NONE) && (sync != POSITION_SYNCHRONIZATION_CHECK)) {
throw new IllegalArgumentException("Unknown synchronization mode " + sync);
}
if (!mIsRegistered) {
diff --git a/media/java/android/media/ResampleInputStream.java b/media/java/android/media/ResampleInputStream.java
index b025e25..80919f7 100644
--- a/media/java/android/media/ResampleInputStream.java
+++ b/media/java/android/media/ResampleInputStream.java
@@ -16,8 +16,6 @@
package android.media;
-import android.util.Log;
-
import java.io.InputStream;
import java.io.IOException;
diff --git a/media/java/android/media/RingtoneManager.java b/media/java/android/media/RingtoneManager.java
index 8e4004b..e211b99 100644
--- a/media/java/android/media/RingtoneManager.java
+++ b/media/java/android/media/RingtoneManager.java
@@ -23,7 +23,6 @@ import android.annotation.SdkConstant.SdkConstantType;
import android.app.Activity;
import android.content.ContentUris;
import android.content.Context;
-import android.content.res.AssetFileDescriptor;
import android.database.Cursor;
import android.net.Uri;
import android.os.Environment;
diff --git a/media/java/android/media/SoundPool.java b/media/java/android/media/SoundPool.java
index 06af5de..b0c077b 100644
--- a/media/java/android/media/SoundPool.java
+++ b/media/java/android/media/SoundPool.java
@@ -18,7 +18,6 @@ package android.media;
import java.io.File;
import java.io.FileDescriptor;
-import java.io.IOException;
import java.lang.ref.WeakReference;
import android.content.Context;
diff --git a/media/java/android/media/SubtitleData.java b/media/java/android/media/SubtitleData.java
index f552e82..3e6f6f9 100644
--- a/media/java/android/media/SubtitleData.java
+++ b/media/java/android/media/SubtitleData.java
@@ -17,7 +17,6 @@
package android.media;
import android.os.Parcel;
-import android.util.Log;
/**
* @hide
diff --git a/media/java/android/media/ThumbnailUtils.java b/media/java/android/media/ThumbnailUtils.java
index 756638c..daa5fa5 100644
--- a/media/java/android/media/ThumbnailUtils.java
+++ b/media/java/android/media/ThumbnailUtils.java
@@ -17,9 +17,6 @@
package android.media;
import android.content.ContentResolver;
-import android.content.ContentUris;
-import android.content.ContentValues;
-import android.database.Cursor;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.graphics.Canvas;
@@ -29,15 +26,12 @@ import android.media.MediaMetadataRetriever;
import android.media.MediaFile.MediaFileType;
import android.net.Uri;
import android.os.ParcelFileDescriptor;
-import android.provider.BaseColumns;
import android.provider.MediaStore.Images;
-import android.provider.MediaStore.Images.Thumbnails;
import android.util.Log;
import java.io.FileInputStream;
import java.io.FileDescriptor;
import java.io.IOException;
-import java.io.OutputStream;
/**
* Thumbnail generation routines for media provider.
diff --git a/media/java/android/media/WebVttRenderer.java b/media/java/android/media/WebVttRenderer.java
index 4dec081..58d3520 100644
--- a/media/java/android/media/WebVttRenderer.java
+++ b/media/java/android/media/WebVttRenderer.java
@@ -1136,11 +1136,15 @@ class WebVttRenderingWidget extends ViewGroup implements SubtitleTrack.Rendering
}
public WebVttRenderingWidget(Context context, AttributeSet attrs) {
- this(context, null, 0);
+ this(context, attrs, 0);
}
- public WebVttRenderingWidget(Context context, AttributeSet attrs, int defStyle) {
- super(context, attrs, defStyle);
+ public WebVttRenderingWidget(Context context, AttributeSet attrs, int defStyleAttr) {
+ this(context, attrs, defStyleAttr, 0);
+ }
+
+ public WebVttRenderingWidget(Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes) {
+ super(context, attrs, defStyleAttr, defStyleRes);
// Cannot render text over video when layer type is hardware.
setLayerType(View.LAYER_TYPE_SOFTWARE, null);
@@ -1521,6 +1525,8 @@ class WebVttRenderingWidget extends ViewGroup implements SubtitleTrack.Rendering
if (DEBUG) {
setBackgroundColor(DEBUG_REGION_BACKGROUND);
+ } else {
+ setBackgroundColor(captionStyle.windowColor);
}
}
@@ -1533,6 +1539,8 @@ class WebVttRenderingWidget extends ViewGroup implements SubtitleTrack.Rendering
final CueLayout cueBox = mRegionCueBoxes.get(i);
cueBox.setCaptionStyle(captionStyle, fontSize);
}
+
+ setBackgroundColor(captionStyle.windowColor);
}
/**
diff --git a/media/java/android/media/audiofx/AudioEffect.java b/media/java/android/media/audiofx/AudioEffect.java
index cc121a3..9b381cc 100644
--- a/media/java/android/media/audiofx/AudioEffect.java
+++ b/media/java/android/media/audiofx/AudioEffect.java
@@ -22,7 +22,6 @@ import android.os.Handler;
import android.os.Looper;
import android.os.Message;
import android.util.Log;
-import java.io.IOException;
import java.lang.ref.WeakReference;
import java.nio.ByteOrder;
import java.nio.ByteBuffer;
diff --git a/media/java/android/media/audiofx/BassBoost.java b/media/java/android/media/audiofx/BassBoost.java
index 91459ed..a46cc22 100644
--- a/media/java/android/media/audiofx/BassBoost.java
+++ b/media/java/android/media/audiofx/BassBoost.java
@@ -16,16 +16,9 @@
package android.media.audiofx;
-import android.app.Activity;
-import android.content.Context;
-import android.content.Intent;
import android.media.audiofx.AudioEffect;
-import android.os.Bundle;
import android.util.Log;
-import java.nio.ByteOrder;
-import java.nio.ByteBuffer;
-import java.nio.CharBuffer;
import java.util.StringTokenizer;
diff --git a/media/java/android/media/audiofx/EnvironmentalReverb.java b/media/java/android/media/audiofx/EnvironmentalReverb.java
index f1f582e..ef1c4c3 100644
--- a/media/java/android/media/audiofx/EnvironmentalReverb.java
+++ b/media/java/android/media/audiofx/EnvironmentalReverb.java
@@ -16,15 +16,7 @@
package android.media.audiofx;
-import android.app.Activity;
-import android.content.Context;
-import android.content.Intent;
import android.media.audiofx.AudioEffect;
-import android.os.Bundle;
-import android.util.Log;
-
-import java.nio.ByteOrder;
-import java.nio.ByteBuffer;
import java.util.StringTokenizer;
/**
diff --git a/media/java/android/media/audiofx/Equalizer.java b/media/java/android/media/audiofx/Equalizer.java
index 7f38955..7abada0 100644
--- a/media/java/android/media/audiofx/Equalizer.java
+++ b/media/java/android/media/audiofx/Equalizer.java
@@ -16,16 +16,9 @@
package android.media.audiofx;
-import android.app.Activity;
-import android.content.Context;
-import android.content.Intent;
import android.media.audiofx.AudioEffect;
-import android.os.Bundle;
import android.util.Log;
-import java.nio.ByteOrder;
-import java.nio.ByteBuffer;
-import java.nio.CharBuffer;
import java.util.StringTokenizer;
diff --git a/media/java/android/media/audiofx/PresetReverb.java b/media/java/android/media/audiofx/PresetReverb.java
index 7a89ae7..ef91667 100644
--- a/media/java/android/media/audiofx/PresetReverb.java
+++ b/media/java/android/media/audiofx/PresetReverb.java
@@ -16,15 +16,7 @@
package android.media.audiofx;
-import android.app.Activity;
-import android.content.Context;
-import android.content.Intent;
import android.media.audiofx.AudioEffect;
-import android.os.Bundle;
-import android.util.Log;
-
-import java.nio.ByteOrder;
-import java.nio.ByteBuffer;
import java.util.StringTokenizer;
diff --git a/media/java/android/media/audiofx/Virtualizer.java b/media/java/android/media/audiofx/Virtualizer.java
index 68a7b88..6b20006 100644
--- a/media/java/android/media/audiofx/Virtualizer.java
+++ b/media/java/android/media/audiofx/Virtualizer.java
@@ -16,16 +16,9 @@
package android.media.audiofx;
-import android.app.Activity;
-import android.content.Context;
-import android.content.Intent;
import android.media.audiofx.AudioEffect;
-import android.os.Bundle;
import android.util.Log;
-import java.nio.ByteOrder;
-import java.nio.ByteBuffer;
-import java.nio.CharBuffer;
import java.util.StringTokenizer;
diff --git a/media/java/android/media/audiofx/Visualizer.java b/media/java/android/media/audiofx/Visualizer.java
index ff04201..24c74ac 100644
--- a/media/java/android/media/audiofx/Visualizer.java
+++ b/media/java/android/media/audiofx/Visualizer.java
@@ -18,7 +18,6 @@ package android.media.audiofx;
import android.util.Log;
import java.lang.ref.WeakReference;
-import java.io.IOException;
import android.os.Handler;
import android.os.Looper;
import android.os.Message;
diff --git a/media/java/android/media/videoeditor/MediaArtistNativeHelper.java b/media/java/android/media/videoeditor/MediaArtistNativeHelper.java
index 2b0b3e2..2d3de85 100644
--- a/media/java/android/media/videoeditor/MediaArtistNativeHelper.java
+++ b/media/java/android/media/videoeditor/MediaArtistNativeHelper.java
@@ -28,7 +28,6 @@ import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.graphics.Canvas;
import android.graphics.Paint;
-import android.graphics.Rect;
import android.graphics.Matrix;
import android.media.videoeditor.VideoEditor.ExportProgressListener;
import android.media.videoeditor.VideoEditor.PreviewProgressListener;
diff --git a/media/java/android/mtp/MtpDatabase.java b/media/java/android/mtp/MtpDatabase.java
index 9ceefc3..cc464db 100755
--- a/media/java/android/mtp/MtpDatabase.java
+++ b/media/java/android/mtp/MtpDatabase.java
@@ -25,12 +25,10 @@ import android.database.Cursor;
import android.database.sqlite.SQLiteDatabase;
import android.media.MediaScanner;
import android.net.Uri;
-import android.os.Environment;
import android.os.RemoteException;
import android.provider.MediaStore;
import android.provider.MediaStore.Audio;
import android.provider.MediaStore.Files;
-import android.provider.MediaStore.Images;
import android.provider.MediaStore.MediaColumns;
import android.util.Log;
import android.view.Display;
diff --git a/media/java/android/mtp/MtpDevice.java b/media/java/android/mtp/MtpDevice.java
index 8310579..72dcaa8 100644
--- a/media/java/android/mtp/MtpDevice.java
+++ b/media/java/android/mtp/MtpDevice.java
@@ -18,8 +18,6 @@ package android.mtp;
import android.hardware.usb.UsbDevice;
import android.hardware.usb.UsbDeviceConnection;
-import android.os.ParcelFileDescriptor;
-import android.util.Log;
/**
* This class represents an MTP or PTP device connected on the USB host bus. An application can
diff --git a/media/java/android/mtp/MtpPropertyGroup.java b/media/java/android/mtp/MtpPropertyGroup.java
index 48da40f..781988d 100644
--- a/media/java/android/mtp/MtpPropertyGroup.java
+++ b/media/java/android/mtp/MtpPropertyGroup.java
@@ -20,7 +20,6 @@ import android.content.IContentProvider;
import android.database.Cursor;
import android.net.Uri;
import android.os.RemoteException;
-import android.provider.MediaStore;
import android.provider.MediaStore.Audio;
import android.provider.MediaStore.Files;
import android.provider.MediaStore.Images;
diff --git a/media/jni/Android.mk b/media/jni/Android.mk
index 63a61e2..dea971e 100644
--- a/media/jni/Android.mk
+++ b/media/jni/Android.mk
@@ -41,13 +41,13 @@ LOCAL_SHARED_LIBRARIES := \
libstagefright_amrnb_common \
LOCAL_REQUIRED_MODULES := \
- libexif_jni
+ libjhead_jni
LOCAL_STATIC_LIBRARIES := \
libstagefright_amrnbenc
LOCAL_C_INCLUDES += \
- external/jhead \
+ external/libexif/ \
external/tremor/Tremor \
frameworks/base/core/jni \
frameworks/av/media/libmedia \
diff --git a/media/jni/android_media_MediaRecorder.cpp b/media/jni/android_media_MediaRecorder.cpp
index 9888591..ac863e1 100644
--- a/media/jni/android_media_MediaRecorder.cpp
+++ b/media/jni/android_media_MediaRecorder.cpp
@@ -344,6 +344,26 @@ android_media_MediaRecorder_native_getMaxAmplitude(JNIEnv *env, jobject thiz)
return result;
}
+static jobject
+android_media_MediaRecorder_getSurface(JNIEnv *env, jobject thiz)
+{
+ ALOGV("getSurface");
+ sp<MediaRecorder> mr = getMediaRecorder(env, thiz);
+
+ sp<IGraphicBufferProducer> bufferProducer = mr->querySurfaceMediaSourceFromMediaServer();
+ if (bufferProducer == NULL) {
+ jniThrowException(
+ env,
+ "java/lang/IllegalStateException",
+ "failed to get surface");
+ return NULL;
+ }
+
+ // Wrap the IGBP in a Java-language Surface.
+ return android_view_Surface_createFromIGraphicBufferProducer(env,
+ bufferProducer);
+}
+
static void
android_media_MediaRecorder_start(JNIEnv *env, jobject thiz)
{
@@ -470,6 +490,7 @@ static JNINativeMethod gMethods[] = {
{"setMaxDuration", "(I)V", (void *)android_media_MediaRecorder_setMaxDuration},
{"setMaxFileSize", "(J)V", (void *)android_media_MediaRecorder_setMaxFileSize},
{"_prepare", "()V", (void *)android_media_MediaRecorder_prepare},
+ {"getSurface", "()Landroid/view/Surface;", (void *)android_media_MediaRecorder_getSurface},
{"getMaxAmplitude", "()I", (void *)android_media_MediaRecorder_native_getMaxAmplitude},
{"start", "()V", (void *)android_media_MediaRecorder_start},
{"stop", "()V", (void *)android_media_MediaRecorder_stop},
diff --git a/media/jni/android_mtp_MtpDatabase.cpp b/media/jni/android_mtp_MtpDatabase.cpp
index 72ce3cc..4fbc55a 100644
--- a/media/jni/android_mtp_MtpDatabase.cpp
+++ b/media/jni/android_mtp_MtpDatabase.cpp
@@ -37,7 +37,10 @@
#include "mtp.h"
extern "C" {
-#include "jhead.h"
+#include "libexif/exif-content.h"
+#include "libexif/exif-data.h"
+#include "libexif/exif-tag.h"
+#include "libexif/exif-utils.h"
}
using namespace android;
@@ -750,6 +753,22 @@ MtpResponseCode MyMtpDatabase::getObjectPropertyList(MtpObjectHandle handle,
return result;
}
+static void foreachentry(ExifEntry *entry, void *user) {
+ char buf[1024];
+ ALOGI("entry %x, format %d, size %d: %s",
+ entry->tag, entry->format, entry->size, exif_entry_get_value(entry, buf, sizeof(buf)));
+}
+
+static void foreachcontent(ExifContent *content, void *user) {
+ ALOGI("content %d", exif_content_get_ifd(content));
+ exif_content_foreach_entry(content, foreachentry, user);
+}
+
+static long getLongFromExifEntry(ExifEntry *e) {
+ ExifByteOrder o = exif_data_get_byte_order(e->parent->parent);
+ return exif_get_long(e->data, o);
+}
+
MtpResponseCode MyMtpDatabase::getObjectInfo(MtpObjectHandle handle,
MtpObjectInfo& info) {
char date[20];
@@ -792,23 +811,22 @@ MtpResponseCode MyMtpDatabase::getObjectInfo(MtpObjectHandle handle,
// read EXIF data for thumbnail information
if (info.mFormat == MTP_FORMAT_EXIF_JPEG || info.mFormat == MTP_FORMAT_JFIF) {
- ResetJpgfile();
- // Start with an empty image information structure.
- memset(&ImageInfo, 0, sizeof(ImageInfo));
- ImageInfo.FlashUsed = -1;
- ImageInfo.MeteringMode = -1;
- ImageInfo.Whitebalance = -1;
- strncpy(ImageInfo.FileName, (const char *)path, PATH_MAX);
- if (ReadJpegFile((const char*)path, READ_METADATA)) {
- Section_t* section = FindSection(M_EXIF);
- if (section) {
- info.mThumbCompressedSize = ImageInfo.ThumbnailSize;
- info.mThumbFormat = MTP_FORMAT_EXIF_JPEG;
- info.mImagePixWidth = ImageInfo.Width;
- info.mImagePixHeight = ImageInfo.Height;
- }
+
+ ExifData *exifdata = exif_data_new_from_file(path);
+ if (exifdata) {
+ //exif_data_foreach_content(exifdata, foreachcontent, NULL);
+
+ // XXX get this from exif, or parse jpeg header instead?
+ ExifEntry *w = exif_content_get_entry(
+ exifdata->ifd[EXIF_IFD_EXIF], EXIF_TAG_PIXEL_X_DIMENSION);
+ ExifEntry *h = exif_content_get_entry(
+ exifdata->ifd[EXIF_IFD_EXIF], EXIF_TAG_PIXEL_Y_DIMENSION);
+ info.mThumbCompressedSize = exifdata->data ? exifdata->size : 0;
+ info.mThumbFormat = MTP_FORMAT_EXIF_JPEG;
+ info.mImagePixWidth = getLongFromExifEntry(w);
+ info.mImagePixHeight = getLongFromExifEntry(h);
+ exif_data_unref(exifdata);
}
- DiscardData();
}
checkAndClearExceptionFromCallback(env, __FUNCTION__);
@@ -824,22 +842,16 @@ void* MyMtpDatabase::getThumbnail(MtpObjectHandle handle, size_t& outThumbSize)
if (getObjectFilePath(handle, path, length, format) == MTP_RESPONSE_OK
&& (format == MTP_FORMAT_EXIF_JPEG || format == MTP_FORMAT_JFIF)) {
- ResetJpgfile();
- // Start with an empty image information structure.
- memset(&ImageInfo, 0, sizeof(ImageInfo));
- ImageInfo.FlashUsed = -1;
- ImageInfo.MeteringMode = -1;
- ImageInfo.Whitebalance = -1;
- strncpy(ImageInfo.FileName, (const char *)path, PATH_MAX);
- if (ReadJpegFile((const char*)path, READ_METADATA)) {
- Section_t* section = FindSection(M_EXIF);
- if (section) {
- outThumbSize = ImageInfo.ThumbnailSize;
- result = malloc(outThumbSize);
- if (result)
- memcpy(result, section->Data + ImageInfo.ThumbnailOffset + 8, outThumbSize);
+
+ ExifData *exifdata = exif_data_new_from_file(path);
+ if (exifdata) {
+ if (exifdata->data) {
+ result = malloc(exifdata->size);
+ if (result) {
+ memcpy(result, exifdata->data, exifdata->size);
+ }
}
- DiscardData();
+ exif_data_unref(exifdata);
}
}
diff --git a/media/lib/java/com/android/media/remotedisplay/RemoteDisplay.java b/media/lib/java/com/android/media/remotedisplay/RemoteDisplay.java
index 6cfc0e8..dc9dd79 100644
--- a/media/lib/java/com/android/media/remotedisplay/RemoteDisplay.java
+++ b/media/lib/java/com/android/media/remotedisplay/RemoteDisplay.java
@@ -16,7 +16,6 @@
package com.android.media.remotedisplay;
-import android.media.MediaRouter;
import android.media.RemoteDisplayState.RemoteDisplayInfo;
import android.text.TextUtils;
diff --git a/media/mca/effect/java/android/media/effect/EffectContext.java b/media/mca/effect/java/android/media/effect/EffectContext.java
index ef03229..a11b9c4 100644
--- a/media/mca/effect/java/android/media/effect/EffectContext.java
+++ b/media/mca/effect/java/android/media/effect/EffectContext.java
@@ -19,10 +19,7 @@ package android.media.effect;
import android.filterfw.core.CachedFrameManager;
import android.filterfw.core.FilterContext;
-import android.filterfw.core.FilterFactory;
import android.filterfw.core.GLEnvironment;
-import android.filterfw.core.GLFrame;
-import android.filterfw.core.FrameManager;
import android.opengl.GLES20;
/**
diff --git a/media/mca/effect/java/android/media/effect/EffectFactory.java b/media/mca/effect/java/android/media/effect/EffectFactory.java
index 4330279..f6fcba7 100644
--- a/media/mca/effect/java/android/media/effect/EffectFactory.java
+++ b/media/mca/effect/java/android/media/effect/EffectFactory.java
@@ -18,7 +18,6 @@
package android.media.effect;
import java.lang.reflect.Constructor;
-import java.util.HashMap;
/**
* <p>The EffectFactory class defines the list of available Effects, and provides functionality to
diff --git a/media/mca/effect/java/android/media/effect/FilterEffect.java b/media/mca/effect/java/android/media/effect/FilterEffect.java
index d7c319e..34b3549 100644
--- a/media/mca/effect/java/android/media/effect/FilterEffect.java
+++ b/media/mca/effect/java/android/media/effect/FilterEffect.java
@@ -17,10 +17,7 @@
package android.media.effect;
-import android.filterfw.core.CachedFrameManager;
import android.filterfw.core.FilterContext;
-import android.filterfw.core.FilterFactory;
-import android.filterfw.core.GLEnvironment;
import android.filterfw.core.GLFrame;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
diff --git a/media/mca/effect/java/android/media/effect/FilterGraphEffect.java b/media/mca/effect/java/android/media/effect/FilterGraphEffect.java
index b18bea8..80c695b 100644
--- a/media/mca/effect/java/android/media/effect/FilterGraphEffect.java
+++ b/media/mca/effect/java/android/media/effect/FilterGraphEffect.java
@@ -19,17 +19,13 @@ package android.media.effect;
import android.filterfw.core.Filter;
import android.filterfw.core.FilterGraph;
import android.filterfw.core.GraphRunner;
-import android.filterfw.core.SimpleScheduler;
import android.filterfw.core.SyncRunner;
-import android.media.effect.Effect;
import android.media.effect.FilterEffect;
import android.media.effect.EffectContext;
import android.filterfw.io.GraphIOException;
import android.filterfw.io.GraphReader;
import android.filterfw.io.TextGraphReader;
-import android.util.Log;
-
/**
* Effect subclass for effects based on a single Filter. Subclasses need only invoke the
* constructor with the correct arguments to obtain an Effect implementation.
diff --git a/media/mca/effect/java/android/media/effect/SingleFilterEffect.java b/media/mca/effect/java/android/media/effect/SingleFilterEffect.java
index 6f85861..47900df 100644
--- a/media/mca/effect/java/android/media/effect/SingleFilterEffect.java
+++ b/media/mca/effect/java/android/media/effect/SingleFilterEffect.java
@@ -21,11 +21,8 @@ import android.filterfw.core.Filter;
import android.filterfw.core.FilterFactory;
import android.filterfw.core.FilterFunction;
import android.filterfw.core.Frame;
-import android.media.effect.Effect;
import android.media.effect.EffectContext;
-import android.util.Log;
-
/**
* Effect subclass for effects based on a single Filter. Subclasses need only invoke the
* constructor with the correct arguments to obtain an Effect implementation.
diff --git a/media/mca/effect/java/android/media/effect/SizeChangeEffect.java b/media/mca/effect/java/android/media/effect/SizeChangeEffect.java
index 4d27bae..1bf7d40 100644
--- a/media/mca/effect/java/android/media/effect/SizeChangeEffect.java
+++ b/media/mca/effect/java/android/media/effect/SizeChangeEffect.java
@@ -16,15 +16,9 @@
package android.media.effect;
-import android.filterfw.core.Filter;
-import android.filterfw.core.FilterFactory;
-import android.filterfw.core.FilterFunction;
import android.filterfw.core.Frame;
-import android.media.effect.Effect;
import android.media.effect.EffectContext;
-import android.util.Log;
-
/**
* Effect subclass for effects based on a single Filter with output size differnet
* from input. Subclasses need only invoke the constructor with the correct arguments
diff --git a/media/mca/effect/java/android/media/effect/effects/CropEffect.java b/media/mca/effect/java/android/media/effect/effects/CropEffect.java
index 3e8d78a..7e1c495 100644
--- a/media/mca/effect/java/android/media/effect/effects/CropEffect.java
+++ b/media/mca/effect/java/android/media/effect/effects/CropEffect.java
@@ -19,7 +19,6 @@ package android.media.effect.effects;
import android.media.effect.EffectContext;
import android.media.effect.SizeChangeEffect;
-import android.media.effect.SingleFilterEffect;
import android.filterpacks.imageproc.CropRectFilter;
/**
diff --git a/media/mca/filterfw/java/android/filterfw/FilterFunctionEnvironment.java b/media/mca/filterfw/java/android/filterfw/FilterFunctionEnvironment.java
index 3f36d98..feaf6e8 100644
--- a/media/mca/filterfw/java/android/filterfw/FilterFunctionEnvironment.java
+++ b/media/mca/filterfw/java/android/filterfw/FilterFunctionEnvironment.java
@@ -20,7 +20,6 @@ package android.filterfw;
import android.filterfw.core.Filter;
import android.filterfw.core.FilterFactory;
import android.filterfw.core.FilterFunction;
-import android.filterfw.core.Frame;
import android.filterfw.core.FrameManager;
/**
diff --git a/media/mca/filterfw/java/android/filterfw/core/AsyncRunner.java b/media/mca/filterfw/java/android/filterfw/core/AsyncRunner.java
index 70cbad4..819774a 100644
--- a/media/mca/filterfw/java/android/filterfw/core/AsyncRunner.java
+++ b/media/mca/filterfw/java/android/filterfw/core/AsyncRunner.java
@@ -18,17 +18,9 @@
package android.filterfw.core;
import android.os.AsyncTask;
-import android.os.Handler;
import android.util.Log;
-import java.lang.InterruptedException;
-import java.lang.Runnable;
-import java.util.concurrent.CancellationException;
-import java.util.concurrent.ExecutionException;
-import java.util.concurrent.TimeoutException;
-import java.util.concurrent.TimeUnit;
-
/**
* @hide
*/
diff --git a/media/mca/filterfw/java/android/filterfw/core/Filter.java b/media/mca/filterfw/java/android/filterfw/core/Filter.java
index 73b009d..062b6ba 100644
--- a/media/mca/filterfw/java/android/filterfw/core/Filter.java
+++ b/media/mca/filterfw/java/android/filterfw/core/Filter.java
@@ -33,7 +33,6 @@ import java.util.Collection;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Map.Entry;
-import java.util.LinkedList;
import java.util.Set;
/**
diff --git a/media/mca/filterfw/java/android/filterfw/core/Frame.java b/media/mca/filterfw/java/android/filterfw/core/Frame.java
index ef8c542..7dd0783 100644
--- a/media/mca/filterfw/java/android/filterfw/core/Frame.java
+++ b/media/mca/filterfw/java/android/filterfw/core/Frame.java
@@ -20,7 +20,6 @@ package android.filterfw.core;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.FrameManager;
import android.graphics.Bitmap;
-import android.util.Log;
import java.nio.ByteBuffer;
diff --git a/media/mca/filterfw/java/android/filterfw/core/NativeFrame.java b/media/mca/filterfw/java/android/filterfw/core/NativeFrame.java
index bfd09ba..7d1553f 100644
--- a/media/mca/filterfw/java/android/filterfw/core/NativeFrame.java
+++ b/media/mca/filterfw/java/android/filterfw/core/NativeFrame.java
@@ -24,8 +24,6 @@ import android.filterfw.core.GLFrame;
import android.filterfw.core.NativeBuffer;
import android.graphics.Bitmap;
-import android.util.Log;
-
import java.nio.ByteBuffer;
/**
diff --git a/media/mca/filterfw/java/android/filterfw/core/OneShotScheduler.java b/media/mca/filterfw/java/android/filterfw/core/OneShotScheduler.java
index dbc8d16..83c475f 100644
--- a/media/mca/filterfw/java/android/filterfw/core/OneShotScheduler.java
+++ b/media/mca/filterfw/java/android/filterfw/core/OneShotScheduler.java
@@ -18,7 +18,6 @@
package android.filterfw.core;
import android.filterfw.core.Filter;
-import android.filterfw.core.Scheduler;
import android.filterfw.core.RoundRobinScheduler;
import android.util.Log;
diff --git a/media/mca/filterfw/java/android/filterfw/core/SerializedFrame.java b/media/mca/filterfw/java/android/filterfw/core/SerializedFrame.java
index f493fd2..35ba04f 100644
--- a/media/mca/filterfw/java/android/filterfw/core/SerializedFrame.java
+++ b/media/mca/filterfw/java/android/filterfw/core/SerializedFrame.java
@@ -20,7 +20,6 @@ package android.filterfw.core;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.FrameManager;
-import android.filterfw.core.NativeBuffer;
import android.filterfw.format.ObjectFormat;
import android.graphics.Bitmap;
@@ -28,10 +27,7 @@ import java.io.InputStream;
import java.io.IOException;
import java.io.ObjectInputStream;
import java.io.ObjectOutputStream;
-import java.io.OptionalDataException;
import java.io.OutputStream;
-import java.io.StreamCorruptedException;
-import java.lang.reflect.Constructor;
import java.nio.ByteBuffer;
/**
diff --git a/media/mca/filterfw/java/android/filterfw/core/SimpleFrame.java b/media/mca/filterfw/java/android/filterfw/core/SimpleFrame.java
index 534a30d..7ddd1d4 100644
--- a/media/mca/filterfw/java/android/filterfw/core/SimpleFrame.java
+++ b/media/mca/filterfw/java/android/filterfw/core/SimpleFrame.java
@@ -20,11 +20,9 @@ package android.filterfw.core;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.FrameManager;
-import android.filterfw.core.NativeBuffer;
import android.filterfw.format.ObjectFormat;
import android.graphics.Bitmap;
-import java.lang.reflect.Constructor;
import java.nio.ByteBuffer;
/**
diff --git a/media/mca/filterpacks/java/android/filterpacks/base/CallbackFilter.java b/media/mca/filterpacks/java/android/filterpacks/base/CallbackFilter.java
index 4185343..4a47fa4 100644
--- a/media/mca/filterpacks/java/android/filterpacks/base/CallbackFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/base/CallbackFilter.java
@@ -20,13 +20,8 @@ package android.filterpacks.base;
import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
-import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
import android.filterfw.core.GenerateFinalPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
-import android.filterfw.core.Program;
import android.os.Handler;
import android.os.Looper;
diff --git a/media/mca/filterpacks/java/android/filterpacks/base/FrameBranch.java b/media/mca/filterpacks/java/android/filterpacks/base/FrameBranch.java
index 6b8cbc7..f909c3f 100644
--- a/media/mca/filterpacks/java/android/filterpacks/base/FrameBranch.java
+++ b/media/mca/filterpacks/java/android/filterpacks/base/FrameBranch.java
@@ -22,7 +22,6 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFinalPort;
-import android.filterfw.core.KeyValueMap;
/**
* @hide
diff --git a/media/mca/filterpacks/java/android/filterpacks/base/FrameFetch.java b/media/mca/filterpacks/java/android/filterpacks/base/FrameFetch.java
index 518b837..87d8f0b 100644
--- a/media/mca/filterpacks/java/android/filterpacks/base/FrameFetch.java
+++ b/media/mca/filterpacks/java/android/filterpacks/base/FrameFetch.java
@@ -24,8 +24,6 @@ import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
import android.filterfw.core.GenerateFinalPort;
-import android.util.Log;
-
/**
* @hide
*/
diff --git a/media/mca/filterpacks/java/android/filterpacks/base/FrameStore.java b/media/mca/filterpacks/java/android/filterpacks/base/FrameStore.java
index 3aadaac..05ac50d 100644
--- a/media/mca/filterpacks/java/android/filterpacks/base/FrameStore.java
+++ b/media/mca/filterpacks/java/android/filterpacks/base/FrameStore.java
@@ -20,7 +20,6 @@ package android.filterpacks.base;
import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
-import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
/**
diff --git a/media/mca/filterpacks/java/android/filterpacks/base/GLTextureSource.java b/media/mca/filterpacks/java/android/filterpacks/base/GLTextureSource.java
index 1776820..af61d9a 100644
--- a/media/mca/filterpacks/java/android/filterpacks/base/GLTextureSource.java
+++ b/media/mca/filterpacks/java/android/filterpacks/base/GLTextureSource.java
@@ -23,11 +23,8 @@ import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
import android.filterfw.core.GLFrame;
-import android.filterfw.core.MutableFrameFormat;
import android.filterfw.format.ImageFormat;
-import java.util.Set;
-
/**
* @hide
*/
diff --git a/media/mca/filterpacks/java/android/filterpacks/base/GLTextureTarget.java b/media/mca/filterpacks/java/android/filterpacks/base/GLTextureTarget.java
index b2285cd..91bb417 100644
--- a/media/mca/filterpacks/java/android/filterpacks/base/GLTextureTarget.java
+++ b/media/mca/filterpacks/java/android/filterpacks/base/GLTextureTarget.java
@@ -23,11 +23,8 @@ import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
import android.filterfw.core.GLFrame;
-import android.filterfw.core.MutableFrameFormat;
import android.filterfw.format.ImageFormat;
-import java.util.Set;
-
/**
* @hide
*/
diff --git a/media/mca/filterpacks/java/android/filterpacks/base/InputStreamSource.java b/media/mca/filterpacks/java/android/filterpacks/base/InputStreamSource.java
index 6c22ee7..0ef9055 100644
--- a/media/mca/filterpacks/java/android/filterpacks/base/InputStreamSource.java
+++ b/media/mca/filterpacks/java/android/filterpacks/base/InputStreamSource.java
@@ -23,7 +23,6 @@ import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
import android.filterfw.core.GenerateFinalPort;
-import android.filterfw.core.KeyValueMap;
import android.filterfw.core.MutableFrameFormat;
import android.filterfw.format.PrimitiveFormat;
diff --git a/media/mca/filterpacks/java/android/filterpacks/base/NullFilter.java b/media/mca/filterpacks/java/android/filterpacks/base/NullFilter.java
index f3e08e4..73434d4 100644
--- a/media/mca/filterpacks/java/android/filterpacks/base/NullFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/base/NullFilter.java
@@ -19,8 +19,6 @@ package android.filterpacks.base;
import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
-import android.filterfw.core.Frame;
-import android.filterfw.core.FrameFormat;
/**
* @hide
diff --git a/media/mca/filterpacks/java/android/filterpacks/base/ObjectSource.java b/media/mca/filterpacks/java/android/filterpacks/base/ObjectSource.java
index d511e44..78e2b50 100644
--- a/media/mca/filterpacks/java/android/filterpacks/base/ObjectSource.java
+++ b/media/mca/filterpacks/java/android/filterpacks/base/ObjectSource.java
@@ -17,15 +17,12 @@
package android.filterpacks.base;
-import java.util.Set;
-
import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
import android.filterfw.core.GenerateFinalPort;
-import android.filterfw.core.MutableFrameFormat;
import android.filterfw.format.ObjectFormat;
/**
diff --git a/media/mca/filterpacks/java/android/filterpacks/base/OutputStreamTarget.java b/media/mca/filterpacks/java/android/filterpacks/base/OutputStreamTarget.java
index 3d3d0f1..fd65a9d 100644
--- a/media/mca/filterpacks/java/android/filterpacks/base/OutputStreamTarget.java
+++ b/media/mca/filterpacks/java/android/filterpacks/base/OutputStreamTarget.java
@@ -20,7 +20,6 @@ package android.filterpacks.base;
import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
-import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
import java.io.OutputStream;
diff --git a/media/mca/filterpacks/java/android/filterpacks/base/RetargetFilter.java b/media/mca/filterpacks/java/android/filterpacks/base/RetargetFilter.java
index 254167a..0e988820 100644
--- a/media/mca/filterpacks/java/android/filterpacks/base/RetargetFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/base/RetargetFilter.java
@@ -21,9 +21,7 @@ import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
-import android.filterfw.core.GenerateFieldPort;
import android.filterfw.core.GenerateFinalPort;
-import android.filterfw.core.KeyValueMap;
import android.filterfw.core.MutableFrameFormat;
/**
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/AlphaBlendFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/AlphaBlendFilter.java
index 473369c..c3cc282 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/AlphaBlendFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/AlphaBlendFilter.java
@@ -17,18 +17,9 @@
package android.filterpacks.imageproc;
-import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
-import android.filterfw.core.Frame;
-import android.filterfw.core.FrameFormat;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
-import android.filterfw.format.ImageFormat;
-
-import java.util.Set;
/**
* @hide
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/AutoFixFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/AutoFixFilter.java
index c71c1c9..ac83db2 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/AutoFixFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/AutoFixFilter.java
@@ -21,13 +21,10 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.NativeProgram;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
-import android.util.Log;
-
public class AutoFixFilter extends Filter {
@GenerateFieldPort(name = "tile_size", hasDefault = true)
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/BitmapOverlayFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/BitmapOverlayFilter.java
index e4bb6cf..92b177c 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/BitmapOverlayFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/BitmapOverlayFilter.java
@@ -21,17 +21,11 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
-import android.filterpacks.imageproc.ImageCombineFilter;
import android.graphics.Bitmap;
-import android.util.Log;
-
/**
* @hide
*/
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/BitmapSource.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/BitmapSource.java
index 978fc94..89e8723 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/BitmapSource.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/BitmapSource.java
@@ -17,17 +17,11 @@
package android.filterpacks.imageproc;
-import android.content.Context;
import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
-import android.filterfw.core.FrameManager;
-import android.filterfw.core.GenerateFinalPort;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.MutableFrameFormat;
-import android.filterfw.core.NativeFrame;
import android.filterfw.format.ImageFormat;
import android.graphics.Bitmap;
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/BlackWhiteFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/BlackWhiteFilter.java
index 20b02d2..38221b4 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/BlackWhiteFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/BlackWhiteFilter.java
@@ -21,9 +21,6 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/BlendFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/BlendFilter.java
index 29bc8a3..aff5e9e 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/BlendFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/BlendFilter.java
@@ -16,18 +16,9 @@
package android.filterpacks.imageproc;
-import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
-import android.filterfw.core.Frame;
-import android.filterfw.core.FrameFormat;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
-import android.filterfw.format.ImageFormat;
-
-import java.util.Set;
/**
* The filter linearly blends "left" and "right" frames. The blending weight is
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/BrightnessFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/BrightnessFilter.java
index 046e69d..bc62e19 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/BrightnessFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/BrightnessFilter.java
@@ -17,13 +17,8 @@
package android.filterpacks.imageproc;
-import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
-import android.filterfw.core.Frame;
-import android.filterfw.core.FrameFormat;
-import android.filterfw.core.KeyValueMap;
import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/ColorTemperatureFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/ColorTemperatureFilter.java
index 7488980..1d408be 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/ColorTemperatureFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/ColorTemperatureFilter.java
@@ -21,13 +21,9 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
-import android.util.Log;
public class ColorTemperatureFilter extends Filter {
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/ContrastFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/ContrastFilter.java
index 70e987f..7043c72 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/ContrastFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/ContrastFilter.java
@@ -17,18 +17,11 @@
package android.filterpacks.imageproc;
-import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
-import android.filterfw.core.Frame;
-import android.filterfw.core.FrameFormat;
-import android.filterfw.core.KeyValueMap;
import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
-import java.util.Set;
-
/**
* @hide
*/
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/CropFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/CropFilter.java
index 5222d9c..0ef323c 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/CropFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/CropFilter.java
@@ -22,19 +22,13 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
import android.filterfw.core.MutableFrameFormat;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
-import android.filterfw.geometry.Point;
import android.filterfw.geometry.Quad;
import android.filterfw.format.ImageFormat;
import android.filterfw.format.ObjectFormat;
-import android.util.Log;
-
/**
* @hide
*/
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/CropRectFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/CropRectFilter.java
index d423d06..010ee21 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/CropRectFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/CropRectFilter.java
@@ -21,14 +21,9 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.MutableFrameFormat;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
-import android.util.Log;
/**
* @hide
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/CrossProcessFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/CrossProcessFilter.java
index e0514f8..d565e65 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/CrossProcessFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/CrossProcessFilter.java
@@ -21,15 +21,10 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
-import android.util.Log;
-
public class CrossProcessFilter extends Filter {
@GenerateFieldPort(name = "tile_size", hasDefault = true)
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/DocumentaryFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/DocumentaryFilter.java
index f93a82c..72745c0 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/DocumentaryFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/DocumentaryFilter.java
@@ -21,9 +21,6 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/DrawOverlayFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/DrawOverlayFilter.java
index 3f1711e..d10a6ef 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/DrawOverlayFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/DrawOverlayFilter.java
@@ -21,17 +21,11 @@ import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
-import android.filterfw.core.GLFrame;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
-import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.geometry.Quad;
import android.filterfw.format.ImageFormat;
import android.filterfw.format.ObjectFormat;
-import android.opengl.GLES20;
-
/**
* @hide
*/
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/DrawRectFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/DrawRectFilter.java
index 83c9348..b288e6e 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/DrawRectFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/DrawRectFilter.java
@@ -23,9 +23,6 @@ import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
import android.filterfw.core.GLFrame;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
-import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.geometry.Quad;
import android.filterfw.format.ImageFormat;
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/DuotoneFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/DuotoneFilter.java
index d8c88ee..ef82ee9 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/DuotoneFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/DuotoneFilter.java
@@ -21,9 +21,6 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/FillLightFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/FillLightFilter.java
index fc917a1..c7fb55d 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/FillLightFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/FillLightFilter.java
@@ -21,10 +21,6 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.GenerateFinalPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/FisheyeFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/FisheyeFilter.java
index 5d7929f..2ff6588 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/FisheyeFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/FisheyeFilter.java
@@ -22,17 +22,11 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
-import android.util.Log;
-
import java.lang.Math;
-import java.util.Set;
/**
* @hide
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/FixedRotationFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/FixedRotationFilter.java
index 3d319ea..340f308 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/FixedRotationFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/FixedRotationFilter.java
@@ -22,7 +22,6 @@ import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
import android.filterfw.core.MutableFrameFormat;
-import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
import android.filterfw.geometry.Point;
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/FlipFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/FlipFilter.java
index f8b857b..68c760f 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/FlipFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/FlipFilter.java
@@ -21,10 +21,6 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.MutableFrameFormat;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/GrainFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/GrainFilter.java
index 577243a..528eaa2 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/GrainFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/GrainFilter.java
@@ -21,14 +21,9 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
-import android.filterfw.geometry.Quad;
-import android.filterfw.geometry.Point;
import java.util.Date;
import java.util.Random;
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/ImageCombineFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/ImageCombineFilter.java
index 858489b..c9a6956 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/ImageCombineFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/ImageCombineFilter.java
@@ -21,16 +21,10 @@ import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
-import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
import java.lang.reflect.Field;
-import java.util.HashSet;
-import java.util.Set;
/**
* @hide
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/ImageEncoder.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/ImageEncoder.java
index a5405cb..e8bf482 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/ImageEncoder.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/ImageEncoder.java
@@ -17,21 +17,16 @@
package android.filterpacks.imageproc;
-import android.content.Context;
import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
import android.filterfw.format.ImageFormat;
import android.graphics.Bitmap;
import android.graphics.Bitmap.CompressFormat;
-import android.util.Log;
-
import java.io.OutputStream;
-import java.io.IOException;
/**
* @hide
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/ImageSlicer.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/ImageSlicer.java
index b996eb8..8bf80b2 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/ImageSlicer.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/ImageSlicer.java
@@ -20,9 +20,7 @@ import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
-import android.filterfw.core.FrameManager;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
import android.filterfw.core.MutableFrameFormat;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/ImageStitcher.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/ImageStitcher.java
index 20aba91..5e3d15b 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/ImageStitcher.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/ImageStitcher.java
@@ -20,16 +20,12 @@ import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
-import android.filterfw.core.FrameManager;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
import android.filterfw.core.MutableFrameFormat;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
-import android.util.Log;
-
public class ImageStitcher extends Filter {
@GenerateFieldPort(name = "xSlices")
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/Invert.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/Invert.java
index 400fd5d..881e30f 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/Invert.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/Invert.java
@@ -17,12 +17,8 @@
package android.filterpacks.imageproc;
-import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
-import android.filterfw.core.Frame;
-import android.filterfw.core.FrameFormat;
import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/LomoishFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/LomoishFilter.java
index 726ffff..4e53f92 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/LomoishFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/LomoishFilter.java
@@ -21,9 +21,6 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/NegativeFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/NegativeFilter.java
index 440d6a6..f66fc23 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/NegativeFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/NegativeFilter.java
@@ -21,9 +21,6 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/PosterizeFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/PosterizeFilter.java
index bc2e553..864d7e2 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/PosterizeFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/PosterizeFilter.java
@@ -21,9 +21,6 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/RedEyeFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/RedEyeFilter.java
index 8618804..48b2fdf 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/RedEyeFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/RedEyeFilter.java
@@ -21,9 +21,6 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
@@ -31,8 +28,6 @@ import android.graphics.Bitmap;
import android.graphics.Canvas;
import android.graphics.Color;
import android.graphics.Paint;
-import android.graphics.PointF;
-import android.util.Log;
/**
* @hide
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/ResizeFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/ResizeFilter.java
index 411e061..c79c11b 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/ResizeFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/ResizeFilter.java
@@ -23,10 +23,7 @@ import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
import android.filterfw.core.GLFrame;
-import android.filterfw.core.KeyValueMap;
import android.filterfw.core.MutableFrameFormat;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/RotateFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/RotateFilter.java
index 3da7939..43d8d6c 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/RotateFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/RotateFilter.java
@@ -22,16 +22,11 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.MutableFrameFormat;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
import android.filterfw.geometry.Quad;
import android.filterfw.geometry.Point;
-import android.util.Log;
/**
* @hide
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/SaturateFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/SaturateFilter.java
index b83af39..757fac1 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/SaturateFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/SaturateFilter.java
@@ -21,9 +21,6 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/SepiaFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/SepiaFilter.java
index 7a83fdf..a9f4e2c 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/SepiaFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/SepiaFilter.java
@@ -21,9 +21,6 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/SharpenFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/SharpenFilter.java
index 256b769..a290996 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/SharpenFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/SharpenFilter.java
@@ -21,15 +21,10 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
-import java.util.Set;
-
public class SharpenFilter extends Filter {
@GenerateFieldPort(name = "scale", hasDefault = true)
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/SimpleImageFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/SimpleImageFilter.java
index f4fc271..afe92de 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/SimpleImageFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/SimpleImageFilter.java
@@ -21,16 +21,10 @@ import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
-import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
import java.lang.reflect.Field;
-import java.util.HashSet;
-import java.util.Set;
/**
* @hide
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/StraightenFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/StraightenFilter.java
index c9f097d..9db296b 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/StraightenFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/StraightenFilter.java
@@ -22,16 +22,11 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.MutableFrameFormat;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
import android.filterfw.geometry.Quad;
import android.filterfw.geometry.Point;
-import android.util.Log;
/**
* @hide
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/TintFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/TintFilter.java
index 0da54a5..2b140ba 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/TintFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/TintFilter.java
@@ -21,9 +21,6 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/ToGrayFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/ToGrayFilter.java
index 00e7bf4..760ce3a 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/ToGrayFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/ToGrayFilter.java
@@ -17,23 +17,14 @@
package android.filterpacks.imageproc;
-import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
-import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
import android.filterfw.core.MutableFrameFormat;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
-import android.util.Log;
-
-import java.lang.reflect.Field;
-
/**
* @hide
*/
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/ToPackedGrayFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/ToPackedGrayFilter.java
index bc4a65e..3c121d0 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/ToPackedGrayFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/ToPackedGrayFilter.java
@@ -27,8 +27,6 @@ import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
-import android.util.Log;
-
import java.lang.Math;
/**
* @hide
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/ToRGBAFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/ToRGBAFilter.java
index ab4814f..f0084fa 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/ToRGBAFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/ToRGBAFilter.java
@@ -21,16 +21,11 @@ import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
-import android.filterfw.core.KeyValueMap;
import android.filterfw.core.MutableFrameFormat;
import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
-import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
-import android.util.Log;
-
/**
* @hide
*/
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/ToRGBFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/ToRGBFilter.java
index 9258502..bbb0fc3 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/ToRGBFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/ToRGBFilter.java
@@ -21,16 +21,11 @@ import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
-import android.filterfw.core.KeyValueMap;
import android.filterfw.core.MutableFrameFormat;
import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
-import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
-import android.util.Log;
-
/**
* @hide
*/
diff --git a/media/mca/filterpacks/java/android/filterpacks/imageproc/VignetteFilter.java b/media/mca/filterpacks/java/android/filterpacks/imageproc/VignetteFilter.java
index 715fec6..249cc6f 100644
--- a/media/mca/filterpacks/java/android/filterpacks/imageproc/VignetteFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/imageproc/VignetteFilter.java
@@ -21,9 +21,6 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
diff --git a/media/mca/filterpacks/java/android/filterpacks/text/StringSource.java b/media/mca/filterpacks/java/android/filterpacks/text/StringSource.java
index cc33b89..2fe519f 100644
--- a/media/mca/filterpacks/java/android/filterpacks/text/StringSource.java
+++ b/media/mca/filterpacks/java/android/filterpacks/text/StringSource.java
@@ -22,8 +22,6 @@ import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.KeyValueMap;
-import android.filterfw.core.MutableFrameFormat;
import android.filterfw.format.ObjectFormat;
/**
diff --git a/media/mca/filterpacks/java/android/filterpacks/ui/SurfaceRenderFilter.java b/media/mca/filterpacks/java/android/filterpacks/ui/SurfaceRenderFilter.java
index a5c1ccb..ba88736 100644
--- a/media/mca/filterpacks/java/android/filterpacks/ui/SurfaceRenderFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/ui/SurfaceRenderFilter.java
@@ -26,19 +26,11 @@ import android.filterfw.core.GenerateFieldPort;
import android.filterfw.core.GenerateFinalPort;
import android.filterfw.core.GLEnvironment;
import android.filterfw.core.GLFrame;
-import android.filterfw.core.KeyValueMap;
import android.filterfw.core.MutableFrameFormat;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
-import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
-import android.view.Surface;
import android.view.SurfaceHolder;
-import android.view.SurfaceView;
-
-import android.graphics.Rect;
import android.util.Log;
diff --git a/media/mca/filterpacks/java/android/filterpacks/ui/SurfaceTargetFilter.java b/media/mca/filterpacks/java/android/filterpacks/ui/SurfaceTargetFilter.java
index 308d168..05cb81b 100644
--- a/media/mca/filterpacks/java/android/filterpacks/ui/SurfaceTargetFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/ui/SurfaceTargetFilter.java
@@ -25,19 +25,11 @@ import android.filterfw.core.GenerateFieldPort;
import android.filterfw.core.GenerateFinalPort;
import android.filterfw.core.GLEnvironment;
import android.filterfw.core.GLFrame;
-import android.filterfw.core.KeyValueMap;
import android.filterfw.core.MutableFrameFormat;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
-import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
import android.view.Surface;
-import android.view.SurfaceHolder;
-import android.view.SurfaceView;
-
-import android.graphics.Rect;
import android.util.Log;
diff --git a/media/mca/filterpacks/java/android/filterpacks/videoproc/BackDropperFilter.java b/media/mca/filterpacks/java/android/filterpacks/videoproc/BackDropperFilter.java
index 78f7f3e..a31ac2c 100644
--- a/media/mca/filterpacks/java/android/filterpacks/videoproc/BackDropperFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/videoproc/BackDropperFilter.java
@@ -24,7 +24,6 @@ import android.filterfw.core.Frame;
import android.filterfw.core.GLFrame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.MutableFrameFormat;
-import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
import android.opengl.GLES20;
@@ -32,7 +31,6 @@ import android.os.SystemClock;
import android.os.SystemProperties;
import android.util.Log;
-import java.lang.ArrayIndexOutOfBoundsException;
import java.lang.Math;
import java.util.Arrays;
import java.nio.ByteBuffer;
diff --git a/media/mca/filterpacks/java/android/filterpacks/videosink/MediaEncoderFilter.java b/media/mca/filterpacks/java/android/filterpacks/videosink/MediaEncoderFilter.java
index 8bb653b..d034051 100644
--- a/media/mca/filterpacks/java/android/filterpacks/videosink/MediaEncoderFilter.java
+++ b/media/mca/filterpacks/java/android/filterpacks/videosink/MediaEncoderFilter.java
@@ -17,32 +17,23 @@
package android.filterpacks.videosink;
-import android.content.Context;
import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
-import android.filterfw.core.FrameManager;
import android.filterfw.core.GenerateFieldPort;
-import android.filterfw.core.GenerateFinalPort;
import android.filterfw.core.GLFrame;
-import android.filterfw.core.KeyValueMap;
import android.filterfw.core.MutableFrameFormat;
-import android.filterfw.core.NativeFrame;
-import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
import android.filterfw.geometry.Point;
import android.filterfw.geometry.Quad;
-import android.os.ConditionVariable;
import android.media.MediaRecorder;
import android.media.CamcorderProfile;
import android.filterfw.core.GLEnvironment;
import java.io.IOException;
import java.io.FileDescriptor;
-import java.util.List;
-import java.util.Set;
import android.util.Log;
diff --git a/media/mca/filterpacks/java/android/filterpacks/videosink/MediaRecorderStopException.java b/media/mca/filterpacks/java/android/filterpacks/videosink/MediaRecorderStopException.java
index dbf9768..ce7a8c1 100644
--- a/media/mca/filterpacks/java/android/filterpacks/videosink/MediaRecorderStopException.java
+++ b/media/mca/filterpacks/java/android/filterpacks/videosink/MediaRecorderStopException.java
@@ -18,7 +18,6 @@
package android.filterpacks.videosink;
import java.lang.RuntimeException;
-import android.util.Log;
/** @hide **/
public class MediaRecorderStopException extends RuntimeException {
diff --git a/media/mca/filterpacks/java/android/filterpacks/videosrc/CameraSource.java b/media/mca/filterpacks/java/android/filterpacks/videosrc/CameraSource.java
index 2c474ab..d260684 100644
--- a/media/mca/filterpacks/java/android/filterpacks/videosrc/CameraSource.java
+++ b/media/mca/filterpacks/java/android/filterpacks/videosrc/CameraSource.java
@@ -17,29 +17,22 @@
package android.filterpacks.videosrc;
-import android.content.Context;
import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
-import android.filterfw.core.FrameManager;
import android.filterfw.core.GenerateFieldPort;
import android.filterfw.core.GenerateFinalPort;
import android.filterfw.core.GLFrame;
-import android.filterfw.core.KeyValueMap;
import android.filterfw.core.MutableFrameFormat;
-import android.filterfw.core.NativeFrame;
-import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
import android.graphics.SurfaceTexture;
import android.hardware.Camera;
-import android.os.ConditionVariable;
import android.opengl.Matrix;
import java.io.IOException;
import java.util.List;
-import java.util.Set;
import android.util.Log;
diff --git a/media/mca/filterpacks/java/android/filterpacks/videosrc/MediaSource.java b/media/mca/filterpacks/java/android/filterpacks/videosrc/MediaSource.java
index 0be6c62..53a39a7 100644
--- a/media/mca/filterpacks/java/android/filterpacks/videosrc/MediaSource.java
+++ b/media/mca/filterpacks/java/android/filterpacks/videosrc/MediaSource.java
@@ -23,28 +23,20 @@ import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
-import android.filterfw.core.FrameManager;
import android.filterfw.core.GenerateFieldPort;
import android.filterfw.core.GenerateFinalPort;
import android.filterfw.core.GLFrame;
-import android.filterfw.core.KeyValueMap;
import android.filterfw.core.MutableFrameFormat;
-import android.filterfw.core.NativeFrame;
-import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
import android.graphics.SurfaceTexture;
import android.media.MediaPlayer;
import android.net.Uri;
-import android.os.ConditionVariable;
import android.opengl.Matrix;
import android.view.Surface;
import java.io.IOException;
-import java.io.FileDescriptor;
import java.lang.IllegalArgumentException;
-import java.util.List;
-import java.util.Set;
import android.util.Log;
diff --git a/media/mca/filterpacks/java/android/filterpacks/videosrc/SurfaceTextureSource.java b/media/mca/filterpacks/java/android/filterpacks/videosrc/SurfaceTextureSource.java
index 37fa242..6595baa 100644
--- a/media/mca/filterpacks/java/android/filterpacks/videosrc/SurfaceTextureSource.java
+++ b/media/mca/filterpacks/java/android/filterpacks/videosrc/SurfaceTextureSource.java
@@ -16,31 +16,20 @@
package android.filterpacks.videosrc;
-import android.content.Context;
-import android.content.res.AssetFileDescriptor;
import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
-import android.filterfw.core.FrameManager;
import android.filterfw.core.GenerateFieldPort;
import android.filterfw.core.GenerateFinalPort;
import android.filterfw.core.GLFrame;
-import android.filterfw.core.KeyValueMap;
import android.filterfw.core.MutableFrameFormat;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
import android.graphics.SurfaceTexture;
-import android.media.MediaPlayer;
import android.os.ConditionVariable;
import android.opengl.Matrix;
-import java.io.IOException;
-import java.io.FileDescriptor;
-import java.lang.IllegalArgumentException;
-import java.util.List;
-import java.util.Set;
-
import android.util.Log;
/** <p>A filter that converts textures from a SurfaceTexture object into frames for
diff --git a/media/mca/filterpacks/java/android/filterpacks/videosrc/SurfaceTextureTarget.java b/media/mca/filterpacks/java/android/filterpacks/videosrc/SurfaceTextureTarget.java
index b6d9f94..5d03627 100644
--- a/media/mca/filterpacks/java/android/filterpacks/videosrc/SurfaceTextureTarget.java
+++ b/media/mca/filterpacks/java/android/filterpacks/videosrc/SurfaceTextureTarget.java
@@ -19,29 +19,19 @@ package android.filterpacks.videosrc;
import android.filterfw.core.Filter;
import android.filterfw.core.FilterContext;
-import android.filterfw.core.FilterSurfaceView;
import android.filterfw.core.Frame;
import android.filterfw.core.FrameFormat;
import android.filterfw.core.GenerateFieldPort;
import android.filterfw.core.GenerateFinalPort;
import android.filterfw.core.GLEnvironment;
import android.filterfw.core.GLFrame;
-import android.filterfw.core.KeyValueMap;
import android.filterfw.core.MutableFrameFormat;
-import android.filterfw.core.NativeProgram;
-import android.filterfw.core.NativeFrame;
-import android.filterfw.core.Program;
import android.filterfw.core.ShaderProgram;
import android.filterfw.format.ImageFormat;
import android.filterfw.geometry.Quad;
import android.filterfw.geometry.Point;
-import android.view.Surface;
-import android.view.SurfaceHolder;
-import android.view.SurfaceView;
-
-import android.graphics.Rect;
import android.graphics.SurfaceTexture;
import android.util.Log;