1 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
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/. */
7 #include "CompositorTypes.h"
14 std::ostream
& operator<<(std::ostream
& aStream
, const TextureFlags
& aFlags
) {
15 if (aFlags
== TextureFlags::NO_FLAGS
) {
18 #define AppendFlag(test) \
20 if (!!(aFlags & (test))) { \
28 bool previous
= false;
29 AppendFlag(TextureFlags::USE_NEAREST_FILTER
);
30 AppendFlag(TextureFlags::ORIGIN_BOTTOM_LEFT
);
31 AppendFlag(TextureFlags::DISALLOW_BIGIMAGE
);
32 AppendFlag(TextureFlags::RB_SWAPPED
);
33 AppendFlag(TextureFlags::NON_PREMULTIPLIED
);
34 AppendFlag(TextureFlags::RECYCLE
);
35 AppendFlag(TextureFlags::DEALLOCATE_CLIENT
);
36 AppendFlag(TextureFlags::DEALLOCATE_SYNC
);
37 AppendFlag(TextureFlags::IMMUTABLE
);
38 AppendFlag(TextureFlags::IMMEDIATE_UPLOAD
);
39 AppendFlag(TextureFlags::COMPONENT_ALPHA
);
40 AppendFlag(TextureFlags::INVALID_COMPOSITOR
);
41 AppendFlag(TextureFlags::RGB_FROM_YCBCR
);
42 AppendFlag(TextureFlags::SNAPSHOT
);
43 AppendFlag(TextureFlags::NON_BLOCKING_READ_LOCK
);
44 AppendFlag(TextureFlags::BLOCKING_READ_LOCK
);
45 AppendFlag(TextureFlags::WAIT_HOST_USAGE_END
);
46 AppendFlag(TextureFlags::IS_OPAQUE
);
53 } // namespace mozilla