diff options
Diffstat (limited to 'include')
| -rw-r--r-- | include/gui/SurfaceTexture.h | 13 | ||||
| -rw-r--r-- | include/media/MediaProfiles.h | 20 | ||||
| -rw-r--r-- | include/ui/Input.h | 4 | ||||
| -rw-r--r-- | include/ui/KeyCharacterMap.h | 1 | ||||
| -rw-r--r-- | include/ui/Keyboard.h | 18 |
5 files changed, 31 insertions, 25 deletions
diff --git a/include/gui/SurfaceTexture.h b/include/gui/SurfaceTexture.h index d7dd4d6..27d863d 100644 --- a/include/gui/SurfaceTexture.h +++ b/include/gui/SurfaceTexture.h @@ -271,7 +271,8 @@ private: mRequestBufferCalled(false), mTransform(0), mScalingMode(NATIVE_WINDOW_SCALING_MODE_FREEZE), - mTimestamp(0) { + mTimestamp(0), + mFrameNumber(0) { mCrop.makeInvalid(); } @@ -340,6 +341,10 @@ private: // mTimestamp is the current timestamp for this buffer slot. This gets // to set by queueBuffer each time this slot is queued. int64_t mTimestamp; + + // mFrameNumber is the number of the queued frame for this slot. + uint64_t mFrameNumber; + }; // mSlots is the array of buffer slots that must be mirrored on the client @@ -476,6 +481,12 @@ private: // around a GL driver limitation on the number of FBO attachments, which the // browser's tile cache exceeds. const GLenum mTexTarget; + + // mFrameCounter is the free running counter, incremented for every buffer queued + // with the surface Texture. + uint64_t mFrameCounter; + + }; // ---------------------------------------------------------------------------- diff --git a/include/media/MediaProfiles.h b/include/media/MediaProfiles.h index eab7648..250f267 100644 --- a/include/media/MediaProfiles.h +++ b/include/media/MediaProfiles.h @@ -48,15 +48,21 @@ enum camcorder_quality { }; /** - *Set CIF as default maximum import and export resolution of video editor. - *The maximum import and export resolutions are platform specific, - *which should be defined in media_profiles.xml. + * Set CIF as default maximum import and export resolution of video editor. + * The maximum import and export resolutions are platform specific, + * which should be defined in media_profiles.xml. + * Set default maximum prefetch YUV frames to 6, which means video editor can + * queue up to 6 YUV frames in the video encoder source. + * This value is used to limit the amount of memory used by video editor + * engine when the encoder consumes YUV frames at a lower speed + * than video editor engine produces. */ enum videoeditor_capability { VIDEOEDITOR_DEFAULT_MAX_INPUT_FRAME_WIDTH = 352, VIDEOEDITOR_DEFUALT_MAX_INPUT_FRAME_HEIGHT = 288, VIDEOEDITOR_DEFAULT_MAX_OUTPUT_FRAME_WIDTH = 352, VIDEOEDITOR_DEFUALT_MAX_OUTPUT_FRAME_HEIGHT = 288, + VIDEOEDITOR_DEFAULT_MAX_PREFETCH_YUV_FRAMES = 6 }; enum video_decoder { @@ -138,6 +144,8 @@ public: * videoeditor.input.height.max - max input video frame height * videoeditor.output.width.max - max output video frame width * videoeditor.output.height.max - max output video frame height + * maxPrefetchYUVFrames - max prefetch YUV frames in video editor engine. This value is used + * to limit the memory consumption. */ int getVideoEditorCapParamByName(const char *name) const; @@ -357,11 +365,12 @@ private: }; struct VideoEditorCap { VideoEditorCap(int inFrameWidth, int inFrameHeight, - int outFrameWidth, int outFrameHeight) + int outFrameWidth, int outFrameHeight, int frames) : mMaxInputFrameWidth(inFrameWidth), mMaxInputFrameHeight(inFrameHeight), mMaxOutputFrameWidth(outFrameWidth), - mMaxOutputFrameHeight(outFrameHeight) {} + mMaxOutputFrameHeight(outFrameHeight), + mMaxPrefetchYUVFrames(frames) {} ~VideoEditorCap() {} @@ -369,6 +378,7 @@ private: int mMaxInputFrameHeight; int mMaxOutputFrameWidth; int mMaxOutputFrameHeight; + int mMaxPrefetchYUVFrames; }; int getCamcorderProfileIndex(int cameraId, camcorder_quality quality) const; diff --git a/include/ui/Input.h b/include/ui/Input.h index 438a1a0..c2cbe1d 100644 --- a/include/ui/Input.h +++ b/include/ui/Input.h @@ -826,6 +826,9 @@ public: inline void setKeyboardType(int32_t keyboardType) { mKeyboardType = keyboardType; } inline int32_t getKeyboardType() const { return mKeyboardType; } + inline void setKeyCharacterMapFile(const String8& value) { mKeyCharacterMapFile = value; } + inline const String8& getKeyCharacterMapFile() const { return mKeyCharacterMapFile; } + inline const Vector<MotionRange>& getMotionRanges() const { return mMotionRanges; } @@ -835,6 +838,7 @@ private: String8 mName; uint32_t mSources; int32_t mKeyboardType; + String8 mKeyCharacterMapFile; Vector<MotionRange> mMotionRanges; }; diff --git a/include/ui/KeyCharacterMap.h b/include/ui/KeyCharacterMap.h index 10a3810..be14432 100644 --- a/include/ui/KeyCharacterMap.h +++ b/include/ui/KeyCharacterMap.h @@ -53,7 +53,6 @@ public: ~KeyCharacterMap(); static status_t load(const String8& filename, KeyCharacterMap** outMap); - static status_t loadByDeviceId(int32_t deviceId, KeyCharacterMap** outMap); /* Gets the keyboard type. */ int32_t getKeyboardType() const; diff --git a/include/ui/Keyboard.h b/include/ui/Keyboard.h index 609f319..274f526 100644 --- a/include/ui/Keyboard.h +++ b/include/ui/Keyboard.h @@ -81,24 +81,6 @@ extern bool isEligibleBuiltInKeyboard(const InputDeviceIdentifier& deviceIdentif const PropertyMap* deviceConfiguration, const KeyMap* keyMap); /** - * Sets keyboard system properties. - */ -extern void setKeyboardProperties(int32_t deviceId, const InputDeviceIdentifier& deviceIdentifier, - const String8& keyLayoutFile, const String8& keyCharacterMapFile); - -/** - * Clears keyboard system properties. - */ -extern void clearKeyboardProperties(int32_t deviceId); - -/** - * Gets the key character map filename for a device using inspecting system properties - * and then falling back on a default key character map if necessary. - * Returns a NAME_NOT_FOUND if none found. - */ -extern status_t getKeyCharacterMapFile(int32_t deviceId, String8& outKeyCharacterMapFile); - -/** * Gets a key code by its short form label, eg. "HOME". * Returns 0 if unknown. */ |
