-
-
Notifications
You must be signed in to change notification settings - Fork 16
Expand file tree
/
Copy pathMediaConstraints.java
More file actions
26 lines (23 loc) · 1.1 KB
/
MediaConstraints.java
File metadata and controls
26 lines (23 loc) · 1.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
package com.github.stickerifier.stickerify.media;
/**
* Class containing the constraints for Telegram stickers as documented in the documentation:
*
* @see <a href="https://core.telegram.org/stickers#static-stickers-and-emoji">Static stickers' constraints</a>
* @see <a href="https://core.telegram.org/stickers#video-stickers-and-emoji">Video stickers' constraints</a>
* @see <a href="https://core.telegram.org/stickers#creating-animations">Animated stickers' constraints</a>
*/
public final class MediaConstraints {
static final int MAX_SIDE_LENGTH = 512;
static final int MAX_VIDEO_FRAMES = 30;
static final float MAX_VIDEO_DURATION_SECONDS = 3.0F - (1.0F / MAX_VIDEO_FRAMES);
static final String VP9_CODEC = "vp9";
static final String MATROSKA_FORMAT = "matroska";
static final long MAX_IMAGE_FILE_SIZE = 512_000L;
static final long MAX_VIDEO_FILE_SIZE = 256_000L;
static final long MAX_ANIMATION_FILE_SIZE = 64_000L;
static final int MAX_ANIMATION_FRAME_RATE = 60;
static final float MAX_ANIMATION_DURATION_SECONDS = 3.0F;
private MediaConstraints() {
throw new UnsupportedOperationException();
}
}