Movie. Labels from text

I am using movie with the following file as timefile. I can’t managed to use the file for labels. Should I use -Lt? In the man page says “If -Lt is used then the format statement must contain a %s-like format”. What exactly should I use it?

-R0/1/0/1
-R1/2/0/1
-R2/3/0/1
-R0/1/1/2
-R1/2/1/2
-R2/3/1/2
-R0/1/2/3
-R1/2/2/3
-R2/3/2/3

My guess would be -Lt0, and you may need to add +w to your -T option to break that single trailing text into a single word. I dont think you need to add +t to -L since it should default to “%s”, but if it complaints you could try -Lt0+t"%s"

When I used -Lt0+t"%s" I get:

movie [ERROR]: option -L: Using +f with frame or data variables requires a ‘%d’, ‘%e’, ‘%f’, or ‘%g’ -style format.

I think this was fixed by this PR.

I didn’t see that. Many thanks @maxrjones and Paul.

I try it. Now when I used

-Lt0+t"%s"

I get:

ERROR: Caught signal number 11 (Segmentation fault) at
/lib/x86_64-linux-gnu/libc.so.6(+0xb4d5a)[0x7fba9d304d5a]
[0x0]
Stack backtrace:
/usr/local/lib/libgmt.so.6(sig_handler+0x2ad)[0x7fba9d4a122d]
/lib/x86_64-linux-gnu/libc.so.6(+0x46210)[0x7fba9d296210]
/lib/x86_64-linux-gnu/libc.so.6(+0xb4d5a)[0x7fba9d304d5a]
/lib/x86_64-linux-gnu/libc.so.6(__stpcpy_chk+0x1f)[0x7fba9d380bdf]
/usr/local/lib/libgmt.so.6(GMT_movie+0x518a)[0x7fba9d7986aa]
/usr/local/lib/libgmt.so.6(GMT_Call_Module+0x40f)[0x7fba9d4bffbf]
gmt(main+0x264)[0x561359e8b5e4]
/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf3)[0x7fba9d2770b3]
gmt(_start+0x2e)[0x561359e8c65e]

Is this a bug? Or something else? If a remove it, then there is no error.

Can you post the master script and one of the parameter files? Need to run with -Qs to save those scripts.

Are these?

Master script:

gmt begin
#	Seleccionar Datos
	gmt select "Az_Pendientes.txt" ${MOVIE_TEXT} -o2,3 -fg > "temp_rumbo" -bi4f

#	Dibujar rosa.
	gmt rose "temp_rumbo" -Gorange -Wfaint -Bx0.2g0.2 -By30g30 -B+glightblue -A3r -S5cn -D -LW,E,S,N -JX10 -R0/1/0/360 -Yc -Xc -T
  	
gmt end

Parameter file (movie_params_0.sh):

# Parameter file for frame 0
MOVIE_NAME=Movie_world_label_BUG_0
MOVIE_FRAME=0
MOVIE_ITEM=0
MOVIE_BACKGROUND=
MOVIE_ITEM=0
MOVIE_TEXT=-R-67/-66/-55/-54
MOVIE_WORD0=-R-67/-66/-55/-54

Should be one called movie_master.sh. I see no LABEL variables in your parameter file. Perhaps simplest if you are able to post a zip with everything I need to recreate your problem , if that is possible.

I send shell file (with txt extension).

Movie_world_label_BUG.txt (1,9 KB)

The movie_master.sh was NOT created (as well as movie_frame.sh). I used -Lf instead and those files appeared.

Thanks I found the problem and have submitted a PR https://github.com/GenericMappingTools/gmt/pull/4858/files

1 Like