Skip to content

Commit

Permalink
Add PixelFormat enum
Browse files Browse the repository at this point in the history
  • Loading branch information
OFFTKP committed Jan 10, 2024
1 parent 20538b9 commit dd942c8
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions include/hydra/core.hxx
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,12 @@ namespace hydra
IconHeight,
};

enum class PixelFormat
{
RGBA,
BGRA,
};

#define X_HYDRA_INTERFACES \
X_HYDRA_INTERFACE(IBase) \
X_HYDRA_INTERFACE(IFrontendDriven) \
Expand Down Expand Up @@ -261,6 +267,11 @@ namespace hydra

// Sets the callback that the emulator must call every frame to render the frame
virtual void setVideoCallback(void (*callback)(void* data, hydra::Size size)) = 0;

virtual hydra::PixelFormat getPixelFormat()
{
return hydra::PixelFormat::RGBA;
}
};

// The OpenGL rendered emulator interface, OpenGL rendered emulators inherit this
Expand Down

0 comments on commit dd942c8

Please sign in to comment.