Migration of current video works from private repository to this repository. This closed #1176

git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3392 74dad513-b988-da41-8d7b-12977e46ad98
diff --git a/pjsip-apps/src/samples/level.c b/pjsip-apps/src/samples/level.c
index d16535c..358265f 100644
--- a/pjsip-apps/src/samples/level.c
+++ b/pjsip-apps/src/samples/level.c
@@ -124,7 +124,7 @@
 	return 1;
     }
 
-    if (file_port->info.samples_per_frame > NSAMPLES) {
+    if (PJMEDIA_PIA_SPF(&file_port->info) > NSAMPLES) {
 	app_perror(THIS_FILE, "WAV clock rate is too big", PJ_EINVAL);
 	return 1;
     }
@@ -145,11 +145,11 @@
 	pjmedia_port_get_frame(file_port, &frm);
 
 	level32 = pjmedia_calc_avg_signal(framebuf, 
-					  file_port->info.samples_per_frame);
+					  PJMEDIA_PIA_SPF(&file_port->info));
 	level = pjmedia_linear2ulaw(level32) ^ 0xFF;
 
-	ms = i * 1000 * file_port->info.samples_per_frame /
-			file_port->info.clock_rate;
+	ms = i * 1000 * PJMEDIA_PIA_SPF(&file_port->info) /
+		PJMEDIA_PIA_SRATE(&file_port->info);
 	printf("%03d.%03d\t%7d\t%7d\n", 
 	        ms/1000, ms%1000, level, level32);
     }