dom
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 5140
Joined: Wed Aug 17, 2011 7:41 pm
Location: Cambridge

Re: Raspberry Pi and 4k @ 15Hz

Tue Aug 19, 2014 4:01 pm

Demodude123 wrote:Ok, I have Openelec running in 4k at 18Hz (not overclocked), but I noticed I wasn't getting any sound through HDMI to my TV. I went back down to 1920x1080 and sound came out of my television. I also tried forcing audio in the config file to the TV, but that attempt was unsuccessful. Is there any reason why sound isn't coming through a 4k signal from the Pi? What are your thoughts?
Have you got hdmi_drive=2?

Demodude123
Posts: 16
Joined: Wed Jun 11, 2014 5:57 pm

Re: Raspberry Pi and 4k @ 15Hz

Tue Aug 19, 2014 4:53 pm

I did not have it, but when I tried it I got nothing. Sound still works in 1920x1080 though.

stag019
Posts: 10
Joined: Thu Mar 20, 2014 3:58 am

Re: Raspberry Pi and 4k @ 15Hz

Fri Sep 05, 2014 6:35 pm

I've been trying this with my Seiki 39in. TV. The TV itself does state that it's in [email protected] mode, but the framebuffer still maxes out at 1920x1200. Using fbset to try and set it to anything below 1920x1200 works fine, but trying to set it higher causes the screen to become black, of which sometimes I can and sometimes I can't get out of by. And yes, I did run rpi-update and rebooted. I have an old Model B before the RAM upgrade to 512MB if that could possibly have anything to do with it.

Any ideas?

Demodude123
Posts: 16
Joined: Wed Jun 11, 2014 5:57 pm

Re: Raspberry Pi and 4k @ 15Hz

Fri Sep 05, 2014 7:45 pm

stag019 wrote:I've been trying this with my Seiki 39in. TV. The TV itself does state that it's in [email protected] mode, but the framebuffer still maxes out at 1920x1200. Using fbset to try and set it to anything below 1920x1200 works fine, but trying to set it higher causes the screen to become black, of which sometimes I can and sometimes I can't get out of by. And yes, I did run rpi-update and rebooted. I have an old Model B before the RAM upgrade to 512MB if that could possibly have anything to do with it.

Any ideas?
Here are all the options I have set in my config.txt, I would think it would work with the 39in as well as the original Model B:

Code: Select all

disable_overscan=1
hdmi_ignore_edid=0xa5000080
hdmi_cvt 3840 2160 15
framebuffer_width=3840
framebuffer_height=2160
hdmi_group=2
hdmi_mode=87
hdmi_pixel_freq_limit=400000000
max_framebuffer_width=3840
max_framebuffer_height=2160
I noticed when I push 18Hz, I lose sound and gain some blue artifacts flickering on the screen, but the sound works fine at 15Hz (via HDMI, analogue always works). 15 seems pretty steady for the Pi.

stag019
Posts: 10
Joined: Thu Mar 20, 2014 3:58 am

Re: Raspberry Pi and 4k @ 15Hz

Sat Sep 06, 2014 6:18 am

Aha! I had framebuffer_width/height, but not max_framebuffer_width/height. That did the trick. So awesome! Thanks. :)

At first, I was experiencing the same blue artifacts flickering at above 15Hz. But then overclocking (but without overvolting) I was able to get 24Hz working on both Raspian and Openelec, without the blue artifacts. Unfortunately, I still couldn't get 30Hz working, but I'm hoping higher settings and/or overvolting may help with that. I'll try more stuff tomorrow maybe.

Here is my current config.txt:

Code: Select all

disable_overscan=1

hdmi_ignore_edid=0xa5000080
hdmi_group=2
hdmi_mode=87
hdmi_cvt 3840 2160 24

config_hdmi_boost=7

framebuffer_width=3840
framebuffer_height=2160
max_framebuffer_width=3840
max_framebuffer_height=2160

