Add the corresponding capability to NativeWindow and implement
getPlatformExtension virtual method to return a native pointer that can
be used with eglCreatePlatformWindowSurfaceEXT().
Bug: angleproject:6961
Change-Id: Ieb1a1fd8b3cae4e6f199c269f3922cbd0307aa35
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3452102
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Auto-Submit: Antonio Caggiano <antonio.caggiano@collabora.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
This pipes through to a system call via JNI. This will allow
Chromium changes to land that were prevented because ANGLE
hard-coded some parts of this path. This in turn will allow
us to more easily override these paths for changes needed
for Android R support.
Bug: chromium:1094062
Change-Id: I20d75b8ee40d418ba5c057f618640ef896248299
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2315483
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Jonah Ryan-Davis <jonahr@google.com>
This lets the trace perf tests run configurable number of frames
within a single swap. The offscreen config is similar to how
gfxbench works. It renders to a user FBO (by overriding calls to
BindFramebuffer) and then composits multiple frames into the real
backbuffer. This allows us to get a perf measurement with less
overhead from composition and display.
Adds emulation for some APIs that operate on Framebuffers like
BindFramebuffer, Invalidate, DrawBuffers and ReadBuffer.
Bug: angleproject:4845
Change-Id: I1044c1d52c82f1c215a68a6c46d74c52ed0f3d2a
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2300207
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
EGL_WINDOW_BIT is now specifically requested for tests that open a
window (those that aren't WithNoFixture). This makes sure pbuffer-only
configs are not selected for the window.
Additionally, a few WithNoFixture tests are made more robust in the
presence of no-window configs.
In the context of crbug.com/1034840, this means that a subset of end2end
tests would be able to run in a remote desktop environment. Tested on
Linux/X11 by turning a subset of configs PBUFFER-only.
Bug: chromium:1034840
Change-Id: I09fd149d43d3b865856fe6b9491c5f333f4a2efc
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2378922
Reviewed-by: Jonah Ryan-Davis <jonahr@google.com>
Reviewed-by: back sept 10 - Jamie Madill <jmadill@chromium.org>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
This CL adds a reverse JNI call to our Android Native Activity that
sets the orientation of the screen based on width and height.
To achieve this we:
* Attach to the java thread once at the beginning to grab JNI env.
* Detach from the thread once when platform sends APP_CMD_DESTROY
* Set the orientation during test init
Bug: angleproject:4327
Change-Id: Ifbe31a6a84dd60a0dfe7d7032962c99b290d8b81
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2289054
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Commit-Queue: Cody Northrop <cnorthrop@google.com>
Changes how context states are serialized during capture run. Now,
context states are serialized after each frame until the end frame
is reached, or context is destroyed.
Adds an api to the trace files to query serialization results of
multiple frames. Makes change to CaptureReplayTest to serialize
multiple frames then compares the serialization results with the ones
retrieved from said api.
Adds to capture replay the ability to produce working, compilable trace
files even when end frame is not reached.
Adds to the generated trace files config information and makes
CaptureReplayTest utilize said config information to reproduce the exact
environment of the captured application.
Bug: angleproject:4817
Change-Id: Ie3d487af2bacf349dc3ff6f6b1b5f89e1169dc84
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2282885
Commit-Queue: Manh Nguyen <nguyenmh@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Removes an unreferenced function. Also adds the ability for samples to
respond to key up and down events. Only implemented on Windows.
Bug: angleproject:2830
Change-Id: I44c9f93f0ad07b92923ffc0efa580f97d9b98693
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1908448
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
For all "ANGLE Project" copyrights, standardize to the format specified
by the style guide. Changes:
- "Copyright (c)" and "Copyright(c)" changed to just "Copyright".
- Removed the second half of date ranges ("Y1Y1-Y2Y2"->"Y1Y1").
- Fixed a small number of files that had no copyright date using the
initial commit year from the version control history.
- Fixed one instance of copyright being "The ANGLE Project" rather than
"The ANGLE Project Authors"
These changes are applied both to the copyright of source file, and
where applicable to copyright statements that are generated by
templates.
BUG=angleproject:3811
Change-Id: I973dd65e4ef9deeba232d5be74c768256a0eb2e5
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1754397
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
WebKit uses the -Wshorten-64-to-32 flag which warns on these cases.
Bug: 3439
Change-Id: I8c1de60da0f173ca2036e2120e79b857f5f2775f
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1740866
Commit-Queue: James Darpinian <jdarpinian@chromium.org>
Reviewed-by: Kenneth Russell <kbr@chromium.org>
Add DisplayVk and WindowSurfaceVk subclasses for Fuchsia to the vulkan
renderer, as well as an implementation of OSWindow that renders
fullscreen for the test suite.
Disallow use of the vulkan loader from third_party as Fuchsia uses a fork
of the loader and has not sent those changes upstream yet.
Add a small wayland-inspired library libfuchsia-egl to provide a type
"struct fuchsia_egl_window" to use as EGLNativeWindowType. This type
combines a zx_handle_t to an image pipe channel and a surface size.
Image pipes can only be used once to create a VkSurfaceKHR. This means we
have to recreate the pipe in tests that call eglCreateWindowSurface more
than once with a single OSWindow, or the second call will fail. Add a
resetNativeWindow() method to accomplish this.
Reland disabling -Wextra-semi.
BUG=angleproject:2475
TEST=angle_end2end_tests on Fuchsia
Change-Id: Ie91715bcd760c6c04d4b8a02a91daa71e32ee30c
Reviewed-on: https://chromium-review.googlesource.com/c/1467603
Commit-Queue: Michael Spang <spang@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
This reverts commit 991d1cfb5e.
Reason for revert: Failing compile on the fuchsia bots on the ANGLE
auto-roller.
https://ci.chromium.org/p/chromium/builders/luci.chromium.try/fuchsia_x64/209198
In file included from ../../third_party/angle/util/fuchsia/ScenicWindow.cpp:10:
In file included from ../../third_party/angle/util/fuchsia/ScenicWindow.h:13:
In file included from gen/third_party/fuchsia-sdk/sdk/fidl/fuchsia/ui/policy/cpp/fidl.h:5:
In file included from ../../third_party/fuchsia-sdk/sdk/pkg/fidl_cpp/include/lib/fidl/cpp/internal/header.h:12:
../../third_party/fuchsia-sdk/sdk/pkg/fit/include/lib/fit/function.h:135:6: error: extra ';' after member function definition [-Werror,-Wextra-semi]
};
^
1 error generated.
Original change's description:
> Vulkan: Port renderer to Fuchsia
>
> Add DisplayVk and WindowSurfaceVk subclasses for Fuchsia to the vulkan
> renderer, as well as an implementation of OSWindow that renders
> fullscreen for the test suite.
>
> Disallow use of the vulkan loader from third_party as Fuchsia uses a fork
> of the loader and has not sent those changes upstream yet.
>
> Add a small wayland-inspired library libfuchsia-egl to provide a type
> "struct fuchsia_egl_window" to use as EGLNativeWindowType. This type
> combines a zx_handle_t to an image pipe channel and a surface size.
>
> Image pipes can only be used once to create a VkSurfaceKHR. This means we
> have to recreate the pipe in tests that call eglCreateWindowSurface more
> than once with a single OSWindow, or the second call will fail. Add a
> resetNativeWindow() method to accomplish this.
>
> BUG=angleproject:2475
> TEST=angle_end2end_tests on Fuchsia
>
> Change-Id: I71a613a362dd1c8aada49a3c02ae461e064457bf
> Reviewed-on: https://chromium-review.googlesource.com/c/1446496
> Commit-Queue: Michael Spang <spang@chromium.org>
> Reviewed-by: Jamie Madill <jmadill@chromium.org>
TBR=spang@chromium.org,geofflang@chromium.org,jmadill@chromium.org,syoussefi@chromium.org
Change-Id: I2d9abefa9db5363ba63a17c1773d0e147040d055
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: angleproject:2475
Reviewed-on: https://chromium-review.googlesource.com/c/1465761
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Add DisplayVk and WindowSurfaceVk subclasses for Fuchsia to the vulkan
renderer, as well as an implementation of OSWindow that renders
fullscreen for the test suite.
Disallow use of the vulkan loader from third_party as Fuchsia uses a fork
of the loader and has not sent those changes upstream yet.
Add a small wayland-inspired library libfuchsia-egl to provide a type
"struct fuchsia_egl_window" to use as EGLNativeWindowType. This type
combines a zx_handle_t to an image pipe channel and a surface size.
Image pipes can only be used once to create a VkSurfaceKHR. This means we
have to recreate the pipe in tests that call eglCreateWindowSurface more
than once with a single OSWindow, or the second call will fail. Add a
resetNativeWindow() method to accomplish this.
BUG=angleproject:2475
TEST=angle_end2end_tests on Fuchsia
Change-Id: I71a613a362dd1c8aada49a3c02ae461e064457bf
Reviewed-on: https://chromium-review.googlesource.com/c/1446496
Commit-Queue: Michael Spang <spang@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
This cleans up any potential problems with allocating and freeing
resources in different shared objects or DLLs. Previously we were
using a dynamically linked allocation function and then calling
the standard delete function.
Also adds a base class helper for EGLWindow. Will base the WGL
Window class on this.
Needed for running ANGLE tests against native drivers.
Bug: angleproject:2995
Change-Id: Ic92b447649ebb32c547605c20086c07a601842f0
Reviewed-on: https://chromium-review.googlesource.com/c/1393443
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Fixes the Android/ChromeOS/Fuchsia builds by using consistent EGL
headers.
This CL adds a dynamic loader generator based on XML files. It also
refactors the entry point generation script to move the XML parsing
into a helper class.
Additionally this includes a new GLES 1.0 base header. The new
header allows for function pointer types and hiding prototypes.
All tests and samples now load ANGLE dynamically. In the future this
will be extended to load entry points from the driver directly when
possible. This will allow us to perform more accurate A/B testing.
The new build configuration leads to some tests having more warnings
applied. The CL includes fixes for the new warnings.
Bug: angleproject:2995
Change-Id: I5a8772f41a0f89570b3736b785f44b7de1539b57
Reviewed-on: https://chromium-review.googlesource.com/c/1392382
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
This reverts commit 03923558a7.
Reason for revert: fails compilation on Android, ChromeOS and Fuchsia during roll https://chromium-review.googlesource.com/c/chromium/src/+/1392624
Original change's description:
> Load entry points dynamically in tests and samples.
>
> This CL adds a dynamic loader generator based on XML files. It also
> refactors the entry point generation script to move the XML parsing
> into a helper class.
>
> Additionally this includes a new GLES 1.0 base header. The new
> header allows for function pointer types and hiding prototypes.
>
> All tests and samples now load ANGLE dynamically. In the future this
> will be extended to load entry points from the driver directly when
> possible. This will allow us to perform more accurate A/B testing.
>
> The new build configuration leads to some tests having more warnings
> applied. The CL includes fixes for the new warnings.
>
> Bug: angleproject:2995
> Change-Id: I6726d4163f7a6e54d2482f094c0a952f59702a05
> Reviewed-on: https://chromium-review.googlesource.com/c/1359516
> Commit-Queue: Jamie Madill <jmadill@chromium.org>
> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
TBR=ynovikov@chromium.org,jmadill@chromium.org,syoussefi@chromium.org
Change-Id: I902bec2d733c2b879be29c02ab52a0b7d4eaa077
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: angleproject:2995
Reviewed-on: https://chromium-review.googlesource.com/c/1392381
Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
This CL adds a dynamic loader generator based on XML files. It also
refactors the entry point generation script to move the XML parsing
into a helper class.
Additionally this includes a new GLES 1.0 base header. The new
header allows for function pointer types and hiding prototypes.
All tests and samples now load ANGLE dynamically. In the future this
will be extended to load entry points from the driver directly when
possible. This will allow us to perform more accurate A/B testing.
The new build configuration leads to some tests having more warnings
applied. The CL includes fixes for the new warnings.
Bug: angleproject:2995
Change-Id: I6726d4163f7a6e54d2482f094c0a952f59702a05
Reviewed-on: https://chromium-review.googlesource.com/c/1359516
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
This addresses several minor code quality issues that are validated
in Chromium, but not yet applied to ANGLE:
* constructors and destructors must be defined out-of-line
* auto is not allowed for simple pointer types
* use override everywhere instead of virtual
* virtual functions must also be defined out-of-line
Slightly reduces binary size for me (~2k on Win, 150k on Linux).
Bug: angleproject:1569
Change-Id: I073ca3365188caf5f29fb28d9eb207903c1843e6
Reviewed-on: https://chromium-review.googlesource.com/779959
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
So that there will be one instance of static thread synchronization variables
in AndroidWindow.
Previously there was one instance in lib_angle_deqp_gles2_tests__library
and one in libangle_deqp_libgles2, resulting in AndroidWindow::initialize
waiting forever.
Also make the change in GYP build to fix standalone build,
and fix rpath issues on Mac.
BUG=angleproject:1471
TEST=end2end and deqp tests on standalone Win10 and end2end on GN Mac 10.11
Change-Id: I731578459400bb47d269df129aabed9b67b555e6
Reviewed-on: https://chromium-review.googlesource.com/376202
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
So that there will be one instance of static thread synchronization variables
in AndroidWindow.
Previously there was one instance in lib_angle_deqp_gles2_tests__library
and one in libangle_deqp_libgles2, resulting in AndroidWindow::initialize
waiting forever.
BUG=angleproject:1471
Change-Id: Ia529c91e34960eb352730c1bb89a91ce6336c8a0
Reviewed-on: https://chromium-review.googlesource.com/368983
Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Refactorings to egl::Surface to enable ref-counting were causing
a situation where we could have two Window surfaces alive at the
same time. This would confuse the window procedure logic in
SurfaceD3D. Releasing the surface fixes this issue and conforms
closely to the wording on the spec on when Surfaces should be
deleted. Also add a test for message loops and surfaces.
BUG=475085
BUG=angleproject:963
Change-Id: Icdee3a7db97c9b54d779dabf1e1f82a89fefc546
Reviewed-on: https://chromium-review.googlesource.com/265064
Reviewed-by: Kenneth Russell <kbr@chromium.org>
Tested-by: Jamie Madill <jmadill@chromium.org>
We were messing up the client rect on resize, which caused the
ReadPixels checks to mess up around the window edges. Disabling
the window styles on the test windows masked this bug. Fix this
by using a style-less child window inside the parent window.
This gives us access to window styles for the samples project,
along with the ability to use tiny 1x1 windows for testing.
BUG=angle:730
Change-Id: Ic6dd931df7b4e32fbbcacbb004d3bbc49917f658
Reviewed-on: https://chromium-review.googlesource.com/217024
Tested-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
This code shares the Window and EGL logic between the two
projects.
BUG=angle:730
Change-Id: I8940371226a8f7b02579c332f51679c4a5d0e2a5
Reviewed-on: https://chromium-review.googlesource.com/212799
Tested-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Brandon Jones <bajones@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>