00001 #include <stdio.h>
00002 #include "lightfield.h"
00003
00004
00005
00006
00007
00008 bool vu16::read(FILE *file)
00009 {
00010 int ret = 0;
00011 int len = 0;
00012
00013 bool success = vu1::read(file);
00014 if (!success) return false;
00015
00016 ret = fscanf(file,"DATASET LIGHTFIELD %n",&len);
00017 if (len < 19) return setInvalidFormatError();
00018
00019 return true;
00020 }
00021
00022
00023
00024
00025
00026 bool vu16::write(FILE *file)
00027 {
00028 int ret = 0;
00029
00030 bool success = vu1::write(file);
00031 if (!success) return false;
00032
00033
00034 ret = fprintf(file,"DATASET LIGHTFIELD\n");
00035
00036 if (ret > 0)
00037 return true;
00038 else
00039 return setWriteError();
00040 }