Media player - weird behaviour

Well it works at 25fps. It's videos that are not 25fps exactly that don't play

Just trying to stop it flashing up the triangle play symbol/graphic for a brief few ms while the player loads now. Trying to get seemless transitions between videos.

I hoped toggling the arrangement visible flag would work, but it doesn't

Even though I appear to have fixed the video playing issue, I can't get rid of the play symbol flashing up. Ruins the look of the process having a giant triangle play symbol flash on the screen briefly before each video.

Tried delaying the arrangement (toggling from off to on), but that doesn't work.
If the arrangement isn't visible when calling .play, then it fails to play the video.

I can't see any other method of making the video 'not visible' for the first 300ms or so (while the symbol flashes).

Nice extension. But In my newbie opinion that means nothing... has quirks that are annoying

Thanks for the advice

This works...

You get a very brief flash of full screen white before the video starts, but it's better than a weird, grainy symbol.

Mad amount of block to play a single video

Now to be able to play 2 videos, I assume I am going to have to have 2x Players?

What should have changed compared to my version?

No.

What should have changed? Not sure what you mean.
Basically, the videos must be exactly 25fps (well in my case anyway).
I am also using the loading block to switch off the arrangement screen to hide the horrible play symbol.

I have them all working now.

Just trying to work out how to configure for multiple videos with one player.
Wish I could get rid of the white flash at the start of the video player (while it initialises), but have not managed to do that.

I have still images that are 1080x1920 captures of the video. Great quality here, but when uploaded to the phone, the quality is appalling.
I assume due to compression.

Any way around that? Maybe load the file from the phone (if at all possible)

Firsr set the source, then play the video
Taifun

Can't get past the terrible image quality. I can only assume its because the 1080x1920 image gets compressed (it's set to fill parent)

You could also try this extension:

For your image, try resizing it so that it does not have to be compressed, make it the size of your device, e.g. if viewing when device held in portrait mode, resize your image width to the device width.

Tried that. Still looks terrible. Just cannot work that out.

Anyway, for some bizarre reason, this morning the entire app doesn't work properly.
I blasts past wait touch commands and does all kind of weird things.
It was working fine last night.

I am asking too much of this software with my limits knowledge.
I can't put any more time into it.

Share the image, and the blocks/code you are using to display the image.

Have you told us about your device: make/model/android version ?

I am struggling with this and the trouble is I hate to be beaten.

This is my list of issues (apart from being newbie and not understanding the way it all works).

The standard media player shows the 'tools'. No good, I need video playback that is clean and not 'stoppable'.

So, using the PLYR extension. Great, does what I need. Except it keeps doing things I don't expect.

At the moment, it blasts past the first video and starts the second video. I can't see why it doesn't wait for PLYR1 to finish first. Annoying... It used to work until I fired it up yesterday, so something changed.

Ideally that would be one video instead of two, but I can't upload the video in one piece as its too large (and already reduced resolution)

The backpack appears broken this morning. Gone all glitchy.

Yes.. I know I don't need two instances of the PLYR for 2 videos, but I have not worked that out yet.

The sequence starts with an image and waits for the screen press.
That image touch turns off that arrangement and image and opens the video arrangement.

I am having all kinds of issues with scaling and quality. All the videos and images are 1080 x 1920. All video are now 25fps as that messes up the PLYR if not exact.

But, fit to screen, percentages, fill parent etc.... none of them work well. My images are distorted and change from one section to the next.

Currently, using percentage works best, but that won't work well when used on a different device (Curerntly an S22+)

I thought of binning images (because the compressed images are terrible) and pausing the video after one frame (if possible) and waiting there for input.
But then how do you tell when someone has touched the video screen?

The final issue is touchscreen option selection. When the video ends, it loads an image in Canvas which is the last frame of the video that has the choices.

Canvas then sends you off to the next part of the story depending on where you touched the screen.
The Background Canvas image is also terrible.

Tried uploading various resolutions of images. None of them work very well.

Its a horrible mess now. It just not viable on this platform with my (useless) skill level

Use only 1 player and your issues of a second player starting while the first still has not finished are gone

Don't try to fix everything in one step... do it step by step... start with using only one player

Taifun

I don't yet know how to use one player.... hence I used 2.
I have been going step by step, but for some reason it randomly broke and odd issues keep popping up.

My biggest issue by far is the random quality and sizes of the media. Ideally 'Fill parent' would be used for everything, but that just doesn't work.

Currently look at other possible options. I just don't think I will ever get this working

Use 1 player
Set the first source, then start playing
If player finished, set the secomd source and start playing
Like this you can use 1 player to play n files, no need to have a separate player for each file

And generally it would help very much to learn some basics...

A very good way to learn App Inventor is to read the free Inventor's Manual here in the AI2 free online eBook App Inventor 2 Book: Create Your Own Android Apps ... the links are at the bottom of the Web page. The book 'teaches' users how to program with AI2 blocks.
There is a free programming course here Course In A Box and the aia files for the projects in the book are here: App Inventor 2 Book: Create Your Own Android Apps
How to do a lot of basic things with App Inventor are described here: How do you...? .

Also do the tutorials Our Tutorials! to learn the basics of App Inventor, then try something and follow the Top 5 Tips: How to learn App Inventor

Taifun


Trying to push the limits! Snippets, Tutorials and Extensions from Pura Vida Apps by icon24 Taifun.

I have used MIT a fair bit before.
But... its the images and scaling that I think will end this anyway.
From what I understand, there is an ongoing issue with the quality of the Canvas background image for starters.

Anyway, thanks for the advice

Again: don't try to fix everything at the same time
This thread is about media player

Create a separate thread for each issue
And create an example project as simple as possible to experiment and to find a solution for each issue
Then put everything together in your main project

How many times did you already anounce this, but you are still here?

Taifun

Thanks for all the advice.
I had it working, which is why I got as far as the Canvas part. Then the video stopped working.

I have purchased a 27" touchscreen and a BrightSign media player. Already got that working.

Not going down the tablet with an app avenue. Too much hassle.

To play multiple videos in a row with one VideoPlayer, see this example:


VideoPlayer_withoutControls_2.aia (2.4 MB)


Post your aia (or send it to me via PM).

Thank you for that example. I had worked out the single usage of the Plyr extension but your example is slightly neater than mine.

But, it does not get me past all the other shortfalls of various parts of the app that I cannot seem to get past.

The screen still transitions horribly between videos because of the play symbol issue
The images are garbage no matter what resolution or format I upload or set the screen to.
The Canvas touch image is terrible.

I constantly have to exit MIT App inventor entirely and come back in because it shows red errors that don't exist and won't clear. The only way to clear them is to log out and log back in.

The Backpack this morning won't let me pick up blocks of code that are set to disabled. So they are stuck in the backpack and I cannot retrieve them.

Looking at it now, there is a yellow warning but there is nothing wrong. A reboot cleared that.
Then every 20 minutes... 'Oops, we tripped on a bug' comes up.

Sticking with the touchscreen and media player.
This software is just a bit too rough around the edges for my needs (probably due to me, but life is too short to put any more time into it)

My test app runs smoothly on all Android versions, with no loss of quality or transition issues between video clips (and, as requested, without any controls). Period.

Whatever your concern or problem may be, it remains in the dark...
We've obviously been talking past each other from the start in these 50 posts. What a waste of time.

I think we should close this topic (inconclusively).