| Flutter Impeller |

Public Member Functions | Static Public Member Functions | List of all members
IMPELLER_HPP_NAMESPACE::Surface Class Reference

`#include <impeller.hpp>`

Inheritance diagram for IMPELLER_HPP_NAMESPACE::Surface:

## Public Member Functions
| Surface (ImpellerSurface surface)
| Surface (ImpellerSurface surface, AdoptTag tag)
bool | Draw (const DisplayList &display_list) const
bool | Present () const
Public Member Functions inherited from IMPELLER_HPP_NAMESPACE::Object< ImpellerSurface, ImpellerSurfaceTraits >
| Object ()=default
| Object (ImpellerSurface object)
| Object (ImpellerSurface object, AdoptTag)
| Object (Object &&other)
| Object (const Object &other)
| ~Object ()
Object & | operator= (Object &&other)
Object & | operator= (const Object &other)
ImpellerSurface | Get () const
| operator bool () const

## Static Public Member Functions
static Surface | WrapFBO (const Context &context, uint64_t fbo, ImpellerPixelFormat format, const ImpellerISize &size)
static Surface | WrapMetalDrawable (const Context &context, void *metal_drawable)

## Detailed Description

See also
  ImpellerSurface

Definition at line 1444 of file impeller.hpp.

## Constructor & Destructor Documentation

## ◆ Surface() [1/2]

IMPELLER_HPP_NAMESPACE::Surface::Surface | ( | ImpellerSurface | surface | ) |
| inline explicit

Definition at line 1446 of file impeller.hpp.

1446 : Object(surface) {}
IMPELLER_HPP_NAMESPACE::Object< ImpellerSurface, ImpellerSurfaceTraits >::Object
Object()=default

Referenced by WrapFBO(), and WrapMetalDrawable().

## ◆ Surface() [2/2]

IMPELLER_HPP_NAMESPACE::Surface::Surface | ( | ImpellerSurface | surface,
|  | AdoptTag | tag
| ) |  |
| inline

Definition at line 1448 of file impeller.hpp.

1448 : Object(surface, tag) {}

## Member Function Documentation

## ◆ Draw()

bool IMPELLER_HPP_NAMESPACE::Surface::Draw | ( | const DisplayList & | display_list | ) | const
| inline

See also
  ImpellerSurfaceDrawDisplayList

Definition at line 1480 of file impeller.hpp.

1480 {
1481 return gGlobalProcTable.ImpellerSurfaceDrawDisplayList(Get(),
1482 display_list.Get());
1483 }
IMPELLER_HPP_NAMESPACE::Object< ImpellerSurface, ImpellerSurfaceTraits >::Get
ImpellerSurface Get() const
Definition: impeller.hpp:278
IMPELLER_HPP_NAMESPACE::gGlobalProcTable
ProcTable gGlobalProcTable
Definition: playground_test.cc:25

References IMPELLER_HPP_NAMESPACE::Object< T, Traits >::Get(), IMPELLER_HPP_NAMESPACE::Object< ImpellerSurface, ImpellerSurfaceTraits >::Get(), and IMPELLER_HPP_NAMESPACE::gGlobalProcTable.

## ◆ Present()

bool IMPELLER_HPP_NAMESPACE::Surface::Present | ( |  | ) | const
| inline

See also
  ImpellerSurfacePresent

Definition at line 1488 of file impeller.hpp.

1488 {
1489 return gGlobalProcTable.ImpellerSurfacePresent(Get());
1490 }

References IMPELLER_HPP_NAMESPACE::Object< ImpellerSurface, ImpellerSurfaceTraits >::Get(), and IMPELLER_HPP_NAMESPACE::gGlobalProcTable.

## ◆ WrapFBO()

static Surface IMPELLER_HPP_NAMESPACE::Surface::WrapFBO | ( | const Context & | context,
|  | uint64_t | fbo,
|  | ImpellerPixelFormat | format,
|  | const ImpellerISize & | size
| ) |  |
| inline static

See also
  ImpellerSurfaceCreateWrappedFBONew

Definition at line 1453 of file impeller.hpp.

1456 {
1457 return Surface(
1458 gGlobalProcTable.ImpellerSurfaceCreateWrappedFBONew(context.Get(), //
1459 fbo, //
1460 format, //
1461 &size //
1462 ),
1463 AdoptTag::kAdopt);
1464 }
IMPELLER_HPP_NAMESPACE::Surface::Surface
Surface(ImpellerSurface surface)
Definition: impeller.hpp:1446
IMPELLER_HPP_NAMESPACE::AdoptTag::kAdopt
@ kAdopt

References IMPELLER_HPP_NAMESPACE::Object< T, Traits >::Get(), IMPELLER_HPP_NAMESPACE::gGlobalProcTable, IMPELLER_HPP_NAMESPACE::kAdopt, and Surface().

## ◆ WrapMetalDrawable()

static Surface IMPELLER_HPP_NAMESPACE::Surface::WrapMetalDrawable | ( | const Context & | context,
|  | void * | metal_drawable
| ) |  |
| inline static

See also
  ImpellerSurfaceCreateWrappedMetalDrawableNew

Definition at line 1469 of file impeller.hpp.

1470 {
1471 return Surface(
1472 gGlobalProcTable.ImpellerSurfaceCreateWrappedMetalDrawableNew(
1473 context.Get(), metal_drawable),
1474 AdoptTag::kAdopt);
1475 }

References IMPELLER_HPP_NAMESPACE::Object< T, Traits >::Get(), IMPELLER_HPP_NAMESPACE::gGlobalProcTable, IMPELLER_HPP_NAMESPACE::kAdopt, and Surface().

The documentation for this class was generated from the following file:

- impeller/toolkit/interop/impeller.hpp