From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id aJMxAFWArGLnIgEAbAwnHQ (envelope-from ) for ; Fri, 17 Jun 2022 15:23:33 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id KKAAAFWArGKfPAAAauVa8A (envelope-from ) for ; Fri, 17 Jun 2022 15:23:33 +0200 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 802916F3B for ; Fri, 17 Jun 2022 15:23:32 +0200 (CEST) Received: from localhost ([::1]:46560 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1o2Bwh-00080b-Od for larch@yhetil.org; Fri, 17 Jun 2022 09:23:31 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:38762) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1o2BvK-00080S-QW for emacs-orgmode@gnu.org; Fri, 17 Jun 2022 09:22:06 -0400 Received: from mbda-vdr-fe2-out.mbda.gmessaging.net ([62.161.9.156]:53378 helo=mbda-vdr-fe2.mbda.gmessaging.net) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1o2BvG-0005aF-LI for emacs-orgmode@gnu.org; Fri, 17 Jun 2022 09:22:05 -0400 Received: from mbda-vdr-fe2.mbda.gmessaging.net (localhost.localdomain [127.0.0.1]) by localhost.mbda.gmessaging.net (Postfix) with SMTP id 4LPfpJ0NRXz3Sr2K for ; Fri, 17 Jun 2022 15:22:00 +0200 (CEST) Received: from RPRELAY41 (unknown [192.168.177.4]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "RPRELAY41", Issuer "RPRELAY41" (not verified)) by mbda-vdr-fe2.mbda.gmessaging.net (Postfix) with ESMTPS id 4LPfpH6wDwz3Sr2H for ; Fri, 17 Jun 2022 15:21:59 +0200 (CEST) X-IronPort-AV: E=Sophos;i="5.92,306,1650924000"; d="scan'208";a="43442032" From: DEBRY.Edouard To: Emacs-orgmode Subject: Creating animated gif from latex src blocks Thread-Topic: Creating animated gif from latex src blocks Thread-Index: AQHYgk05tQWPNAGvcEGrmv1h7kulPQ== Date: Fri, 17 Jun 2022 13:21:58 +0000 Message-ID: Accept-Language: fr-FR, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mbda-systems.com; h=from:to:subject:date:message-id:content-type:content-transfer-encoding:mime-version; s=selector2; bh=xv6bHYdezwH/P1oOYH0W/f1aOsF+wp22tepW+NcNJ40=; b=xud6NQyVzhVBLts2zrcIY89H3ZURCPECDVLO9FjrUb+/p8zOJLpu7Zj4fmvRFBzkQXU+I3fsXyP/5XliPVk32JQVUhWUo2uluDrEQUP5t4sFZ1jltNwDGLmWsOnnRxdsdsRFw+zKg6jsDn1J39mpa482rA0tPBsLo3wio0SVbIHqENTzFSPuRzm5gqmQbryO95abQ3dXLXrXxysI6kg4X3Q7G8ji0J9hlts5RuI1wcFmjcM7Wihsq7bWO3z8AP9IdcNBjahHVPanpUsdh9llHKZ62z8HJ9rPyvzxQbTcl/a7oscBiDvnDPLal9APOaW6B3JplVZ/TGUOh0EqNpD5hw== Received-SPF: pass client-ip=62.161.9.156; envelope-from=edouard.debry@mbda-systems.com; helo=mbda-vdr-fe2.mbda.gmessaging.net X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN X-Migadu-To: larch@yhetil.org X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1655472212; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=xv6bHYdezwH/P1oOYH0W/f1aOsF+wp22tepW+NcNJ40=; b=noQIjrHj12G/XKG12DQjTcBK6M9/s713PNZP9t3Av7+nsVruoH8/NGGxhZYsm/p6bgvYWg LyGTw6vAT61B0Q7z1Dyy6CHQy1jVPns4n+SUvc7fyDXxPK9A60cAD8Cac/aeBMv3UvunCy UfJbRmTQzinyLWXIhENJbi2tEMwD3w88we+DNmhwCHhwS/iZCKDN+XaSdAYlR5P6ZzYhDU m2NZ9cxPuKKbgz7eMc2/G8zeccMCbKtJys3WemoZCVwV4AxklX3qOMY+JLpJ5qYNM0gm5K no4OO4qlRJmpfLSndpU1smvPjbDo0rzDrda8DKUZWzYSj0pa2rqjSXgmAg2dtQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1655472212; a=rsa-sha256; cv=none; b=bq3F1TUDgzdlyDTobSO/Vnp8408cNDU/wzOlX02QmUPZGPyJi/t/TC7vHn0R0KCVG1w3pU 3uN0fS6GsZ4AsF8fmeyzSHWq1agl40qdiRqxgvl45EUSMJcGwxpmq/gflxraPpTfw+GL3Y wvESdX1QAl+RNz5F2JAdjOvj8vdWyCVOrJvym8fwnvoNp3rXAMIB2GX2GXAaubsKOk0p57 VZmSC1olap6JW+AJ/pvSMY3v/aq+HvqOZar2dGx4WA01Y4KsEzS6hLiLZKSKehLjGiV7xH ni/51dG7/cwsh8WGSyuZF5E2J8udrns/pWVOa79OmIS9I8RubkdTVnHsR8vX2A== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=mbda-systems.com header.s=selector2 header.b=xud6NQyV; dmarc=none; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -3.59 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=mbda-systems.com header.s=selector2 header.b=xud6NQyV; dmarc=none; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: 802916F3B X-Spam-Score: -3.59 X-Migadu-Scanner: scn1.migadu.com X-TUID: 55UM2LW8ePDq Hello, I would like to create an animated gif for a latex src block. Here to fix ideas such a block : <=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D> #+header: :file test4.gif #+header: :exports results #+header: :results output silent graphics file #+header: :imagemagick yes :iminoptions -density 600 -delay 8 -loop 0 -back= ground white -alpha remove #+header: :fit yes :noweb yes :headers '("\\usepackage{tikz}") #+begin_src latex \foreach \angle in {0,10,...,360} { \begin{tikzpicture} % fill circle and plot \fill[blue!50] (-1,0) arc (0:\angle:1) -- (-2,0) -- cycle; \fill[blue!50] plot[smooth,domain=3D0:\angle] (pi/180*\x,{sin(\x)}) |- = (0,0); % draw connection \draw (-2,0) +(\angle:1) circle (2pt) -- (pi/180*\angle,{sin(\angle)}) = circle (2pt); % draw axes an ticks \draw (-3.5,0) -- (7,0); \foreach \deg in {90, 180, 270, 360} \draw (pi/180*\deg,2pt) -- (pi/180*\deg,-2pt) node[below] {$\deg^\cir= c$}; \draw (0,-1.2) -- (0,1.2); \foreach \y in {-1,-0.5,0.5,1} \draw (2pt,\y) -- (-2pt,\y) node[left] {$\y$}; % draw plot and circle outline \draw plot[smooth,domain=3D0:360] (pi/180*\x,{sin(\x)}); \draw (-2,0) circle (1); \end{tikzpicture} } #+end_src <=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D> grabbed here : https://tex.stackexchange.com/questions/291627/draw-an-animated-gif-of-trig= onometry-function When hitting [C-c C-c], it does produce a gif, but which cannot be animated. I downloaded another animated gif on internet which works properly within emacs, so the issue comes most probably from the latex to pdf generation. I noticed that the latex header used is <=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D> \documentclass{article} \usepackage[usenames]{color} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} \usepackage{graphicx} \usepackage{longtable} \usepackage{wrapfig} \usepackage{rotating} \usepackage[normalem]{ulem} \usepackage{amsmath} \usepackage{amssymb} \usepackage{capt-of} \pagestyle{empty} % do not remove % The settings below are copied from fullpage.sty \setlength{\textwidth}{\paperwidth} \addtolength{\textwidth}{-3cm} \setlength{\oddsidemargin}{1.5cm} \addtolength{\oddsidemargin}{-2.54cm} \setlength{\evensidemargin}{\oddsidemargin} \setlength{\textheight}{\paperheight} \addtolength{\textheight}{-\headheight} \addtolength{\textheight}{-\headsep} \addtolength{\textheight}{-\footskip} \addtolength{\textheight}{-3cm} \setlength{\topmargin}{1.5cm} \addtolength{\topmargin}{-2.54cm} \usepackage[active, tightpage]{preview} <=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D> which is different from the latex header used in tex.stackexchange page : <=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D> \documentclass[tikz]{standalone} \usepackage{tikz} <=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D> I replaced the default header provided by emacs with this very one and it worked. Is it possible to modify the latex header depending on the export image format ? Regards ___________________________________________________________________________= ________________________________________________________ This email and any attachments are confidential to the intended recipient a= nd may also be privileged. If you are not the intended recipient please delete it from your system and= notify the sender.=20 You should not copy it or use it for any purpose nor disclose or distribute= its contents to any other person. =20 Ce courriel et ses pieces-jointes sont envoyes de maniere confidentielle et= doivent etre traites avec attention. Si vous n'etes pas le destinataire, merci de le detruire et d'en informer s= on auteur.=20 Vous ne devez pas copier, utiliser, reveler ou diffuser son contenu a quico= nque.