15 Commits
Author SHA1 Message Date
Jason Macnak 3adb8882e4 Pimpl-ify the host headers
... to break up the circular header imports between the main host
server headers and the underlying GL/VK backend headers. This is
needed to support further imports to internal which is stricter
about header includes.

Additional android CI on ag/33941257

Bug: b/423634910
Test: android build
Test: bazel build
Test: cmake build
Test: meson build
Change-Id: I378640034bc665c07dec5edbd396074d79e94cd6
2025-06-10 20:10:09 +00:00
Jason Macnak 453d39675a Use Gfxstream's Stream for save/load interface
Moves several of the "common/base" classes to host/backend as these
classes all used `Stream` which is a host only interface.

Bug: b/403363880

Test: cd hardware/google/gfxstream
      mma

Test: cd hardware/google/gfxstream
      mkdir build && cd build
      cmake .. -G Ninja
      ninja

Test: meson setup \
        -Ddefault_library=static \
        -Dgfxstream-build=host \
        build

      meson compile -C build

Test: cd <emu main dev repo>
      cd external/qemu
      python android/build/python/cmake.py --gfxstream

Test: cd <emu main next repo>
      prebuilts/bazel/linux-x86_64/bazel test \
      --platforms=@//build/bazel/platforms:linux_x64 \
     @gfxstream//...

Change-Id: Ia664776c2322b310614f632e4926bb3b031f3bc1
2025-05-07 12:35:25 -07:00
Jason Macnak b001c743d3 Update non interface parts of Gfxstream to use new base lib
NO_IFTTT=existing field covered with type change

Bug: b/403363880

Test: cd hardware/google/gfxstream
      mma

Test: cd hardware/google/gfxstream
      mkdir build && cd build
      cmake .. -G Ninja
      ninja

Test: meson setup \
        -Ddefault_library=static \
        -Dgfxstream-build=host \
        build

      meson compile -C build

Test: cd <emu master dev repo>
      cd external/qemu
      python android/build/python/cmake.py --gfxstream

Test: cd <emu main next repo>
      prebuilts/bazel/linux-x86_64/bazel test \
      --platforms=@//build/bazel/platforms:linux_x64 \
     @gfxstream//...
Change-Id: I6bfb2c4ef8368799d9f99f6293d9762b7dcb4c7f
2025-05-01 16:29:17 +00:00
Jason Macnak a43dfa9f3c Add gfxstream host logging lib
... to eventually replace the existing host-common/logging. This
is needed to break up the circular dependency between aemu-base and
aemu-host-common, so that we can move parts of aemu-base and
aemu-host-common into hardware/google/gfxstream, in order to make
Gfxstream a self contained library for building.

Hooks up the existing host-common/logging via the
RenderLibImpl::setLogger() call.

Bug: b/403363880

Test: cd hardware/google/gfxstream
      mma

Test: cd hardware/google/gfxstream
      mkdir build && cd build
      cmake .. -G Ninja
      ninja

Test: meson setup \
        -Ddefault_library=static \
        -Dgfxstream-build=host \
        build
      meson compile -C build

Test: cd <emu master dev repo>
      cd external/qemu
      python android/build/python/cmake.py --gfxstream

Test: cd <emu main next repo>
      prebuilts/bazel/linux-x86_64/bazel test \
      --platforms=@//build/bazel/platforms:linux_x64 \
     @gfxstream//...

Change-Id: Id52c6f756f85d0a5fb948601228234d7a84a14c2
2025-04-09 13:11:08 -07:00
Jason Macnak 4e379d810e Remove the global VkEmulation variable
... and move into FrameBuffer.

Bug: b/383139165
Test: cvd create --gpu_mode=gfxstream_guest_angle_host_swiftshader
Change-Id: Iab139a0793564b21126a66946031caab8a8a6456
2025-03-04 13:03:38 -08:00
Jason Macnak 17b4107260 Make VkEmulation a class w/ VkCommonOperations funcs
... so that members can start to be protected with GUARDED_BY
annotations and potentially can start to eliminate having a
global `sVkEmulation`.

