Jump to content


Photo

Openpli-5 (still next master)


  • Please log in to reply
1177 replies to this topic

Re: Openpli-5 (still next master) #361 christophecvr

  • Senior Member
  • 3,131 posts

+140
Excellent

Posted 7 June 2016 - 15:48

@littlesat ,

 

Guess You mean that the resulting code lines :

		/* required if previous subtitle was external or new one is back to external */
		if (m_change_aktif_subtitle == 1 || m_change_aktif_subtitle == 2)
		{
			if (m_change_aktif_subtitle == 1)
			{
				eDebug("[eServiceMP3] Switch back/restart external subtittle");
				pts_t ppos = 0;
				if (getPlayPosition(ppos) >= 0)
				{
					// seek flush
					seekTo(ppos);
				}
				m_change_aktif_subtitle = 0;
			}
			else if (m_change_aktif_subtitle == 2)
			{
				eDebug("[eServiceMP3] switch to internal subtitle comming from external subtitle.");
				m_change_aktif_subtitle = 3;
			}
			return;
		}

should become :

		if (m_change_aktif_subtitle == 1)
		{
			eDebug("[eServiceMP3] Switch back/restart external subtittle");
			pts_t ppos = 0;
			if (getPlayPosition(ppos) >= 0)
			{
				// seek flush
				seekTo(ppos);
			}
			m_change_aktif_subtitle = 0;
		}
		else if (m_change_aktif_subtitle == 2)
		{
			eDebug("[eServiceMP3] switch to internal subtitle comming from external subtitle.");
			m_change_aktif_subtitle = 3;
		}
		return;

That will not work since we always will have a return and never any subtitle.

 

 

Or what do You mean ?



Re: Openpli-5 (still next master) #362 littlesat

  • PLi® Core member
  • 56,965 posts

+695
Excellent

Posted 7 June 2016 - 15:58

Good point...

 

But then put the return inside the if and else if.... (so we have two returns...)

 

But I agree this is subject for discussion. Different coders could have a different meaning here... ;)...

 

I also like to have descriptions for the 0,1,2,3 conditions. This makes the code more readable -or- event self explainable as you need to describe these conditions in your code (e.g. with a enum thing).

Sorry for bothering you.... as we just try to 'tune' the code the best as we can get...


Edited by littlesat, 7 June 2016 - 15:59.

WaveFrontier 28.2E | 23.5E | 19.2E | 16E | 13E | 10/9E | 7E | 5E | 1W | 4/5W | 15W


Re: Openpli-5 (still next master) #363 christophecvr

  • Senior Member
  • 3,131 posts

+140
Excellent

Posted 7 June 2016 - 16:47

@littlesat ,

 

Yes indeed initiatlly the code was build step by step. And indeed that is why you find the first if(blablab || blabla) . An yes I thaught about to remove that line but :

First like I said the return must be relocated an twice one in the if and a second time in the if else.

 

Second the code is supposed to be for next-master only which is not a beta but experimental I would like to say alpha phase .. then it would not take to long before we move on to pli5 ;)

 

However based on more testers when it's pushed to next-master will give a better (wider) important testing base which I do find very important for such things.

Based on the result off testing quit possible that extra changes are needed.

 

After that all tests are done and it is find ok, Then I find it indeed very useful to add a enumeration in the servicemp3.h file for the parameter I added :

int m_change_aktif_subtitle;

This will make it a lot easier to read the code by others and certainly in time when changes must be done.



Re: Openpli-5 (still next master) #364 betacentauri

  • PLi® Core member
  • 7,185 posts

+323
Excellent

Posted 7 June 2016 - 18:30

aktif? What is it? Dutch? I guess m_change_current_subtitle is better.


Xtrend ET-9200, ET-8000, ET-10000, OpenPliPC on Ubuntu 12.04

Re: Openpli-5 (still next master) #365 christophecvr

  • Senior Member
  • 3,131 posts

+140
Excellent

