MM-14030 Add format and frame count to image metadata (#10757)
* MM-14030 Add initial CountFrames * MM-14030 Add format and frame count to image metadata * Fix tests and stop using image dimensions from OpenGraph * Fix copyright header * Move license to NOTICE.txt
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
9a9d5d4081
Коммит
e50b642e43
@@ -31,6 +31,12 @@ type PostMetadata struct {
|
||||
type PostImage struct {
|
||||
Width int `json:"width"`
|
||||
Height int `json:"height"`
|
||||
|
||||
// Format is the name of the image format as used by image/go such as "png", "gif", or "jpeg".
|
||||
Format string `json:"format"`
|
||||
|
||||
// FrameCount stores the number of frames in this image, if it is an animated gif. It will be 0 for other formats.
|
||||
FrameCount int `json:"frame_count"`
|
||||
}
|
||||
|
||||
func (o *PostImage) ToJson() string {
|
||||
|
||||
Ссылка в новой задаче
Block a user