* EGLImageTargetRenderbufferStorageOES was incorrectly accepting
TEXTURE_EXTERNAL_OES as a target. Revert that; the host GL will
correctly reject it with INVALID_ENUM.
* Handle the REQUIRED_TEXTURE_IMAGE_UNITS_OES texparameter query.
* Validate texture parameters set on TEXTURE_EXTERNAL textures;
otherwise invalid parameters would work on the emulator but not on a
real device.
Change-Id: I49a088608d58a9822f33e5916bd354eee3709127
The gralloc API assumes system-wide reference counting of gralloc
buffers. The host-GL accelerated gralloc maps buffers to host-side
ColorBuffer objects, but was destroying them unconditionally in
gralloc_free(), ignoring any additional references from
gralloc_register_buffer().
This affected the SurfaceTexture gralloc buffers used by the
Browser/WebView. For some reason these buffers are actually allocated
by SurfaceFlinger and passed back to the WebView through Binder. But
since SurfaceFlinger doesn't actually need the buffer for anything,
sometime after the WebView has called gralloc_register_buffer()
SurfaceFlinger calls gralloc_free() on it. This caused the host
ColorBuffer to be destroyed long before the WebView is done using it.
Change-Id: I33dbee887a48a6907041cf19e9f38a1f6c983eff
Copy changes faaf1553cf and
f37a7ed6c5 from the GLESv1 translator to
the GLESv2 translator. After this, both translators use the same logic
for glEGLImageTargetTexture2DOES().
Change-Id: I0a95bf2301df7b7428abc593f38170edf4cbda30
Off-by-two bug when removing textures from the tracking array could
overwrite malloc's mem chunk data structure, usually resulting in a
heap corruption abort on a later malloc/realloc/free.
Bug: 5951738
Change-Id: I11056bb62883373c2a3403f53899347ff8cdabf2
The data pointer argument to glBufferData can be NULL; this
[re]allocates the buffer while leaving the contents undefined.
Bug: 5833436
Change-Id: Ia1ddf62e2cd2c59d3d631e01d23d7c557ca5a52e
* Disable verbose debug spam.
* Add missing GL enum to utility function. The default case was
returning the correct size, so this doesn't fix any bugs, just
removes some logcat spam.
* Comment and whitespace corrections.
Change-Id: I83fb8644331ae1072d6a8dae9c041da92073089f
The code that creates the GL-accelerated screen view wasn't converting
the upper-left-relative coordinates used within the emulator to the
lower-left coordinates used by the Cocoa APIs on OS X. Since most
skins have the screen view centered vertically this often just
happened to work.
Bug: 5782118
Change-Id: I2f96ee181e850df5676d10a82d86c94421149b40
Having it landscape by default is not representative of a phone
and triggers an issue where the system ui bar is not displayed.
Change-Id: Ic28e3739c30825fe55f8cc6cede5c9a5462f6931
The emulator EGL implementation tried to hold its own reference to
buffers acquired/released with dequeueBuffer/queueBuffer, but was
missing an incRef after dequeueBuffer during swapBuffers.
Since the native window holds a reference to the buffer between
dequeueBuffer and queueBuffer, the EGL reference isn't needed anyway.
Change-Id: I95e4f9f4faf59198f99939cdca6603fe176c56bc
Using fake camera implementation for WB/exposure, implement the same functionality
on frames comming from webcam emulator. Note that due to heavy computations that
are involved in implementing this, we will do all that math in the emulator
application in order to provide a decent performance.
Change-Id: Id6c37b472860674c91e6ca37522fc61f497515a3
The glBufferData, glBufferSubData, and glDeleteBuffers entry points
had interception routines in GL2Encoder which cache the data, but they
weren't hooked up. So when glDrawElements tried to retrieve the cached
data it wasn't there.
Change-Id: Iaed11fccaefab3186485be53a0f15c8ca0a255f9
Camera framework requires 352x288, and 320x240 frames for video preview and video
recording. If these dimensions are missing in camera properties the camera app
may abort when entering video mode, or start video recording.
Also truned off switching fake frames, leaving only the checker board.
(cherry picked from commit 6f00e7fc48)
Change-Id: Ic50225e1700ea3b04ae5445549548f2ffe4ae2df