Skip to content

📺 Streaming OBS video into maps on item frames at a high frame rate

License

Notifications You must be signed in to change notification settings

menggatot/MakiScreen

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MakiScreen

📺 Streaming OBS video into maps on item frames at a high frame rate

2021-12-09.13-47-41-1.mp4

How does it work

  • Load jar plugin onto 1.17.1 Paper server
  • It will start a thread to listen for UDP packets on port 1337
  • Use ffmpeg to send OBS Virtual Camera as JPG frames to the UDP socket
  • Renders the latest available frame in Minecraft!

Get started (It's not easy, and it's experimental)

Beware that map will probably be overwritten

  • Download MakiScreen jar and place in Spigot 1.13+ server plugins
  • Download FFmpeg and make sure it's in your path
  • Download OBS
  • Run Paper server and make sure port 1337 UDP is available, and then turn it off after the server has finished starting up
  • Change the size setting in config.yml to match your output resolution
  • Run OBS and make sure the output resolution is according to the config option and the base resolution is set to same as the config or any resolution with 2:1 aspect ratio, and set the frame rate to 20
  • Turn on your OBS Virtual Camera
  • Open terminal shell and enter ffmpeg -y -f dshow -thread_queue_size 4096 -hwaccel cuda -hwaccel_output_format cuda -i video="OBS Virtual Camera" -f rawvideo -c:v mjpeg -qscale:v 1 -r 20 udp://127.0.0.1:1337
    • you can remove -hwaccel cuda -hwaccel_output_format cuda if you're not using nvidia GPU
    • set -qscale:v 1 you can increase this value from 1 to 31 to lower your bitrate
  • Run Paper server and Type /maki in Minecraft to get the maps

if your performance went doodoo, you could try removing both data.yml in the MakiScreen folder and removing anything in the data folder in the world folder

Help me

You can contact me on Discord at Maki#4845 or on Twitter at @MakiXx_

Credit

  • CodedRed For ImageManager class
  • DNx5 for synchronizing the maps, optimizing the code, implementing sierra2 dithering. literally do all the hard work for me
  • EzMediaCore for the dither algorithm

About

📺 Streaming OBS video into maps on item frames at a high frame rate

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Java 100.0%