gpu_mem=128
arm_freq=900
gpu_freq=275
sdram_freq=500
hdmi_pixel_freq_limit=400000000
avoid_pwm_pll=1
hvs_priority=0x32ff
I tried taking a screenshot of Openelec, but either pressing printscreen, or sshing and running

Code: Select all

xbmc-send --host=127.0.0.1 -a "TakeScreenshot"
seems to freeze it. It seems the main interface looks to me like it's 3840x2160, but I tried viewing a few pictures and they look like they're 1920x1080 scaled up. I haven't tried any videos yet.

ProfSparkles
Posts: 5
Joined: Mon Sep 29, 2014 7:36 pm

Re: Raspberry Pi and 4k @ 15Hz

Mon Sep 29, 2014 7:41 pm

This is a super interesting topic, has there been any progress?
I was wondering if h264_freq wasn't (software?) locked to 250MHz we might have a chance of playing back 4k video by increasing that clock?

dom
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 5140
Joined: Wed Aug 17, 2011 7:41 pm
Location: Cambridge

Re: Raspberry Pi and 4k @ 15Hz

Wed Oct 01, 2014 10:46 am

ProfSparkles wrote:This is a super interesting topic, has there been any progress?
I was wondering if h264_freq wasn't (software?) locked to 250MHz we might have a chance of playing back 4k video by increasing that clock?
h264 can be overclocked (with h264_freq). However the hardware was designed for 1920x1080 and there are some cases where the hardware doesn't handle > 2K dimensions.
If you just wanted a proof of concept, then decoding 4 1080p streams may be possible, but i suspect you will hit performance and possibly memory limits.

stag019
Posts: 10
Joined: Thu Mar 20, 2014 3:58 am

Re: Raspberry Pi and 4k @ 15Hz

Wed Oct 08, 2014 4:16 am

dom wrote:If you just wanted a proof of concept, then decoding 4 1080p streams may be possible, but i suspect you will hit performance and possibly memory limits.
So I've been trying to figure out how to do something even remotely like this, but to no avail. Could you figure out some modifications to "video.c" from the "hello_video" demo that would attempt to do such a thing instead of just decoding one stream and fullscreening it?

dom
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 5140
Joined: Wed Aug 17, 2011 7:41 pm
Location: Cambridge

Re: Raspberry Pi and 4k @ 15Hz

Wed Oct 08, 2014 7:54 pm

stag019 wrote:So I've been trying to figure out how to do something even remotely like this, but to no avail. Could you figure out some modifications to "video.c" from the "hello_video" demo that would attempt to do such a thing instead of just decoding one stream and fullscreening it?
Using omxplayer may be easier. That already support the "--win" option to decode the video to a specific region. Try running 4 concurrent omxplayers with --win set to each quarter of the screen.
Set gpu_mem and overclock high...

stag019
Posts: 10
Joined: Thu Mar 20, 2014 3:58 am

Re: Raspberry Pi and 4k @ 15Hz

Thu Oct 09, 2014 1:45 am

dom wrote:Using omxplayer may be easier. That already support the "--win" option to decode the video to a specific region. Try running 4 concurrent omxplayers with --win set to each quarter of the screen.
Set gpu_mem and overclock high...
Oh, that's pretty cool. With my settings right now, it has no problem doing 2 of the BBB clips at the same time, but with 3 it seems to have problems, and it has different problems depending on the gpu_mem setting. As I mentioned before, I'm still using a 256MB Model B, but I just purchased a Model B+ and will start testing again when that arrives. I'll also try overvolting soon too. I'll post update when the time comes.
dom wrote:However the hardware was designed for 1920x1080 and there are some cases where the hardware doesn't handle > 2K dimensions.
Is this specific in the hardware, or just a software limitation?

jamesh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 19798
Joined: Sat Jul 30, 2011 7:41 pm

Re: Raspberry Pi and 4k @ 15Hz