Bug: b/383139165
Test: cvd create --gpu_mode=gfxstream_guest_angle_host_swiftshader
Change-Id: Iae4dd859991015e386fcc30ef091ccdb7ed1aeb6
2025-03-04 12:56:10 -08:00
Aaron Ruby 9ef51649a5 Revert^2 "Use a common GenericDescriptorInfo struct"
1bfb4638b4

NO_IFTTT=doesn't affect snapshot

Change-Id: I754c649c6e1f842108674ea405c6dcaab90e9c07
2024-12-18 10:46:01 -05:00
Lars Harrison 1bfb4638b4 Revert "Use a common GenericDescriptorInfo struct"
Revert submission 3393388-extmem-refactor-dec-5

Reason for revert: b/384041851 (+gap in test coverage)

Reverted changes: /q/submissionid:3393388-extmem-refactor-dec-5

NO_IFTTT=Revert, doesn't affect snapshot

Change-Id: I6b3184618a4beb16a25ddd1dbbd55d551aa85190
2024-12-13 19:03:45 -08:00
Aaron Ruby 4dd24d4409 Use a common GenericDescriptorInfo struct
Also clean up references to headers/namespace for ManagedDescriptor type

BUG=382442209
TEST=compile
NO_IFTTT=doesn't affect snapshot

Change-Id: I7dc660f239e47974588b574b3ce676c482658bd7
2024-12-09 13:35:59 -05:00
Gurchetan Singh 619646f3a4 gfxstream: host: BlobManager --> ExternalObjectManager
We should try to support external sync, along with
external memory so:

find ./ -type f -exec sed -i -e 's/BlobManager/ExternalObjectManager/g' {} \;
find ./ -type f -exec sed -i -e 's/removeDescriptorInfo/removeBlobDescriptorInfo/g' {} \;
find ./ -type f -exec sed -i -e 's/addDescriptorInfo/addBlobDescriptorInfo/g' {} \;
find ./ -type f -exec sed -i -e 's/mDescriptorInfo/mBlobDescriptorInfo/g' {} \;
find ./ -type f -exec sed -i -e 's/ManagedDescriptorInfo/BlobDescriptorInfo/g' {} \;

BUG=350965057
TEST=compile

Change-Id: Id9fe5319ed617638ae8c67f9377f5426fe15cf44
2024-07-03 16:21:42 +00:00
Gurchetan Singh b86aa8b160 gfxstream: host: add exportColorBuffer + exportBuffer functions
We want to share the color buffer or buffer with a Wayland,

BUG=349122558
TEST=see dmabufs being exported

Change-Id: I5d3a94aec2b7a58b8281ba081d8041e21d12e8bf
2024-07-02 11:47:45 -07:00
Gurchetan Singh 95b30dc862 Reland "gfxstream: introduce GFXSTREAM_ENABLE_HOST_GLES compiler flag"
Same as before, but added extra GFXSTREAM_ENABLE_HOST_GLES
to keep MacOS builders happy.

Change-Id: I333503ecb6e67840326ce248428fa097eb152e92
2024-01-18 18:34:08 -08:00
Gurchetan Singh 6ed12e9d66 Revert "gfxstream: introduce GFXSTREAM_ENABLE_HOST_GLES compiler flag"
This reverts commit 4675a9d4ef.

Reason for revert: I suppose it breaks MacOS

Change-Id: I91bef5c2fa0e8726b6e77e6678540b808ad26316
2024-01-19 02:19:50 +00:00
Gurchetan Singh 4675a9d4ef gfxstream: introduce GFXSTREAM_ENABLE_HOST_GLES compiler flag
This allows:

meson -Ddecoders=vulkan

to build without errors.  This is useful for enviroments where
GLES does not exist (Fuchsia) or where importing the entire
gfxstream GLES decoder is undesirable.

BUG=31148679
TEST=compile

Change-Id: I59e385c205588a4dbbe472fac1681ebe261127dc
2024-01-17 18:13:22 -08:00
Jason Macnak 648a9edc06 Rename stream-servers to host
Bug: b/271464937
Test: m
Change-Id: I89553dfe2e27170e1e968e234b364f13e76b2f88
2023-05-19 15:09:46 -07:00