Posted 7 June 2016 - 19:14

aktif? What is it? Dutch? I guess m_change_current_subtitle is better.

I do agree that actually aktif is not dutch neighter english . and yes this could and should be improved. But before it is more important that it is all tested by much more persons then me and much more stb's then my two I have one duo2 and one dm8000.

 

next-master is not published so it would be good the push it there so perhaps we have a much bigger testing base with the own self builders. This is really required for such changes.

 

p.s. I really await results of users and would not be surpised to have some unexpected bad ones. Just cause actually I'm so what shure that the way of working wit the

m_subtitle_sync_timer->stop();
m_subtitle_sync_timer->start(1,true) /*or*/ (ext_timer, true)

//is wrong on it and not required since with gst-1.0 the sub is in sink whit playbin, whic could not be done in gst-0.10.

The point is that we inherit stuff made for the old buggy complete deprecated 0.10 gst code. And this timer is a hack cause gst-0.10 code was so buggy.



Re: Openpli-5 (still next master) #366 Panther-6

  • Senior Member
  • 66 posts

+2
Neutral

Posted 8 June 2016 - 08:45

When can I test OpenPli-5 on my VU+ Solo SE V2? You said, it will be before summer this year. The summer begins already in 2 weeks...


VU+ Uno 4K

Edision OS mini


Re: Openpli-5 (still next master) #367 WanWizard

  • PLi® Core member
  • 69,928 posts

+1,788
Excellent

Posted 8 June 2016 - 11:32

We're still aiming for that.

 

Summer ends in 15 weeks, so I'd say before then. ;)


Currently in use: VU+ Duo 4K (2xFBC S2), VU+ Solo 4K (1xFBC S2), uClan Usytm 4K Ultimate (S2+T2), Octagon SF8008 (S2+T2), Zgemma H9.2H (S2+T2)

Due to my bad health, I will not be very active at times and may be slow to respond. I will not read the forum or PM on a regular basis.

Many answers to your question can be found in our new and improved wiki.


Re: Openpli-5 (still next master) #368 Erik Slagter

  • PLi® Core member
  • 46,969 posts

+541
Excellent

Posted 8 June 2016 - 14:46

cvr: newline is also whitespace and it also gets removed if you choose "reformat".


* Wavefrontier T90 with 28E/23E/19E/13E via SCR switches 2 x 2 x 6 user bands
I don't read PM -> if you have something to ask or to report, do it in the forum so others can benefit. I don't take freelance jobs.
Ik lees geen PM -> als je iets te vragen of te melden hebt, doe het op het forum, zodat anderen er ook wat aan hebben.


Re: Openpli-5 (still next master) #369 christophecvr

  • Senior Member
  • 3,131 posts

+140
Excellent

Posted 8 June 2016 - 15:09

Well a can't find any reformat for a c++ std::string .

 

code is

#if GST_VERSION_MAJOR < 1
				std::string line((const char*)GST_BUFFER_DATA(buffer), len);
#else
				std::string line((const char*)map.data, len);
#endif
				/* some media muxers do add an extra new line at the end off a muxed/reencoded srt to ssa codec
					yes that's a bug but looks like a lot off encoders do it now (ffmpeg bug ?) */
				if (!line.empty() && line[line.length()-1] == '\n')
					line.erase(line.length()-1);
				eLog(4, "[eServiceMP3] got new text subtitle @ buf_pos = %lld ns (in pts=%lld), dur=%lld: '%s' ", buf_pos, buf_pos/11111, duration_ns, line.c_str());
 
				uint32_t start_ms = ((buf_pos / 1000000ULL) * convert_fps) + (delay / 90);
				uint32_t end_ms = start_ms + (duration_ns / 1000000ULL);
				m_subtitle_pages.insert(subtitle_pages_map_pair_t(end_ms, subtitle_page_t(start_ms, end_ms, line)));