Thu Oct 09, 2014 8:27 am

It's a HW limitation - the HW was designed or 1080p (which 6 years ago when the VC4 was being planned, was really the bleeding edge)
Principal Software Engineer at Raspberry Pi (Trading) Ltd.
Please direct all questions to the forum, I do not do support via PM.

feriso
Posts: 1
Joined: Sun Nov 09, 2014 11:33 pm

Re: Raspberry Pi and 4k @ 15Hz

Sun Nov 09, 2014 11:41 pm

Well, I've had this page bookmarked for a while now but earlier today I finally went and did it... ordered a new Sony 4K TV and I was hoping to use my Pi to display by photos for me in slideshow. Once I've got it plugged in I'll have to give it a try :D

I'll try and follow what's happening here but has anyone got any tips to start off with?

Thanks :)

ildanach
Posts: 3
Joined: Sat Nov 08, 2014 10:38 pm

Re: Raspberry Pi and 4k @ 15Hz

Mon Nov 10, 2014 12:56 am

Does this mean that the rPi will be able to run GoPro Hero4 Silver movies at 2.7k with 50FPS?

stag019
Posts: 10
Joined: Thu Mar 20, 2014 3:58 am

Re: Raspberry Pi and 4k @ 15Hz

Thu Nov 13, 2014 10:32 pm

So I know that Seiki has stupid discrepancies in EDID data not just between each model, but between the different firmware for the different models too. So I was looking online, and I found a couple of timings for some 3840x2160 resolutions in my quest to try to get better than 24Hz working (with hdmi_cvt, I can get 25Hz working, but still with those blue artifacts).

Here's some that I'm trying to test:

Code: Select all

"[email protected]"	296.75 3840 5116 5204 5500 2160 2168 2178 2250 +hsync +vsync
"[email protected]"	297.00 3840 4896 4984 5280 2160 2168 2178 2250 +hsync +vsync
And here's how I converted them to hdmi_timings:

Code: Select all

hdmi_timings=3840 0 1276 88 296 2160 0 8 10 72 0 0 0 24 0 29675000 3
hdmi_timings=3840 0 1056 88 296 2160 0 8 10 72 0 0 0 25 0 29700000 3
First, here's some random thoughts:
  • In this thread dom tends to use hdmi_timing and hdmi_timings interchangeably, which caused me a little bit of grief. He should fix those posts.
    Less important, he messed up some of the chevrons in that listing as well.
    What exactly are <v_sync_offset_a>, <v_sync_offset_b>, and <pixel_rep> for?
    For polarity, does 1 mean positive and 0 negative, or vice-versa?
Now before I get to the results of my test, I want to mention one thing. I ran

Code: Select all

cvt 1920 1080 60
on my Ubuntu machine, and got

Code: Select all

# 1920x1080 59.96 Hz (CVT 2.07M9) hsync: 67.16 kHz; pclk: 173.00 MHz
Modeline "1920x1080_60.00"  173.00  1920 2048 2248 2576  1080 1083 1088 1120 -hsync +vsync
which I converted to

Code: Select all

hdmi_timings=1920 0 128 200 328 1080 0 3 5 32 0 0 0 60 0 17300000 3
I tested this on my Raspberry Pi (trying different values for the polarities), but nothing would work (I forget what happened, but I believe I got the "Not Support" message). Could this have anything to do with it saying it's 59.96 Hz instead of exactly 60? Also, when I use

Code: Select all

hdmi_cvt 1920 1080 60
on the Raspberry Pi it works perfectly. Is there any flaws in my thought process here?

And now onto the results of my 3840x2160 hdmi_timings test. They worked... sort of. The TV reported it was in "1080p 60Hz" mode. Looking at the text on the screen (keep in mind the framebuffer was still 3840x2160), it did look like it was 3840x2160 scaled down to 1920x1080.

Is there any way that hdmi_timings sets some sort of upper limit on any of it's parameters?


Edit: And now I'm stumped again. I realized I was off by an order of magnitude in the <pixel_freq> section. Fixing that fixed my [email protected] test. However, it didn't fix the other timings at all. So I was still hoping there was some sort of stupid limit in hdmi_timings.... until I tested it with what Ubuntu gave me for

Code: Select all

cvt 3840 2160 24
and that worked perfectly. So I'm stumped. I guess I'm just gonna keep looking for all sorts of timings and keep testing them.

I'm still curious about the two questions about hdmi_timings though.

dom
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 5140
Joined: Wed Aug 17, 2011 7:41 pm
Location: Cambridge

Re: Raspberry Pi and 4k @ 15Hz

Fri Nov 14, 2014 12:39 pm

stag019 wrote: In this thread dom tends to use hdmi_timing and hdmi_timings interchangeably, which caused me a little bit of grief. He should fix those posts.
Less important, he messed up some of the chevrons in that listing as well.
Fixed.
What exactly are <v_sync_offset_a>, <v_sync_offset_b>, and <pixel_rep> for?
For polarity, does 1 mean positive and 0 negative, or vice-versa?[/list]
It may be illuminating to see the values for the standard modes. See here.
See this for info on pixel repetition.
The polarities use HDMI_NEGATIVE_SYNC=0, HDMI_POSITIVE_SYNC=1.
Is there any way that hdmi_timings sets some sort of upper limit on any of it's parameters?
Almost certainly. The pixel clock is limited to 163MHz (the limit can be increased, but you are in overclock territory - it will fail at some point).
There may be other limits on other parameters for hardware that was designed for 1080p.

jamesh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 19798
Joined: Sat Jul 30, 2011 7:41 pm

Re: Raspberry Pi and 4k @ 15Hz

Fri Nov 14, 2014 1:20 pm

ildanach wrote:Does this mean that the rPi will be able to run GoPro Hero4 Silver movies at 2.7k with 50FPS?
This thread generally is about HDMI display, rather than H264 decode. They are different things. I believe the decoder will go a bit above 1080p30, but not far IIRC.
Principal Software Engineer at Raspberry Pi (Trading) Ltd.
Please direct all questions to the forum, I do not do support via PM.

stag019
Posts: 10
Joined: Thu Mar 20, 2014 3:58 am

Re: Raspberry Pi and 4k @ 15Hz

Fri Nov 14, 2014 8:22 pm

Okay, so I tried a bunch more timings and managed to find some that I like. I was able to get 28Hz without overclocking at all. Here are the minimal settings for that (included 24Hz and 25Hz since those seem to be common frame rates for videos):

Code: Select all

disable_overscan=1

hdmi_ignore_edid=0xa5000080
hdmi_group=2
hdmi_mode=87

hdmi_timings=3840 1 48 32 80 2160 1 3 5 54 0 0 0 28 0 248140000 3
#hdmi_timings=3840 1 48 32 80 2160 1 3 5 54 0 0 0 24 0 211190000 3
#hdmi_timings=3840 1 48 32 80 2160 1 3 5 54 0 0 0 25 0 220430000 3

framebuffer_width=3840
framebuffer_height=2160
max_framebuffer_width=3840
max_framebuffer_height=2160

gpu_mem=128

hdmi_pixel_freq_limit=400000000
And with some overclocking and overvolting, I managed to get 30Hz. It requires force_turbo to be set though so that it's always running overclocked to get the screen running. However, doing this voids your warranty. Here are the settings that worked for me:

Code: Select all

##### WARNING: THIS WILL VOID YOUR WARRANTY! #####
disable_overscan=1

hdmi_ignore_edid=0xa5000080
hdmi_group=2
hdmi_mode=87
hdmi_timings=3840 1 48 32 80 2160 1 3 5 54 0 0 0 30 0 266610000 3

framebuffer_width=3840
framebuffer_height=2160
max_framebuffer_width=3840
max_framebuffer_height=2160

