From aa73b8e860e62e26272989e33b2604e45cd2e69f Mon Sep 17 00:00:00 2001 From: bronwyn <119465870+notbronwyn@users.noreply.github.com> Date: Sat, 30 Mar 2024 14:04:01 -0400 Subject: [PATCH 1/2] Create CCSMB-14.md --- Standards/CCSMB-14.md | 56 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 Standards/CCSMB-14.md diff --git a/Standards/CCSMB-14.md b/Standards/CCSMB-14.md new file mode 100644 index 0000000..271b0ef --- /dev/null +++ b/Standards/CCSMB-14.md @@ -0,0 +1,56 @@ +# *CCSMB 14:* Stereo television + +*Author: @notbronwyn* +*Version: v1.0* +*Last updated: 2024-03-30* + +## Server: +Videos should either be in BIMG but other formats do not break compliance as long as they are marked in "type" to avoid issues with clients and there is an open-source encoder and decoder + + an example of this would be [PBB](https://raw.githubusercontent.com/craftytv/pigutv/main/pbbconverter.py) which is supported in the example server + +Broadcasts in BIMG should only use the default CraftOS pallete + +Each frame of video should have enough audio to last the entire frame and no more + +Each packet sent from the server most have "protocol" set to "stereovideo" + +Each packet should have metadata for the TV broadcast + +An optional feature that packets can have is subtitles + +An example of a compliant server is [here](https://github.com/craftytv/television/tree/main/channel) + +Example of a packet: +```lua +{ + protocol = "stereovideo", -- Always stereo video + type = broadcastType, -- Image format (BIMG, etc.) SHOULD BE ALL LOWERCASE + audio = { + left = leftbuffer, -- Decoded PCM, left channel + right = rightbuffer -- Decoded PCM, right channel + }, + video = currentFrame, -- Either a frame of PBB or BIMG + subtitle = subtitle, --Subtitles is avaliable + meta = { + name = station, --TV station name + title = program, --What the name of the video is + owner = owner --Owner of the TV station + } +} +``` + +## Client: +Clients should be able to display BIMG and avoid incompatible formats to prevent any issues + +Supporting formats other than BIMG does not break compliance as long as there is an open-source encoder and decoder + +Clients should be able to play stereo audio in-sync with the frames + +Clients should be able to display subtitles + +Displaying metadata attached to broadcasts is optional + +If the client supports multiple palletes, the client should be able to switch back to default pallete before changing broadcasts + +An example of a compliant client is [here](https://github.com/craftytv/television/tree/main/tuner) From ac84a3b8a98fefae678b036684327d8ace3d61d3 Mon Sep 17 00:00:00 2001 From: WindClan <119465870+WindClan@users.noreply.github.com> Date: Sat, 22 Jun 2024 02:40:55 -0400 Subject: [PATCH 2/2] Try and make it more clear --- Standards/CCSMB-14.md | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/Standards/CCSMB-14.md b/Standards/CCSMB-14.md index 271b0ef..12580e4 100644 --- a/Standards/CCSMB-14.md +++ b/Standards/CCSMB-14.md @@ -1,15 +1,20 @@ # *CCSMB 14:* Stereo television -*Author: @notbronwyn* +*Author: @WindClan* *Version: v1.0* -*Last updated: 2024-03-30* +*Last updated: 2024-06-22* + +## Both: +BIMG video should be at least 57x38 characters (resolution of a 3x3 monitor) and no more than 20 fps. + +The only requirement for the video is that it can be decoded without hogging server resources ## Server: Videos should either be in BIMG but other formats do not break compliance as long as they are marked in "type" to avoid issues with clients and there is an open-source encoder and decoder an example of this would be [PBB](https://raw.githubusercontent.com/craftytv/pigutv/main/pbbconverter.py) which is supported in the example server -Broadcasts in BIMG should only use the default CraftOS pallete +High framerate broadcasts in BIMG should only use the default CraftOS pallete or a static pallete that doesn't change Each frame of video should have enough audio to last the entire frame and no more @@ -17,7 +22,7 @@ Each packet sent from the server most have "protocol" set to "stereovideo" Each packet should have metadata for the TV broadcast -An optional feature that packets can have is subtitles +An optional feature that packets can have is subtitles by including a `subtitles` index in a frame An example of a compliant server is [here](https://github.com/craftytv/television/tree/main/channel) @@ -47,9 +52,9 @@ Supporting formats other than BIMG does not break compliance as long as there is Clients should be able to play stereo audio in-sync with the frames -Clients should be able to display subtitles +Clients should be able to display subtitles by reading the "subtitles" metadata from each frame -Displaying metadata attached to broadcasts is optional +Displaying metadata (ex. station and program) attached to broadcasts is optional If the client supports multiple palletes, the client should be able to switch back to default pallete before changing broadcasts