1 # -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
2 # vim: set filetype=python:
3 # This Source Code Form is subject to the terms of the Mozilla Public
4 # License, v. 2.0. If a copy of the MPL was not distributed with this
5 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 BUG_COMPONENT = ("Core", "Graphics")
11 BUG_COMPONENT = ("Core", "Panning and Zooming")
14 "composite/CompositableHost.h",
24 "opengl/OGLShaderConfig.h",
25 "opengl/OGLShaderProgram.h",
28 if CONFIG["MOZ_WIDGET_TOOLKIT"] == "windows":
30 "D3D11ShareHandleImage.cpp",
31 "D3D11TextureIMFSampleImage.cpp",
32 "D3D11YCbCrImage.cpp",
37 if CONFIG["MOZ_ENABLE_D3D10_LAYER"]:
38 EXPORTS.mozilla.layers += [
39 "d3d11/CompositorD3D11.h",
40 "d3d11/DeviceAttachmentsD3D11.h",
42 "d3d11/GpuProcessD3D11QueryMap.h",
43 "d3d11/GpuProcessD3D11TextureMap.h",
44 "d3d11/HelpersD3D11.h",
45 "d3d11/ShaderDefinitionsD3D11.h",
46 "d3d11/TextureD3D11.h",
47 "d3d11/TextureHostWrapperD3D11.h",
50 "d3d11/FenceD3D11.cpp",
51 "d3d11/GpuProcessD3D11QueryMap.cpp",
52 "d3d11/GpuProcessD3D11TextureMap.cpp",
53 "d3d11/TextureD3D11.cpp",
54 "d3d11/TextureHostWrapperD3D11.cpp",
57 "d3d11/CompositorD3D11.cpp",
58 "d3d11/DeviceAttachmentsD3D11.cpp",
60 if CONFIG["MOZ_WMF_MEDIA_ENGINE"]:
61 EXPORTS.mozilla.layers += [
62 "DcompSurfaceImage.h",
65 "DcompSurfaceImage.cpp",
69 "ipc/ShadowLayerUtils.h",
70 "ipc/SurfaceDescriptor.h",
73 EXPORTS.mozilla.dom += [
74 "apz/util/CheckerboardReportService.h",
77 EXPORTS.mozilla.gfx += [
81 EXPORTS.mozilla.layers += [
84 "AnimationStorageData.h",
85 "apz/public/APZInputBridge.h",
86 "apz/public/APZPublicUtils.h",
87 "apz/public/APZSampler.h",
88 "apz/public/APZUpdater.h",
89 "apz/public/CompositorController.h",
90 "apz/public/GeckoContentController.h",
91 "apz/public/GeckoContentControllerTypes.h",
92 "apz/public/IAPZCTreeManager.h",
93 "apz/public/MatrixMessage.h",
94 # exporting things from apz/src is temporary until we extract a
95 # proper interface for the code there
97 "apz/src/AsyncDragMetrics.h",
98 "apz/src/FocusTarget.h",
99 "apz/src/KeyboardMap.h",
100 "apz/src/KeyboardScrollAction.h",
101 "apz/testutil/APZTestData.h",
102 "apz/util/ActiveElementManager.h",
103 "apz/util/APZCCallbackHelper.h",
104 "apz/util/APZEventState.h",
105 "apz/util/APZTaskRunnable.h",
106 "apz/util/APZThreadUtils.h",
107 "apz/util/ChromeProcessController.h",
108 "apz/util/ContentProcessController.h",
109 "apz/util/DoubleTapToZoom.h",
110 "apz/util/InputAPZContext.h",
111 "apz/util/ScrollingInteractionContext.h",
112 "apz/util/ScrollLinkedEffectDetector.h",
113 "apz/util/TouchActionHelper.h",
114 "apz/util/TouchCounter.h",
115 "AtomicRefCountedWithFinalize.h",
116 "AxisPhysicsModel.h",
117 "AxisPhysicsMSDModel.h",
121 "CanvasDrawEventRecorder.h",
123 "client/CanvasClient.h",
124 "client/CompositableClient.h",
125 "client/GPUVideoTextureClient.h",
126 "client/ImageClient.h",
127 "client/TextureClient.h",
128 "client/TextureClientPool.h",
129 "client/TextureClientRecycleAllocator.h",
130 "client/TextureClientSharedSurface.h",
131 "client/TextureRecorded.h",
132 "composite/Diagnostics.h",
133 "composite/FrameUniformityData.h",
134 "composite/GPUVideoTextureHost.h",
135 "composite/ImageComposite.h",
136 "composite/RemoteTextureHostWrapper.h",
137 "composite/TextureHost.h",
138 "CompositionRecorder.h",
140 "CompositorAnimationStorage.h",
142 "D3D11ShareHandleImage.h",
143 "D3D11TextureIMFSampleImage.h",
147 "ImageDataSerializer.h",
148 "ipc/ActiveResource.h",
150 "ipc/APZCTreeManagerChild.h",
151 "ipc/APZCTreeManagerParent.h",
152 "ipc/APZInputBridgeChild.h",
153 "ipc/APZInputBridgeParent.h",
155 "ipc/CanvasTranslator.h",
156 "ipc/CompositableForwarder.h",
157 "ipc/CompositableTransactionParent.h",
158 "ipc/CompositorBridgeChild.h",
159 "ipc/CompositorBridgeParent.h",
160 "ipc/CompositorManagerChild.h",
161 "ipc/CompositorManagerParent.h",
162 "ipc/CompositorThread.h",
163 "ipc/CompositorVsyncScheduler.h",
164 "ipc/CompositorVsyncSchedulerOwner.h",
165 "ipc/ContentCompositorBridgeParent.h",
166 "ipc/ImageBridgeChild.h",
167 "ipc/ImageBridgeParent.h",
168 "ipc/ISurfaceAllocator.h",
169 "ipc/KnowsCompositor.h",
170 "ipc/LayersMessageUtils.h",
171 "ipc/LayerTreeOwnerTracker.h",
172 "ipc/RefCountedShmem.h",
173 "ipc/RemoteContentController.h",
174 "ipc/SharedPlanarYCbCrImage.h",
175 "ipc/SharedRGBImage.h",
176 "ipc/SharedSurfacesChild.h",
177 "ipc/SharedSurfacesMemoryReport.h",
178 "ipc/SharedSurfacesParent.h",
179 "ipc/SynchronousTask.h",
180 "ipc/TextureForwarder.h",
181 "ipc/UiCompositorControllerChild.h",
182 "ipc/UiCompositorControllerMessageTypes.h",
183 "ipc/UiCompositorControllerParent.h",
184 "ipc/VideoBridgeChild.h",
185 "ipc/VideoBridgeParent.h",
186 "ipc/VideoBridgeUtils.h",
188 "MemoryPressureObserver.h",
190 "OOPCanvasRenderer.h",
191 "opengl/CompositingRenderTargetOGL.h",
192 "opengl/CompositorOGL.h",
193 "opengl/MacIOSurfaceTextureClientOGL.h",
194 "opengl/MacIOSurfaceTextureHostOGL.h",
195 "opengl/TextureClientOGL.h",
196 "opengl/TextureHostOGL.h",
197 "PersistentBufferProvider.h",
198 "ProfilerScreenshots.h",
199 "RecordedCanvasEventImpl.h",
200 "RemoteTextureMap.h",
203 "ScreenshotGrabber.h",
204 "ScrollableLayerGuid.h",
206 "ShareableCanvasRenderer.h",
207 "SourceSurfaceSharedData.h",
210 "TextureSourceProvider.h",
211 "TextureWrapperImage.h",
212 "TransactionIdAllocator.h",
214 "UpdateImageHelper.h",
215 "wr/AsyncImagePipelineManager.h",
216 "wr/AsyncImagePipelineOp.h",
218 "wr/DisplayItemCache.h",
219 "wr/HitTestInfoManager.h",
220 "wr/IpcResourceUpdateQueue.h",
221 "wr/OMTAController.h",
223 "wr/RenderRootStateManager.h",
224 "wr/RenderRootTypes.h",
225 "wr/StackingContextHelper.h",
226 "wr/WebRenderBridgeChild.h",
227 "wr/WebRenderBridgeParent.h",
228 "wr/WebRenderCanvasRenderer.h",
229 "wr/WebRenderCommandBuilder.h",
230 "wr/WebRenderDrawEventRecorder.h",
231 "wr/WebRenderImageHost.h",
232 "wr/WebRenderLayerManager.h",
233 "wr/WebRenderMessageUtils.h",
234 "wr/WebRenderScrollData.h",
235 "wr/WebRenderScrollDataWrapper.h",
236 "wr/WebRenderTextureHost.h",
237 "wr/WebRenderUserData.h",
241 if CONFIG["MOZ_WIDGET_TOOLKIT"] == "gtk":
242 EXPORTS.mozilla.layers += [
243 "DMABUFSurfaceImage.h",
244 "opengl/DMABUFTextureClientOGL.h",
245 "opengl/DMABUFTextureHostOGL.h",
248 "DMABUFSurfaceImage.cpp",
249 "opengl/DMABUFTextureClientOGL.cpp",
250 "opengl/DMABUFTextureHostOGL.cpp",
253 if CONFIG["MOZ_WAYLAND"]:
254 EXPORTS.mozilla.layers += [
255 "NativeLayerWayland.h",
256 "SurfacePoolWayland.h",
259 "NativeLayerWayland.cpp",
260 "SurfacePoolWayland.cpp",
263 if CONFIG["MOZ_WIDGET_TOOLKIT"] == "cocoa":
264 EXPORTS.mozilla.layers += [
269 "MacIOSurfaceHelpers.h",
270 "MacIOSurfaceImage.h",
277 "MacIOSurfaceHelpers.cpp",
278 "MacIOSurfaceImage.cpp",
281 "-framework IOSurface",
284 if CONFIG["MOZ_WIDGET_TOOLKIT"] == "android":
285 EXPORTS.mozilla.layers += [
286 "AndroidHardwareBuffer.h",
289 "AndroidHardwareBuffer.cpp",
290 "apz/src/AndroidAPZ.cpp",
291 "apz/src/AndroidFlingPhysics.cpp",
292 "apz/src/AndroidVelocityTracker.cpp",
296 "AnimationHelper.cpp",
298 "apz/src/APZCTreeManager.cpp",
299 "apz/src/APZInputBridge.cpp",
300 "apz/src/APZPublicUtils.cpp",
301 "apz/src/APZSampler.cpp",
302 "apz/src/APZUpdater.cpp",
303 "apz/src/APZUtils.cpp",
304 "apz/src/AsyncPanZoomController.cpp",
305 "apz/src/AutoscrollAnimation.cpp",
307 "apz/src/CheckerboardEvent.cpp",
308 "apz/src/DragTracker.cpp",
309 "apz/src/ExpectedGeckoMetrics.cpp",
310 "apz/src/FlingAccelerator.cpp",
311 "apz/src/FocusState.cpp",
312 "apz/src/FocusTarget.cpp",
313 "apz/src/GenericScrollAnimation.cpp",
314 "apz/src/GestureEventListener.cpp",
315 "apz/src/HitTestingTreeNode.cpp",
316 "apz/src/IAPZHitTester.cpp",
317 "apz/src/InputBlockState.cpp",
318 "apz/src/InputQueue.cpp",
319 "apz/src/KeyboardMap.cpp",
320 "apz/src/KeyboardScrollAction.cpp",
321 "apz/src/OverscrollHandoffState.cpp",
322 "apz/src/OvershootDetector.cpp",
323 "apz/src/PotentialCheckerboardDurationTracker.cpp",
324 "apz/src/QueuedInput.cpp",
325 "apz/src/SampledAPZCState.cpp",
326 "apz/src/ScrollThumbUtils.cpp",
327 "apz/src/SimpleVelocityTracker.cpp",
328 "apz/src/SmoothMsdScrollAnimation.cpp",
329 "apz/src/SmoothScrollAnimation.cpp",
330 "apz/src/WheelScrollAnimation.cpp",
331 "apz/src/WRHitTester.cpp",
332 "apz/testutil/APZTestData.cpp",
333 "apz/util/ActiveElementManager.cpp",
334 "apz/util/APZCCallbackHelper.cpp",
335 "apz/util/APZEventState.cpp",
336 "apz/util/APZTaskRunnable.cpp",
337 "apz/util/APZThreadUtils.cpp",
338 "apz/util/CheckerboardReportService.cpp",
339 "apz/util/ChromeProcessController.cpp",
340 "apz/util/ContentProcessController.cpp",
341 "apz/util/DoubleTapToZoom.cpp",
342 "apz/util/InputAPZContext.cpp",
343 "apz/util/ScrollingInteractionContext.cpp",
344 "apz/util/ScrollLinkedEffectDetector.cpp",
345 "apz/util/TouchActionHelper.cpp",
346 "apz/util/TouchCounter.cpp",
347 "AxisPhysicsModel.cpp",
348 "AxisPhysicsMSDModel.cpp",
351 "CanvasDrawEventRecorder.cpp",
352 "CanvasRenderer.cpp",
353 "client/CanvasClient.cpp",
354 "client/CompositableClient.cpp",
355 "client/GPUVideoTextureClient.cpp",
356 "client/ImageClient.cpp",
357 "client/TextureClientPool.cpp",
358 "client/TextureClientRecycleAllocator.cpp",
359 "client/TextureClientSharedSurface.cpp",
360 "client/TextureRecorded.cpp",
361 "composite/CompositableHost.cpp",
362 "composite/FrameUniformityData.cpp",
363 "composite/GPUVideoTextureHost.cpp",
364 "composite/ImageComposite.cpp",
365 "composite/RemoteTextureHostWrapper.cpp",
366 "CompositionRecorder.cpp",
368 "CompositorAnimationStorage.cpp",
369 "CompositorTypes.cpp",
373 "ImageDataSerializer.cpp",
375 "ipc/APZCTreeManagerChild.cpp",
376 "ipc/APZCTreeManagerParent.cpp",
377 "ipc/APZInputBridgeChild.cpp",
378 "ipc/APZInputBridgeParent.cpp",
379 "ipc/CanvasChild.cpp",
380 "ipc/CanvasTranslator.cpp",
381 "ipc/CompositableForwarder.cpp",
382 "ipc/CompositableTransactionParent.cpp",
383 "ipc/CompositorBench.cpp",
384 "ipc/CompositorBridgeChild.cpp",
385 "ipc/CompositorBridgeParent.cpp",
386 "ipc/CompositorManagerChild.cpp",
387 "ipc/CompositorManagerParent.cpp",
388 "ipc/CompositorThread.cpp",
389 "ipc/CompositorVsyncScheduler.cpp",
390 "ipc/ContentCompositorBridgeParent.cpp",
391 "ipc/ImageBridgeChild.cpp",
392 "ipc/ImageBridgeParent.cpp",
393 "ipc/ISurfaceAllocator.cpp",
394 "ipc/KnowsCompositor.cpp",
395 "ipc/LayerTreeOwnerTracker.cpp",
396 "ipc/RefCountedShmem.cpp",
397 "ipc/RemoteContentController.cpp",
398 "ipc/SharedPlanarYCbCrImage.cpp",
399 "ipc/SharedRGBImage.cpp",
400 "ipc/SharedSurfacesChild.cpp",
401 "ipc/SharedSurfacesParent.cpp",
402 "ipc/UiCompositorControllerChild.cpp",
403 "ipc/UiCompositorControllerParent.cpp",
404 "ipc/VideoBridgeChild.cpp",
405 "ipc/VideoBridgeParent.cpp",
407 "MemoryPressureObserver.cpp",
408 "opengl/CompositingRenderTargetOGL.cpp",
409 "opengl/CompositorOGL.cpp",
410 "opengl/OGLShaderProgram.cpp",
411 "opengl/TextureClientOGL.cpp",
412 "opengl/TextureHostOGL.cpp",
413 "ProfilerScreenshots.cpp",
414 "RemoteTextureMap.cpp",
415 "RepaintRequest.cpp",
417 "ScreenshotGrabber.cpp",
418 "ScrollableLayerGuid.cpp",
419 "ShareableCanvasRenderer.cpp",
420 "SourceSurfaceSharedData.cpp",
422 "TextureSourceProvider.cpp",
423 "TextureWrapperImage.cpp",
424 "wr/AsyncImagePipelineManager.cpp",
425 "wr/AsyncImagePipelineOp.cpp",
426 "wr/ClipManager.cpp",
427 "wr/DisplayItemCache.cpp",
428 "wr/HitTestInfoManager.cpp",
429 "wr/IpcResourceUpdateQueue.cpp",
430 "wr/OMTAController.cpp",
431 "wr/OMTASampler.cpp",
432 "wr/RenderRootStateManager.cpp",
433 "wr/RenderRootTypes.cpp",
434 "wr/StackingContextHelper.cpp",
435 "wr/WebRenderBridgeChild.cpp",
436 "wr/WebRenderBridgeParent.cpp",
437 "wr/WebRenderCanvasRenderer.cpp",
438 "wr/WebRenderCommandBuilder.cpp",
439 "wr/WebRenderDrawEventRecorder.cpp",
440 "wr/WebRenderImageHost.cpp",
441 "wr/WebRenderLayerManager.cpp",
442 "wr/WebRenderScrollData.cpp",
443 "wr/WebRenderUserData.cpp",
444 "ZoomConstraints.cpp",
445 # XXX here are some unified build error.
446 #'wr/WebRenderTextureHost.cpp'
450 "client/TextureClient.cpp",
451 "composite/TextureHost.cpp",
452 "ImageContainer.cpp",
453 "PersistentBufferProvider.cpp",
454 "wr/WebRenderTextureHost.cpp",
457 DEFINES["GOOGLE_PROTOBUF_NO_RTTI"] = True
458 DEFINES["GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER"] = True
459 DEFINES["MOZ_APP_VERSION"] = CONFIG["MOZ_APP_VERSION"]
461 if CONFIG["MOZ_WIDGET_TOOLKIT"] == "cocoa":
463 "opengl/MacIOSurfaceTextureClientOGL.cpp",
464 "opengl/MacIOSurfaceTextureHostOGL.cpp",
468 "ipc/LayersMessages.ipdlh",
469 "ipc/LayersSurfaces.ipdlh",
471 "ipc/PAPZCTreeManager.ipdl",
472 "ipc/PAPZInputBridge.ipdl",
474 "ipc/PCompositorBridge.ipdl",
475 "ipc/PCompositorBridgeTypes.ipdlh",
476 "ipc/PCompositorManager.ipdl",
477 "ipc/PImageBridge.ipdl",
479 "ipc/PUiCompositorController.ipdl",
480 "ipc/PVideoBridge.ipdl",
481 "ipc/PWebRenderBridge.ipdl",
482 "ipc/WebRenderMessages.ipdlh",
485 include("/ipc/chromium/chromium-config.mozbuild")
487 if CONFIG["COMPILE_ENVIRONMENT"] and CONFIG["MOZ_WIDGET_TOOLKIT"] == "windows":
489 "CompositorD3D11Shaders.h",
490 script="d3d11/genshaders.py",
491 inputs=["d3d11/shaders.manifest"],
495 "/docshell/base", # for nsDocShell.h
496 "/dom/canvas", # for intertwined WebGL headers
497 "/gfx/cairo/cairo/src",
498 "/layout/base", # for TouchManager.h
499 "/layout/generic", # for nsTextFrame.h
500 "/media/libyuv/libyuv/include", # for libyuv.h
503 FINAL_LIBRARY = "xul"
505 if CONFIG["MOZ_DEBUG"]:
506 DEFINES["D3D_DEBUG_INFO"] = True
508 if CONFIG["MOZ_ENABLE_D3D10_LAYER"]:
509 DEFINES["MOZ_ENABLE_D3D10_LAYER"] = True
511 if CONFIG["ENABLE_TESTS"]:
512 DIRS += ["apz/test/gtest"]
513 DIRS += ["apz/test/gtest/mvm"]
515 MOCHITEST_MANIFESTS += ["apz/test/mochitest/mochitest.toml"]
516 BROWSER_CHROME_MANIFESTS += ["apz/test/mochitest/browser.toml"]
518 if CONFIG["MOZ_WIDGET_TOOLKIT"] == "gtk":
519 CXXFLAGS += CONFIG["MOZ_GTK3_CFLAGS"]
521 CXXFLAGS += ["-Werror=switch"]
523 LOCAL_INCLUDES += CONFIG["SKIA_INCLUDES"]
525 # Suppress warnings in third-party code.
526 if CONFIG["CC_TYPE"] == "gcc":
527 CXXFLAGS += ["-Wno-maybe-uninitialized"]
529 UNIFIED_SOURCES += []
531 # Add libFuzzer configuration directives
532 include("/tools/fuzzing/libfuzzer-config.mozbuild")