gstreamer-graphix/api/api.proto

86 lines
1.6 KiB
Protocol Buffer

syntax = "proto3";
option go_package = "./api";
package api;
message Pipeline {
string name = 1;
string clip = 2;
string output = 3;
repeated Overlay overlays = 4;
}
message Overlay {
string name = 1;
int64 x = 2;
int64 y = 3;
bool display = 4;
int64 blend_in = 5;
int64 blend_out = 6;
oneof overlay_data {
ExtraOverlay extra = 7;
TextOverlay text_overlay = 8;
ImageOverlay image_overlay = 9;
}
}
message ExtraOverlay {
map<string, string> properties = 1;
}
message ImageOverlay {
int64 x = 2;
int32 y = 3;
string path = 7;
}
message TextOverlay {
string name = 1;
int64 x = 2;
int64 y = 3;
string text = 4;
uint64 font_size = 5;
string font_name = 6;
string font_weight = 7;
uint32 font_color = 8;
uint64 max_width = 9;
}
message PipelineCreationResponse {
PipelineID pipeline_id = 1;
}
message PipelineUpdates {
PipelineID id = 1;
repeated Overlay overlays = 2;
}
message PipelineID {
string id = 1;
}
message PipelineUpdateResponse {
PipelineID pipeline_id = 1;
}
message PipelineStartResponse {
PipelineID pipeline_id = 1;
}
message PipelineStopResponse {
PipelineID pipeline_id = 1;
}
message PipelineDeleteResponse {
PipelineID pipeline_id = 1;
}
service PipelineService {
rpc CreatePipeline(Pipeline) returns (PipelineCreationResponse);
rpc UpdatePipeline(PipelineUpdates) returns (PipelineUpdateResponse);
rpc StartPipeline(PipelineID) returns (PipelineStartResponse);
rpc StopPipeline(PipelineID) returns (PipelineStopResponse);
rpc DeletePipeline(PipelineID) returns (PipelineDeleteResponse);
}