From patchwork Wed Mar 29 02:55:57 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: James Almer X-Patchwork-Id: 3162 Delivered-To: ffmpegpatchwork@gmail.com Received: by 10.103.44.195 with SMTP id s186csp900966vss; Tue, 28 Mar 2017 19:58:40 -0700 (PDT) X-Received: by 10.223.160.183 with SMTP id m52mr11116491wrm.201.1490756320564; Tue, 28 Mar 2017 19:58:40 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id f74si5475127wmi.20.2017.03.28.19.58.38; Tue, 28 Mar 2017 19:58:40 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=gmail.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 0ACD3689A0C; Wed, 29 Mar 2017 05:57:56 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mail-qk0-f196.google.com (mail-qk0-f196.google.com [209.85.220.196]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id EA8176891DB for ; Wed, 29 Mar 2017 05:57:49 +0300 (EEST) Received: by mail-qk0-f196.google.com with SMTP id 10so454939qkh.1 for ; Tue, 28 Mar 2017 19:58:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=KVvmR2teI8Es2zZUlUZQjsC8aR2NiggRfyvLeP2cgEM=; b=tcoUAP5vgvQDcFLFQo0yim4Dve4KnSBqIBSRltYoVA80f5RIVrArjk8VFvYEUWsefq Cc3jRh+gum8lj/jmVg++BRc9KIIkGv4/5/Ll3gMEr1q1zm11AKgfJ2LCXxVvAzo9KSr/ Tl4VtK5f8OU5sfaYn4NhWTUMzHSeFagOosJtR+uYovw3OlzpuNYonDu3yGjttRC6EG7W IPBBrjmk/GSDATFyrssCiJfvt85C7WbMhpDZMvrExjO3S8Kh97L/Pc0lkzP/370uvYM+ 4au91M2l/7gAHlM2uGfY7Tr4j4FCwuSFlWU2irCqzqDwW6xatk2JkotYZrf5+h0cI3+h hzXg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=KVvmR2teI8Es2zZUlUZQjsC8aR2NiggRfyvLeP2cgEM=; b=rBLMEh7CtmZzNwQvmQ1jHReARBruUbdjQM9L9yOg8OZxKsxRjb4lLtHk3Tq1QXaGQZ Ccv47x1GvX8/zSzPF12fFN0OJSO7kmInibyHtKrxhgRuIKFV3bybg0DGQqCWGoXVEpZk GIp6MhFAnlYvHmwatKZBcspQdD5xMFBicgUYzTgmqxvsMBCy1pkgaQyRE+XkKEWAXoPi QXSQ0rY8u0Gy24FJIaBFMGZYKXGxQe4FCFDYlXnV1ppamLVI7vNV51iS/gWEKik1aX4n mYXn1wpomz/3DAGzAM7ML7Z/lEyn8s7sx1kt/sXhm+tYQsDQ6eyBkpxKXAgh+y0L6UML cokg== X-Gm-Message-State: AFeK/H0lLASKDmb+Qe5IstLGP/CuN5Mv9vKmlcRxwnv7zV/raALy65cPsocJDjaZzsOPnQ== X-Received: by 10.55.65.81 with SMTP id o78mr26966162qka.82.1490756291500; Tue, 28 Mar 2017 19:58:11 -0700 (PDT) Received: from localhost.localdomain ([181.231.62.139]) by smtp.gmail.com with ESMTPSA id e16sm4018899qkj.64.2017.03.28.19.58.10 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 28 Mar 2017 19:58:11 -0700 (PDT) From: James Almer To: ffmpeg-devel@ffmpeg.org Date: Tue, 28 Mar 2017 23:55:57 -0300 Message-Id: <20170329025557.952-3-jamrial@gmail.com> X-Mailer: git-send-email 2.12.1 In-Reply-To: <20170329025557.952-1-jamrial@gmail.com> References: <20170329025557.952-1-jamrial@gmail.com> Subject: [FFmpeg-devel] [PATCH 3/3] ffprobe: use av_spherical_projection_name() to print spherical projection names X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Vittorio Giovara MIME-Version: 1.0 Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Signed-off-by: James Almer --- ffprobe.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/ffprobe.c b/ffprobe.c index 67c4ed40fa..be5583aea2 100644 --- a/ffprobe.c +++ b/ffprobe.c @@ -1872,22 +1872,18 @@ static void print_pkt_side_data(WriterContext *w, print_int("inverted", !!(stereo->flags & AV_STEREO3D_FLAG_INVERT)); } else if (sd->type == AV_PKT_DATA_SPHERICAL) { const AVSphericalMapping *spherical = (AVSphericalMapping *)sd->data; - if (spherical->projection == AV_SPHERICAL_EQUIRECTANGULAR) - print_str("projection", "equirectangular"); - else if (spherical->projection == AV_SPHERICAL_CUBEMAP) { - print_str("projection", "cubemap"); + print_str("projection", av_spherical_projection_name(spherical->projection)); + if (spherical->projection == AV_SPHERICAL_CUBEMAP) { print_int("padding", spherical->padding); } else if (spherical->projection == AV_SPHERICAL_EQUIRECTANGULAR_TILE) { size_t l, t, r, b; av_spherical_tile_bounds(spherical, par->width, par->height, &l, &t, &r, &b); - print_str("projection", "tiled equirectangular"); print_int("bound_left", l); print_int("bound_top", t); print_int("bound_right", r); print_int("bound_bottom", b); - } else - print_str("projection", "unknown"); + } print_int("yaw", (double) spherical->yaw / (1 << 16)); print_int("pitch", (double) spherical->pitch / (1 << 16));