the std::line come from the buffer (and it's a bug from handbrake but there are more progam who makes this error) who put and 200A  extra to the end off a subtitle. I wel filed an issue report off that to handbrake that's shure. But this bug is there already since long and not the (best way generaly said is to correct the string by stripping off the \n that must be done other wise whe do have a blank line. in cpp there are more ways but the best is by using erase last char if it's a \n <0x0A>  .



Re: Openpli-5 (still next master) #370 Panther-6

  • Senior Member
  • 66 posts

+2
Neutral

Posted 9 June 2016 - 09:14

We're still aiming for that.

 

Summer ends in 15 weeks, so I'd say before then. ;)

 

I can not wait so long. Please make OpenPli-5 ready in the next days, max. one week. Thank you :P


VU+ Uno 4K

Edision OS mini


Re: Openpli-5 (still next master) #371 hemertje

  • Forum Moderator
    PLi® Core member
  • 33,500 posts

+118
Excellent

Posted 9 June 2016 - 09:51

You have too
Remember it's a hobby no work

on the Glassfibre 1GB DVB-C...


Re: Openpli-5 (still next master) #372 WanWizard

  • PLi® Core member
  • 69,928 posts

+1,788
Excellent

Posted 9 June 2016 - 11:23

I can not wait so long. Please make OpenPli-5 ready in the next days, max. one week. Thank you :P

 

I can be clear about that: that is not going to happen. There are external depencies that have to be worked on first, my most optimistic guess whould be "sometime July".


Currently in use: VU+ Duo 4K (2xFBC S2), VU+ Solo 4K (1xFBC S2), uClan Usytm 4K Ultimate (S2+T2), Octagon SF8008 (S2+T2), Zgemma H9.2H (S2+T2)

Due to my bad health, I will not be very active at times and may be slow to respond. I will not read the forum or PM on a regular basis.

Many answers to your question can be found in our new and improved wiki.


Re: Openpli-5 (still next master) #373 malakudi

  • Senior Member
  • 1,449 posts

+69
Good

Posted 9 June 2016 - 14:39

We could skip OpenPLi-5 and release OpenPLI 16 instead! Indicating the year of the release, like Ubuntu etc.



Re: Openpli-5 (still next master) #374 vasilich07

  • Senior Member
  • 155 posts

+4
Neutral

Posted 9 June 2016 - 14:48

We could skip OpenPLi-5 and release OpenPLI 16 instead! Indicating the year of the release, like Ubuntu etc.

Create at least some new release ;) 


GI ET11000,Vu+DUO2 - 4W-90E Supral 120 (motor Stab  HH 120), 36Е- satellite antenna Nokia - 90

 xtrend ET9000 - Tests without a permanent connection


Re: Openpli-5 (still next master) #375 Erik Slagter

  • PLi® Core member
  • 46,969 posts

+541
Excellent

Posted 9 June 2016 - 16:29

@cvr: the reformatting takes place at another level, it's not in that part of the code. Just try it.


* Wavefrontier T90 with 28E/23E/19E/13E via SCR switches 2 x 2 x 6 user bands
I don't read PM -> if you have something to ask or to report, do it in the forum so others can benefit. I don't take freelance jobs.
Ik lees geen PM -> als je iets te vragen of te melden hebt, doe het op het forum, zodat anderen er ook wat aan hebben.


Re: Openpli-5 (still next master) #376 christophecvr

  • Senior Member
  • 3,131 posts

+140
Excellent

Posted 10 June 2016 - 20:43

@cvr: the reformatting takes place at another level, it's not in that part of the code. Just try it.

Where and how reformat just does not exist in c and c++

 

basically for a std:string in c++ spaces and new lines are valid string chars where they are in string does not mather.

 

Point is here that for a ssa codec unfortunately the '\N' char is an allowed char but it is not in c or c ++. So our subsink just makes from the char into the ssa codec an 200A (don't ask me why). If I patch the handbrake to use \n instead off \N the media runs perfect by us. Point is that that codec may have \N.

 

So the original codec line into ssa is then

Dialogue: Marked=0,0:00:17.62,0:00:22.76,Default,,0000,0000,0000,,LIGUSTERLAAN
Dialogue: Marked=0,0:01:18.39,0:01:23.22,Default,,0000,0000,0000,,Ik had kunnen weten dat u hier\nwas, professor Anderling .

Will give : out (I adapted for the test the debug output in servicemp3)

<119483.600> [eServiceMP3] ** investigate string ** [BEGIN]LIGUSTERLAAN[END]
HEX OUT : 4C494755535445524C41414E00

<119544.379> [eServiceMP3] ** investigate string ** [BEGIN]Ik had kunnen weten dat u hier 
was, professor Anderling .[END]
HEX OUT : 496B20686164206B756E6E656E20776574656E2064617420752068696572200A7761732C2070726F666573736F7220416E6465726C696E67202E00

That is perfect.

 

But handbrake uses \N now (and this is allowed by that codec)

 

codec :

Dialogue: Marked=0,0:00:17.62,0:00:22.76,Default,,0000,0000,0000,,LIGUSTERLAAN\NDialogue: Marked=0,0:01:18.39,0:01:23.22,Default,,0000,0000,0000,,Ik had kunnen weten dat u hier\Nwas, professor Anderling .\N

the pulled puffer by us is then :

<119483.600> [eServiceMP3] ** investigate string ** [BEGIN]LIGUSTERLAAN 
[END]
HEX OUT : 4C494755535445524C41414E200A00
<119544.379> [eServiceMP3] ** investigate string ** [BEGIN]Ik had kunnen weten dat u hier 
was, professor Anderling . 
[END]
HEX OUT : 496B20686164206B756E6E656E20776574656E2064617420752068696572200A7761732C2070726F666573736F7220416E6465726C696E67202E200A00

So in despite that the codec does use an allowed \N it does not work by us.



Re: Openpli-5 (still next master) #377 golfdiesel

  • Senior Member
  • 448 posts

+10
Neutral

Posted 10 June 2016 - 23:03

We're still aiming for that.

Summer ends in 15 weeks, so I'd say before then. ;)


I can not wait so long. Please make OpenPli-5 ready in the next days, max. one week. Thank you :P
you know that the guys behind the screens are doing this as a hobby? It is ready when it is ready and when it is ready it will be released.

Re: Openpli-5 (still next master) #378 christophecvr

  • Senior Member
  • 3,131 posts

+140
Excellent

Posted 10 June 2016 - 23:56

Here the ssa codec patch for ssa codec type made with \N as line retrun instead off \n.

 

This patch is for e2 master.

 

 

Attached Files



Re: Openpli-5 (still next master) #379 littlesat

  • PLi® Core member
  • 56,965 posts

+695
Excellent

Posted 11 June 2016 - 07:16

I'm doubting if we shoild domthat as this is in fact a bug in the source... This should be solved at handbrake. Also vlc should habe issues with that extra space!

WaveFrontier 28.2E | 23.5E | 19.2E | 16E | 13E | 10/9E | 7E | 5E | 1W | 4/5W | 15W


Re: Openpli-5 (still next master) #380 Erik Slagter

  • PLi® Core member
  • 46,969 posts

+541
Excellent

Posted 11 June 2016 - 08:59

cvr, you are completely missing the point. The reformatting of the text is done inside the text renderer of enigma. It has nothing to do with either C or C++ or Python. It's a flag you can enable or disable while requesting the text to be rendered.


* Wavefrontier T90 with 28E/23E/19E/13E via SCR switches 2 x 2 x 6 user bands
I don't read PM -> if you have something to ask or to report, do it in the forum so others can benefit. I don't take freelance jobs.
Ik lees geen PM -> als je iets te vragen of te melden hebt, doe het op het forum, zodat anderen er ook wat aan hebben.



29 user(s) are reading this topic

0 members, 28 guests, 0 anonymous users


    Facebook (1)