Photon Engine 2.0.0-beta
A physically based renderer.
Loading...
Searching...
No Matches
SdlDataPacketInterface.h
Go to the documentation of this file.
1#pragma once
2
3#include "SDL/sdl_fwd.h"
4
5#include <string>
6#include <string_view>
7
8namespace ph
9{
10
14{
15public:
18
26 virtual void parse(
27 std::string_view packetCommand,
28 const SdlInputContext& ctx,
29 std::string_view targetName,
30 ISdlResource* targetInstance,
31 SdlInputClauses& out_clauses) const = 0;
32
39 virtual void generate(
40 const SdlOutputClauses& clauses,
41 const SdlOutputContext& ctx,
42 std::string_view targetName,
43 const ISdlResource* targetInstance,
44 std::string& out_packetCommand) const = 0;
45};
46
47}// end namespace ph
Interface for all SDL resource.
Definition ISdlResource.h:22
Parsing & generating a group of SDL clauses.
Definition SdlDataPacketInterface.h:14
virtual void parse(std::string_view packetCommand, const SdlInputContext &ctx, std::string_view targetName, ISdlResource *targetInstance, SdlInputClauses &out_clauses) const =0
Turn a packet command into out_clauses.
SdlDataPacketInterface()
Definition SdlDataPacketInterface.cpp:6
virtual void generate(const SdlOutputClauses &clauses, const SdlOutputContext &ctx, std::string_view targetName, const ISdlResource *targetInstance, std::string &out_packetCommand) const =0
Turn all data in the clauses into a packet command.
Container for input clauses.
Definition SdlInputClauses.h:18
Data that SDL input process can rely on.
Definition SdlInputContext.h:19
Definition SdlOutputClauses.h:14
Data that SDL output process can rely on.
Definition SdlOutputContext.h:19
The root for all renderer implementations.
Definition EEngineProject.h:6