Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-2-2
Commits
c637ea54
Commit
c637ea54
authored
May 02, 2008
by
Jean-Baptiste Kempf
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Small fix for PJS to remove "".
parent
971d6b76
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
3 deletions
+7
-3
modules/demux/subtitle.c
modules/demux/subtitle.c
+7
-3
No files found.
modules/demux/subtitle.c
View file @
c637ea54
...
...
@@ -56,12 +56,13 @@ static void Close( vlc_object_t *p_this );
#define SUB_TYPE_LONGTEXT \
N_("Force the subtiles format. Valid values are : \"microdvd\", " \
"\"subrip\", \"ssa1\", \"ssa2-4\", \"ass\", \"vplayer\" " \
"\"sami\", \"dvdsubtitle\", \"mpl2\" and \"auto\" (meaning autodetection, this " \
"\"sami\", \"dvdsubtitle\", \"mpl2\"
, \"aqt\", \"pjs\"
and \"auto\" (meaning autodetection, this " \
"should always work).")
static
const
char
*
ppsz_sub_type
[]
=
{
"auto"
,
"microdvd"
,
"subrip"
,
"subviewer"
,
"ssa1"
,
"ssa2-4"
,
"ass"
,
"vplayer"
,
"sami"
,
"dvdsubtitle"
,
"mpl2"
"ssa2-4"
,
"ass"
,
"vplayer"
,
"sami"
,
"dvdsubtitle"
,
"mpl2"
,
"aqt"
,
"pjs"
};
vlc_module_begin
();
...
...
@@ -1309,17 +1310,20 @@ static int ParsePJS( demux_t *p_demux, subtitle_t *p_subtitle, int i_idx )
psz_text
=
malloc
(
strlen
(
s
)
+
1
);
/* Data Lines */
if
(
sscanf
(
s
,
"%d,%d,%[^
\n\r
]"
,
&
t1
,
&
t2
,
psz_text
)
==
3
)
if
(
sscanf
(
s
,
"%d,%d,
\"
%[^
\n\r
]"
,
&
t1
,
&
t2
,
psz_text
)
==
3
)
{
/* 1/10th of second ? Frame based ? FIXME */
p_subtitle
->
i_start
=
10
*
t1
;
p_subtitle
->
i_stop
=
10
*
t2
;
/* Remove latest " */
psz_text
[
strlen
(
psz_text
)
-
1
]
=
'\
0
'
;
break
;
}
free
(
psz_text
);
}
p_subtitle
->
psz_text
=
psz_text
;
msg_Dbg
(
p_demux
,
"%s"
,
psz_text
);
return
VLC_SUCCESS
;
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment