diff -urN rt_v22/dat.py rt_v23/dat.py
--- rt_v22/dat.py	2018-04-15 18:19:02.000000000 +0900
+++ rt_v23/dat.py	2018-04-16 21:00:00.000000000 +0900
@@ -9,9 +9,7 @@
 import fcx
 import lstx
 
-copen = 'copen-090419.jpg'
-
-maps_copen = [ { 'fn': copen, 't2m': [ ax.zoom_all(2) ] } ]
+maps_copen = [ { 'fn': 'copen-090419.jpg', 't2m': [ ax.zoom_all(2) ] } ]
 
 copen = [ {
 	'kind': 'square',
@@ -26,6 +24,22 @@
 	'm2g': [ ax.zoom_all(50) ],
 } ]
 
+maps_copen_rep = [ { 'fn': 'copen-090419.jpg', 't2m': [ ax.zoom_all(0.5) ], 'rep': (True,True) } ]
+
+rtd = { 'base':0.1, 'diff': 0, 'reflect': 0.5, 'reflact': 0.5, 'density': 2 }
+
+copen_rep = [ {
+	'kind': 'square',
+	'l2m': [],
+	'maps': maps_copen_rep,
+	'm2g': [ ax.zoom_all(50), ax.slide_z(-20) ],
+},{
+	'kind': 'ball',
+	'rtd': rtd,
+	'def_col': [128,0,0],
+	'm2g': [ ax.zoom_all(20), ax.slide_z(20) ],
+} ]
+
 maps = [
 	{ 'fn': 'IMG_3999_3.mov', 'fn_r': 'IMG_3999_4.mov', 't2m': [ ax.zoom_all(3) ] },
 ]
@@ -73,8 +87,6 @@
 	'm2g': [ ax.zoom_all(50) ],
 } ]
 
-rtd = { 'base':0.1, 'diff': 0, 'reflect': 0.5, 'reflact': 0.5, 'density': 2 }
-
 objs = [ {
 	'kind': 'square',
 	'rtd': { 'base': 0.1, 'diff': 1.0, 'reflect': 0.9 },
@@ -176,16 +188,26 @@
 	'm2g': [ ax.zoom_all(7), ax.slide_x(-10) ]
 } ]
 
-data_dic = {
-	'copen': copen,
-	'ball': ball,
-	'cube': cube,
-	'poly_n_pyramid': poly_n_pyramid,
-	'objs': objs,
-	'ball_world': ball_world,
-}
+ball_world2 = [ {
+	'kind': 'ball',
+	'rtd': { 'diff': 0.3 },
+	'maps': [ { 'fn': 'IMG_3999_3.mov', 'fn_r': 'IMG_3999_4.mov', 'r': 0.3, 'rep': (True,True) } ],
+	'm2g': [ ax.zoom_all(r), ax.slide_z(-r/2) ],
+},{
+	'kind': 'circle',
+	'rtd': { 'diff': 0.1, 'reflect': 0.3 },
+	'm2g': [ ax.zoom_all(r), ax.slide_z(-r/2) ],
+},{
+	'kind': 'ball',
+	'rtd': rtd,
+	'm2g': [ ax.zoom_all(10), ax.slide_x(10) ]
+},{
+	'kind': 'cube',
+	'rtd': rtd,
+	'm2g': [ ax.zoom_all(7), ax.slide_x(-10) ]
+} ]
 
