Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
VLC
Manage
Activity
Members
Labels
Plan
Issues
4k
Issue boards
Milestones
Code
Merge requests
455
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Analyze
Contributor analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
VideoLAN
VLC
Commits
bee4c192
Commit
bee4c192
authored
3 years ago
by
François Cartegnie
Committed by
Rémi Denis-Courmont
3 years ago
Browse files
Options
Downloads
Patches
Plain Diff
codec: jpeg: write orientation
parent
89635373
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!1364
codec: png/jpeg: read & write xmp orientation
Pipeline
#188506
passed with stages
Stage:
Stage:
in 55 minutes and 57 seconds
Changes
1
Pipelines
3
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
modules/codec/jpeg.c
+15
-0
15 additions, 0 deletions
modules/codec/jpeg.c
with
15 additions
and
0 deletions
modules/codec/jpeg.c
+
15
−
0
View file @
bee4c192
...
...
@@ -691,6 +691,21 @@ static block_t *EncodeBlock(encoder_t *p_enc, picture_t *p_pic)
jpeg_start_compress
(
&
p_sys
->
p_jpeg
,
TRUE
);
unsigned
char
exif
[]
=
"Exif
\x00\x00
"
"
\x4d\x4d\x00\x2a
"
/* TIFF BE header */
"
\x00\x00\x00\x08
"
/* IFD0 offset */
"
\x00\x01
"
/* IFD0 tags count */
"
\x01\x12
"
/* tagtype */
"
\x00\x03
"
/* value type (x03 == short) */
"
\x00\x00\x00\x01
"
/* value count */
"
\xFF\xFF\x00\x00
"
/* value if <= 4 bytes or value offset */
"
\x00\x00\x00\x00
"
/* 0 last IFD */
"
\x00\x00\x00\x00
"
/* 0 last IFD offset */
;
exif
[
24
]
=
0x00
;
exif
[
25
]
=
ORIENT_TO_EXIF
(
p_pic
->
format
.
orientation
);
jpeg_write_marker
(
&
p_sys
->
p_jpeg
,
JPEG_APP0
+
1
,
exif
,
sizeof
(
exif
)
-
1
);
/* Encode picture */
p_row_pointers
=
vlc_alloc
(
p_pic
->
i_planes
,
sizeof
(
JSAMPARRAY
));
if
(
p_row_pointers
==
NULL
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment