Kodi Community Forum
AMLogic - try and fix your Audio and Video playback problems. - Printable Version

Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: General Support (https://forum.kodi.tv/forumdisplay.php?fid=111)
+---- Forum: Android (https://forum.kodi.tv/forumdisplay.php?fid=164)
---- Thread: AMLogic - try and fix your Audio and Video playback problems. (/showthread.php?tid=229310)

Pages: 1 2 3 4 5 6 7 8 9 10 11


RE: AMLogic - try and fix your Audio and Video playback problems. - WimKl - 2016-03-11

Hi,

I guess I'm not the only one left with a CRT.........

Put this in a file and (if you want) have it start at autoboot (not if you have to change between HDMI and AV everytime):

# Fix for AV output on S89-H with Kodi 16
# DENY Kodi superuser access!!!
# If you want it to autostart at boot, use smanager or init.d
# With this file AV works correct, HDMI does NOT!
# Reboot after install to have affect

#!/system/bin/sh

#allow all changes for xbmc (this is instead of giving supersu access to xbmc) but deny access for /sys/class/video/axis
chmod 666 /dev/amstream*
chmod 444 /sys/class/video/axis
chmod 666 /sys/class/video/screen_mode
chmod 666 /sys/class/video/disable_video
chmod 666 /sys/class/tsync/pts_pcrscr
chmod 666 /sys/class/audiodsp/digital_raw
#chmod 666 /sys/class/ppmgr/ppmgr_3d_mode
chmod 666 /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
chmod 666 /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
chmod 666 /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
chmod 666 /dev/amvideo
# addition below for Kodi 16
chmod 444 /sys/class/display/mode

Good luck,

Wim


RE: AMLogic - try and fix your Audio and Video playback problems. - Dr_IT - 2016-03-11

Hi Wim,

Thanks for your help. I tried your script, but unfortunately did not make a difference Sad
After some play with the 444 files, i did find that is not only screen_mode which makes text unsharp or does play video right, but also the axis file is responsible. So if one of them is read only, text is sharp, but video does not play correctly. And if both of them are writable (666), video plays fine, but text is unsharp in AV mode.

I also played with the acceleration. Nothing works for the unsharp issue, but enabling only amcodec (together with writable permissions on the 2 files) will play video slightly different. Now not black screen with only sound, but a stuttering video (probably because of no acceleration?).

What i was thinking is when XBMC 13.2 does work correctly by setting 666 permissions to all those files and Kodi 16 does not with exactly the same permissions, problem probably lies in Kodi code and not file rights anymore?

Mark


RE: AMLogic - try and fix your Audio and Video playback problems. - WimKl - 2016-03-12

Hi Mark,

Oeps, sorry. I posted very quick yesterday, but now I remember i too had a problem with the script, that's why I revertred back to Kodi 15.2. I'm very sorry.

The above script without the last line DOES work good with Kodi 15.2. So something has changed in 16. I'm not sure what yet and I have very limited time to test. I don't know if one of the developers lknows, it would make it a lot easier. I spent a lot of hours making this script)..

Problem is that Kodi code changes file contents and for amlogic it creates a problem, because amlogic (that's what I think) hasn't set the permissions of some files to read-only and they should have. That's why we have to do it manually.If we know which files to set, it's a piece of cake. Figuring out which files is the problem.

If I find out before you do, I will let you know here, I hope you do likewise. Good luck.

Wim


RE: AMLogic - try and fix your Audio and Video playback problems. - Brakiss - 2016-04-19

ok guys could really use some help. Gbox MX2 official box, chmod init script running and on kodi 16. whenever i play a 59 fps video, starts out fine then video slows and i get way out of sync with no adjustment. i have searched but nothing i have found has been helpful. anyone have any pointers for me?


RE: AMLogic - try and fix your Audio and Video playback problems. - tornicade - 2016-04-19

(2016-04-19, 04:45)Brakiss Wrote: ok guys could really use some help. Gbox MX2 official box, chmod init script running and on kodi 16. whenever i play a 59 fps video, starts out fine then video slows and i get way out of sync with no adjustment. i have searched but nothing i have found has been helpful. anyone have any pointers for me?

Try using this for testing
http://kodi.wiki/view/HOW-TO:Use_external_players_on_Android

You can specify paparameters when to use the external player.

first though you probably wanna check your playback settings and see if the player is matching refresh rate.

and of course check your accelerators try it with the amlogic accekeratr only. then the mediasource codec only.see if there is any difference.

You can debug your attempts and upload it


RE: AMLogic - try and fix your Audio and Video playback problems. - spon901 - 2016-05-12

I have an Android tablet with HDMI port and a resolution of 1024x600 (ONDA V711 dual processor clone)
I fixed amlogic permissions ( the ones that old versions of kodi fix) in boot.img
system("su -c chmod 666 /dev/amvideo");
system("su -c chmod 666 /dev/amstream*");
system("su -c chmod 666 /sys/class/video/axis");
system("su -c chmod 666 /sys/class/video/screen_mode");
system("su -c chmod 666 /sys/class/video/disable_video");
system("su -c chmod 666 /sys/class/tsync/pts_pcrscr");
system("su -c chmod 666 /sys/class/audiodsp/digital_raw");
system("su -c chmod 666 /sys/class/ppmgr/ppmgr_3d_mode");
system("su -c chmod 666 /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq");
system("su -c chmod 666 /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq");
system("su -c chmod 666 /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor");
I activate the HDMI output, invalidate the LCD display and set the resolution of HDMI to 1920x1080p through HDMISwitch application that came with the official firmware.
First issue: Somehow solved

Without changing the source file of the kodi, all the versions before and including 14.05beta produced no video but with audio. All the versions after and including 14.2 final once started produced black screen, ( nothing is present on screen), and the only way to revive the tablet is resetting it through reset switch. I did not test versions between 14.05beta and 14.2.
I discovered that on the versions prior 14.05beta when the movie starts it is written 0 0 -1 -1 to /sys/class/video/axis. No matter how many movies I started situtation is same. But if I manually change the value from /sys/class/video/axis. through adb with kodi started, , without restarting kodi, all the video started after the change will be ok, including the one thet is eventually playing, having both sound and video. If I restart kodi again I have the same issue.
I discovered that in function AMLCodec::SetVideoRect SrcRect, and DestRect have proper values , but by some reasons, m_display_rect is 0 and as result dst_rect is 0 and therefore 0 0 -1 -1 is written in axis (this only happened before i manually alter axis, after alteration, m_diplay_rect is corect. I "fixed" this by checking in the function if m_display_rect is 0 case in which I made it equal to gui, with have proper values. I also copy and adapt versions from trunk of the following files :
windowing/egl/EGLNativeTypeAmlogic.cpp
windowing/egl/EGLNativeTypeAmlogic.h
windowing/egl/EGLWrapper.cpp
utils/AMLUtils.cpp
utils/AMLUtils.h
(Only copying the files without altering SetVideoRect does not help)

Second issue Not solved
Even the resolution is set up at 1920x1080p, and the movie is full HD (1920x1080) in axis is written 0 0 1024 552 (552 and not 600 because of android softbuttons) the image is on whole screen. but the image is not so sharp, therefore is like movie is played at 1024 x 552 and upscaled to the TV at 1920x1080. I played same video with diferent video player (movieplayer) , and picture is more clear, so the tablet can produce full HD output through HDMI. If I manually put in /sys/class/video/axis 0 0 1920 1080. then only top left part of the movie is shown on screen. /sys/class/display/axis shows 0 0 1920 1080 0 0 32 32
Are maybe needed other permission to be set? This issue is probably similar to zoom issue that is signalled in another thread which is now closed. So probably the Zoom issue was "fixed" by reducing resolution to the native one of the tablet/box. That's probably why some said the zoom issue is not present if the resolution to the TV is set at 720p. That is because maybe that resolution is more close to the native one, so the zoom effect is much diminuated or no longer exists( many tablet offer vertical native resolutions of 800

Please help


RE: AMLogic - try and fix your Audio and Video playback problems. - spon901 - 2016-05-13

MoviePlayer seems to use different approach to play videos. When it started it plays at FULL HD quality, so the movie is not upscaled. I tested using the 1080 test movie from this forum, and it preserve all details. It plays also full screen by hidingt android soft buttons, and what is strange when it plays /sys/class/video/axis is 0 0 -1 -1 . In kodi when I put those values the video is blank. It use hardware acceleration for sure, because the video plays without shuttering thing that cannot happened using software acceleration, the processor not being so powerfull.


RE: AMLogic - try and fix your Audio and Video playback problems. - prof7bit - 2016-07-22

I have made a fork of the well known XBMCLauncher that
will apply chmod 666 /sys/class/display/mode
immediately before starting. This works better
than waiting for the universalinit app to do its thing
before manually starting Kodi, now I can have it started
automatically and immediately again.

This works on my MXQ Pro 4k box that came already rooted
but has wrong permission on /sys/class/display/mode

It is currently only tested on this particular device with
this chipset. The ROM needs a working su (which my device
had already on it when I bought it).

apk and source code:
https://github.com/prof7bit/XBMCLauncher/releases


RE: AMLogic - try and fix your Audio and Video playback problems. - Iadalazzhr - 2016-09-27

I have a m8s+ box, which has the amcodec etc in having a problem I can't solve and this seemed like the right place, certain video files will just freeze my system, only way out is to pull the plug and restart. It's not hevc or extra large files specifically, just seems random. I've tried disabling various accelerator settings and audio settings but nothing seems to work... Any ideas? I'll have the list of files, click one, it says Buffering then screen goes black like it's going to play but then the file screen comes back on frozen...


RE: AMLogic - try and fix your Audio and Video playback problems. - wrxtasy - 2016-10-07

@netaccs,

You post has been transferred here to the appropriate Android section:

- Troubleshooting Beelink GT1 S912 Firmware:


netaccs Wrote:I just try to find some fix about my problem.
I don't wanna use mxplayer only.
I hope so that some plugin like libreelec will fix the issue.
In the forum I read about some tricky with echo
echo 1 >/sys/class/audiodsp/audio_samesource
echo 2 >/sys/class/audiodsp/digital_codec
I will try it and paste the results.

15minutes no problem with all ac3 files using this one
echo 2 >/sys/class/audiodsp/digital_codec
or using ES File Explorer, edit the file /sys/class/audiodsp/digital_codec
and change 0 to 2.
Note that evey time you reboot the device it will be set to 0, so I have
to find some script to make automatic.



RE: AMLogic - try and fix your Audio and Video playback problems. - musicadi - 2016-10-21

Hello,

Should this fix HD video playback problems on my Wetek Core?!

Although, Samba has 22Mb up/down bandwidth, Kodi is unable to normally play back any HD video.

I tried dozens of settings, inside Kodi, buffer settings in advancedsettings.xml... nothing works

Thank you!


RE: AMLogic - try and fix your Audio and Video playback problems. - wrxtasy - 2016-10-21

You don't use Kodi on the WeTek Core - use the customised, optimised for Core - Wetek Media Player App (Kodi Jarvis).

HD Video playback does work on the Core, really you should be seeking help in the WeTek forums as that is what they are specifically there for with WeTek devices. I do not recommend using regular Kodi.

Sounds more like you have a networking issue rather than Kodi playback problem.. See the Wetek forums for help.


RE: AMLogic - try and fix your Audio and Video playback problems. - musicadi - 2016-10-21

Thank you for your answer!

I already have a thread on the Wetek forums, but they didn't mention that I had to use the Wetek Media Player Smile Kodi is even preinstalled in the OS and has its own "tile"... that kind of seems useless then.

I don't really like being "bound" to OS updates, that's why I haven't even tried to use the Wetek player. I'll give it a try though and see what happens.

Like I said, there is no network issue. I tested the Samba service from within the Wetek Core (WiFi Speed Test app) and the bandwidth is 22 Mbps

Anyway, I will keep this in the Wetek forums then Smile

Thanks!


RE: AMLogic - try and fix your Audio and Video playback problems. - Martijn - 2016-10-21

The upcoming firmware should be just fine for regular kodi


RE: AMLogic - try and fix your Audio and Video playback problems. - musicadi - 2016-10-22

(2016-10-21, 12:26)wrxtasy Wrote: You don't use Kodi on the WeTek Core - use the customised, optimised for Core - Wetek Media Player App (Kodi Jarvis).

HD Video playback does work on the Core, really you should be seeking help in the WeTek forums as that is what they are specifically there for with WeTek devices. I do not recommend using regular Kodi.

Sounds more like you have a networking issue rather than Kodi playback problem.. See the Wetek forums for help.

Just as an update. The exact same thing is happening with Wetek Media Player.

P.S. With OpenELEC, playback of the same file under the same conditions is OK


This forum uses Lukasz Tkacz MyBB addons.