gpu_mem=128

hdmi_pixel_freq_limit=400000000

force_turbo=1

over_voltage=6
over_voltage_sdram=6

arm_freq=1125
core_freq=510
gpu_freq=510
sdram_freq=750

And now on to my experiments with decoding multiple 1080p streams. With my max overclock settings, I'm able to decode 3 of the Big Buck Bunny video streams simultaneously without any slowdown (maybe minimal slowdown, but it's hard to notice if it is). Unfortunately, when I try to do 4, it flickers between the video streams, showing only one at a time (though still in the right position). Also, when I say "simultaneously" I mean I have a bash script which runs each one without waiting for the other to finish, then waits for them all to finish before a "done" message appears. It would be nice if a more simultaneous method were possible.

I also wonder, if there were two Raspberry Pis doing the decoding, connected to each other via Ethernet cable, and if one of the two could be the slave and decode two or three of the streams (while having no video output capabilities so as not to slow down the processing), while the other could be the master, receiving the video stream from the slave to merge with the one or two streams it's decoding to output the final picture. How difficult would something like this be to work out? Not worth the effort?

How about 3D drawing? Even if it's only able to render a scene at a max of 1920x1080, would it be able to render a (simple) scene from 4 different angles and then composite that to the screen (like with omxplayer) to have a final 3840x2160 scene? Or would this also be just as slow as the decoding of video?

dom
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 5140
Joined: Wed Aug 17, 2011 7:41 pm
Location: Cambridge

Re: Raspberry Pi and 4k @ 15Hz

Sat Nov 15, 2014 12:37 pm

stag019 wrote: I also wonder, if there were two Raspberry Pis doing the decoding, connected to each other via Ethernet cable, and if one of the two could be the slave and decode two or three of the streams (while having no video output capabilities so as not to slow down the processing), while the other could be the master, receiving the video stream from the slave to merge with the one or two streams it's decoding to output the final picture. How difficult would something like this be to work out? Not worth the effort?
Each 1080p24 decoded video stream requires 74MB/s (~600Mbit/sec) so you won't be sending that over ethernet.
stag019 wrote: How about 3D drawing? Even if it's only able to render a scene at a max of 1920x1080, would it be able to render a (simple) scene from 4 different angles and then composite that to the screen (like with omxplayer) to have a final 3840x2160 scene? Or would this also be just as slow as the decoding of video?
There are some 2048x2048 limits in the 3D engine (e.g. for textures). I'm not sure if the 3D framebuffer has the same limit, but I'd guess it most likely does.
It may be possible to render to an offscreen buffer that is 1920x2048 and do that twice for 3840x2048, and use dispmanx to add them to the display.

epyonxero
Posts: 3
Joined: Wed Feb 05, 2014 1:06 am

Re: Raspberry Pi and 4k @ 15Hz

Tue Dec 02, 2014 8:03 pm

feriso wrote:Well, I've had this page bookmarked for a while now but earlier today I finally went and did it... ordered a new Sony 4K TV and I was hoping to use my Pi to display by photos for me in slideshow. Once I've got it plugged in I'll have to give it a try :D

I'll try and follow what's happening here but has anyone got any tips to start off with?

Thanks :)
How did it go? Im also interested in a 4K photo frame.

pankajet
Posts: 2
Joined: Mon Jan 26, 2015 8:12 pm

Re: Raspberry Pi and 4k @ 15Hz

Mon Jan 26, 2015 8:19 pm

Hello,

I am trying to play 4k video on openelec+pi (Rev B+) but it hangs immediately after video starts. I have made few changes like - frame rate, HDMI mode but result still the same. Don't have 4K TV yet but still would like to watch 4k video on 1080p support TV.

My question is : What changes required to run 4k video and output from pi is 1080p ?

Thanks in advance..

dom
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 5140
Joined: Wed Aug 17, 2011 7:41 pm
Location: Cambridge