-data = data_dic.get( ut.arg_s('data_name'), [] )
+data = eval( ut.arg_s('data_name', 'copen') )
 
 lights = [
 	{ 'p': mt.arr( [1,-1,-1] ) * 30, 'e': 2.5 },
diff -urN rt_v22/img.py rt_v23/img.py
--- rt_v22/img.py	2018-04-06 15:32:01.000000000 +0900
+++ rt_v23/img.py	2018-04-16 21:00:00.000000000 +0900
@@ -8,6 +8,14 @@
 img_wh = lambda img: ( lambda h, w, d: (w, h) )( *img.shape )
 resize = lambda img, w, h: img if img_wh(img) == (w, h) else cv2.resize( img, (w, h) )
 
+def rep_xy(x, y, w, h, rep):
+	(rx, ry) = rep;
+	if rx and not (0 <= x and x < w):
+		x = x % w if x > 0 else w - (-x % w)
+	if ry and not (0 <= y and y < h):
+		y = y % h if y > 0 else h - (-y % h)
+	return (x, y)
+
 def new_imgs():
 	d = {}
 	e = ut.Empty()
@@ -20,7 +28,17 @@
 
 	e.wh = lambda fn: img_wh( get(fn) )
 	e.in_img = lambda fn, x, y: ( lambda w, h: 0 <= x and x < w and 0 <= y and y < h )( *e.wh(fn) )
-	e.col = lambda fn, x, y, def_col=[128,128,128]: get(fn)[y, x] if e.in_img(fn, x, y) else def_col
+
+	def col(fn, x, y, def_col=[128,128,128], rep=None):
+		if e.in_img(fn, x, y):
+			return get(fn)[y, x] 
+		if rep:
+			(w, h) = e.wh(fn)
+			(x, y) = rep_xy(x, y, w, h, rep)
+			if e.in_img(fn, x, y):
+				return get(fn)[y, x] 
+		return def_col
+	e.col = col
 
 	return e
 
@@ -75,7 +93,17 @@
 
 	img_sec = lambda fn, sec: e.imgs(fn)[ int( e.fps(fn) * sec ) % e.n(fn) ]
 	e.in_img = lambda fn, x, y: ( lambda w, h: 0 <= x and x < w and 0 <= y and y < h )( *e.wh(fn) )
-	e.col = lambda fn, sec, x, y, def_col=[128,128,128]: img_sec(fn, sec)[y, x] if e.in_img(fn, x, y) else def_col
+
+	def col(fn, sec, x, y, def_col=[128,128,128], rep=None):
+		if e.in_img(fn, x, y):
+			return img_sec(fn, sec)[y, x]
+		if rep:
+			(w, h) = e.wh(fn)
+			(x, y) = rep_xy(x, y, w, h, rep)
+			if e.in_img(fn, x, y):
+				return img_sec(fn, sec)[y, x]
+		return def_col
+	e.col = col
 
 	return e
 
@@ -92,10 +120,10 @@
 
 wh = lambda fn: ( videos if fn_typ(fn) == 'v' else imgs ).wh(fn)
 
-def col(fn, sec, x, y, def_col=[128,128,128]):
+def col(fn, sec, x, y, def_col=[128,128,128], rep=None):
 	if fn_typ(fn) == 'v':
-		return videos.col(fn, sec, x, y, def_col)
-	return imgs.col(fn, x, y, def_col)
+		return videos.col(fn, sec, x, y, def_col, rep)
+	return imgs.col(fn, x, y, def_col, rep)
 
 def new_wimg(w, h, def_col=[0,0,0]):
 	e = ut.Empty()
diff -urN rt_v22/Makefile rt_v23/Makefile
--- rt_v22/Makefile	2018-04-13 22:02:41.000000000 +0900
+++ rt_v23/Makefile	2018-04-16 21:00:00.000000000 +0900
@@ -5,7 +5,7 @@
 all: sock
 
 sock: $(OBJS)
-	gcc -o $@ $(OBJS)
+	gcc -o $@ $(OBJS) -lm
 clean:
 	rm -f *.o *~
 # EOF
diff -urN rt_v22/rt.py rt_v23/rt.py
--- rt_v22/rt.py	2018-04-15 18:02:30.000000000 +0900
+++ rt_v23/rt.py	2018-04-16 21:00:00.000000000 +0900
@@ -32,7 +32,7 @@
 		#(x, y, _) = lstx.tr( m.get('wh2xyz'), 'g2l', nv_line.p )
 		(x, y, _) = lstx.tr_p( m.get('wh2xyz'), 'g2l', nv_line.p )
 		sec = video.cur_sec() + ut.arg_f('init_sec', 0.0)
-		return img.col( fn, sec, int(x), int(y), [] )
+		return img.col( fn, sec, int(x), int(y), [], m.get('rep') )
 
 	cols = map( f, d.get('maps') )
 	cols = ut.filter_lst( lambda col: col != [], cols )