Re: Raspberry Pi and 4k @ 15Hz

Mon Jan 26, 2015 11:02 pm

pankajet wrote: I am trying to play 4k video on openelec+pi (Rev B+) but it hangs immediately after video starts. I have made few changes like - frame rate, HDMI mode but result still the same. Don't have 4K TV yet but still would like to watch 4k video on 1080p support TV.

My question is : What changes required to run 4k video and output from pi is 1080p ?
The hardware video decoder (like most of the chip) is designed for 1920x1080 maximum.
You won't be able to play 4K video files.

User avatar
mwilliams03
Posts: 118
Joined: Mon Oct 29, 2012 2:56 pm
Contact: Website

Re: Raspberry Pi and 4k @ 15Hz

Tue Jan 27, 2015 3:45 am

I spent many hours getting 4K @ 60Hz working on my media center PC. (it has HMDI V2 )

What I know;
HDMI 1.4 does support 4k, but at very low frame rates
To increase frame rate, you can do chroma down sampling.. however you will loose picture quality

You can use the below image to see if you are getting full 4:4:4. If your are not, the bottom two lines will be hard to read

http://cdn.avsforum.com/b/b4/b4a44044_v ... 208609.png
Image
Mark -- OzzMaker.com -- Creator of PiScreen - A 3.5" TFT for the Rasspberry Pi and BerryIMU.

pankajet
Posts: 2
Joined: Mon Jan 26, 2015 8:12 pm

Re: Raspberry Pi and 4k @ 15Hz

Tue Jan 27, 2015 6:39 pm

dom wrote:
pankajet wrote: I am trying to play 4k video on openelec+pi (Rev B+) but it hangs immediately after video starts. I have made few changes like - frame rate, HDMI mode but result still the same. Don't have 4K TV yet but still would like to watch 4k video on 1080p support TV.

My question is : What changes required to run 4k video and output from pi is 1080p ?
The hardware video decoder (like most of the chip) is designed for 1920x1080 maximum.
You won't be able to play 4K video files.
I see many guys have reported that they are playing but frame rate is low. How is that possible if its chip limitation ?

stag019
Posts: 10
Joined: Thu Mar 20, 2014 3:58 am

Re: Raspberry Pi and 4k @ 15Hz

Tue Jan 27, 2015 7:22 pm

There's a difference between using a UI in 4K and playing a 4K video file. I can use Raspbian's CLI or GUI in 4K (and OpenElec's GUI), but I can't get the processor to decode a 4K video file.

magepug
Posts: 1
Joined: Fri Feb 20, 2015 1:01 am

Re: Raspberry Pi and 4k @ 15Hz

Fri Feb 20, 2015 2:15 pm

I've got a pi2 and I'm outputting 4k @ 24hz to a Samsung 40" 4k. It works fairly well. I tried the above settings to overclock and get up to 30hz, but the screen flickers on and off after a few minutes of being on. Eventually it just bombs out completly and the screen just says unsupported resolution.

My config txt... anyone know how I can get to 30hz, or even above that? I'm using the PI2 as thin client and the TV as a monitor, so actually playing 4k video isn't important to me.

Code: Select all

disable_overscan=1

# using this causes screen flickering
#hdmi_timings=3840 1 48 32 80 2160 1 3 5 54 0 0 0 30 0 266610000 3

# need to use this instead
hdmi_cvt 3840 2160 24

hdmi_ignore_edid=0xa5000080
hdmi_group=2
hdmi_mode=87
hdmi_pixel_freq_limit=400000000

framebuffer_width=3840
framebuffer_height=2160
max_framebuffer_width=3840
max_framebuffer_height=2160

arm_freq=1000
gpu_freq=510
gpu_mem=256
core_freq=500
sdram_freq=500
over_voltage=2
force_turbo=1

Return to “Graphics, sound and multimedia”

Who is online

Users browsing this forum: No registered users and 4 guests