From: <ai...@us...> - 2009-02-20 21:18:37
|
Revision: 9565 http://plplot.svn.sourceforge.net/plplot/?rev=9565&view=rev Author: airwin Date: 2009-02-20 21:18:33 +0000 (Fri, 20 Feb 2009) Log Message: ----------- Add a pointer to a QSASConfig in plstrm.h. This pointer is currently only used in plbox.c, but that is about to change. Modified Paths: -------------- trunk/bindings/f77/CMakeLists.txt trunk/bindings/f95/CMakeLists.txt trunk/bindings/gnome2/lib/CMakeLists.txt trunk/bindings/gnome2/python/CMakeLists.txt trunk/bindings/java/CMakeLists.txt trunk/bindings/lua/CMakeLists.txt trunk/bindings/ocaml/myocamlbuild.ml.cmake trunk/bindings/python/CMakeLists.txt trunk/bindings/tcl/CMakeLists.txt trunk/bindings/wxwidgets/CMakeLists.txt trunk/drivers/CMakeLists.txt trunk/examples/ada/CMakeLists.txt trunk/examples/c/CMakeLists.txt trunk/examples/c++/CMakeLists.txt trunk/examples/f77/CMakeLists.txt trunk/examples/f95/CMakeLists.txt trunk/include/plstrm.h trunk/src/plbox.c trunk/utils/CMakeLists.txt Modified: trunk/bindings/f77/CMakeLists.txt =================================================================== --- trunk/bindings/f77/CMakeLists.txt 2009-02-20 19:43:15 UTC (rev 9564) +++ trunk/bindings/f77/CMakeLists.txt 2009-02-20 21:18:33 UTC (rev 9565) @@ -67,6 +67,7 @@ # Set the include path include_directories( ${CMAKE_CURRENT_SOURCE_DIR} +${CMAKE_SOURCE_DIR}/lib/qsastime ${CMAKE_SOURCE_DIR}/include ${CMAKE_BINARY_DIR} ${CMAKE_BINARY_DIR}/include Modified: trunk/bindings/f95/CMakeLists.txt =================================================================== --- trunk/bindings/f95/CMakeLists.txt 2009-02-20 19:43:15 UTC (rev 9564) +++ trunk/bindings/f95/CMakeLists.txt 2009-02-20 21:18:33 UTC (rev 9565) @@ -23,6 +23,7 @@ # Set the include path include_directories( ${CMAKE_SOURCE_DIR}/include + ${CMAKE_SOURCE_DIR}/lib/qsastime ${CMAKE_BINARY_DIR} ${CMAKE_BINARY_DIR}/include ${CMAKE_CURRENT_SOURCE_DIR} Modified: trunk/bindings/gnome2/lib/CMakeLists.txt =================================================================== --- trunk/bindings/gnome2/lib/CMakeLists.txt 2009-02-20 19:43:15 UTC (rev 9564) +++ trunk/bindings/gnome2/lib/CMakeLists.txt 2009-02-20 21:18:33 UTC (rev 9565) @@ -45,6 +45,7 @@ # Set the include path include_directories( ${CMAKE_SOURCE_DIR}/include +${CMAKE_SOURCE_DIR}/lib/qsastime ${CMAKE_BINARY_DIR} ${CMAKE_BINARY_DIR}/include ) Modified: trunk/bindings/gnome2/python/CMakeLists.txt =================================================================== --- trunk/bindings/gnome2/python/CMakeLists.txt 2009-02-20 19:43:15 UTC (rev 9564) +++ trunk/bindings/gnome2/python/CMakeLists.txt 2009-02-20 21:18:33 UTC (rev 9565) @@ -111,6 +111,7 @@ include_directories( ${CMAKE_SOURCE_DIR}/include +${CMAKE_SOURCE_DIR}/lib/qsastime ${CMAKE_BINARY_DIR} ${CMAKE_BINARY_DIR}/include ${PYTHON_INCLUDE_PATH} Modified: trunk/bindings/java/CMakeLists.txt =================================================================== --- trunk/bindings/java/CMakeLists.txt 2009-02-20 19:43:15 UTC (rev 9564) +++ trunk/bindings/java/CMakeLists.txt 2009-02-20 21:18:33 UTC (rev 9565) @@ -104,6 +104,7 @@ set(java_interface_INCLUDE_PATHS ${CMAKE_SOURCE_DIR} ${CMAKE_SOURCE_DIR}/include +${CMAKE_SOURCE_DIR}/lib/qsastime ${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_BINARY_DIR} ${CMAKE_BINARY_DIR}/include Modified: trunk/bindings/lua/CMakeLists.txt =================================================================== --- trunk/bindings/lua/CMakeLists.txt 2009-02-20 19:43:15 UTC (rev 9564) +++ trunk/bindings/lua/CMakeLists.txt 2009-02-20 21:18:33 UTC (rev 9565) @@ -23,6 +23,7 @@ # This is currently the include list for swig. set(lua_interface_INCLUDE_PATHS ${CMAKE_SOURCE_DIR}/include +${CMAKE_SOURCE_DIR}/lib/qsastime ${CMAKE_BINARY_DIR} ${CMAKE_BINARY_DIR}/include ${CMAKE_CURRENT_BINARY_DIR} Modified: trunk/bindings/ocaml/myocamlbuild.ml.cmake =================================================================== --- trunk/bindings/ocaml/myocamlbuild.ml.cmake 2009-02-20 19:43:15 UTC (rev 9564) +++ trunk/bindings/ocaml/myocamlbuild.ml.cmake 2009-02-20 21:18:33 UTC (rev 9565) @@ -29,6 +29,7 @@ (* gcc needs to know where to find the needed #includes *) flag ["c"; "compile"] (S[A"-ccopt"; A"-I@SOURCE_DIR@/include"; + A"-ccopt"; A"-I@SOURCE_DIR@/lib/qsastime"; A"-ccopt"; A"-I@BUILD_DIR@/include"] ); (* Custom tag for OCaml bytecode *) Modified: trunk/bindings/python/CMakeLists.txt =================================================================== --- trunk/bindings/python/CMakeLists.txt 2009-02-20 19:43:15 UTC (rev 9564) +++ trunk/bindings/python/CMakeLists.txt 2009-02-20 21:18:33 UTC (rev 9565) @@ -32,6 +32,7 @@ # the Python headers. Not particular pretty... set(python_interface_INCLUDE_PATHS ${CMAKE_SOURCE_DIR}/include +${CMAKE_SOURCE_DIR}/lib/qsastime ${CMAKE_BINARY_DIR} ${CMAKE_BINARY_DIR}/include ${CMAKE_CURRENT_BINARY_DIR} Modified: trunk/bindings/tcl/CMakeLists.txt =================================================================== --- trunk/bindings/tcl/CMakeLists.txt 2009-02-20 19:43:15 UTC (rev 9564) +++ trunk/bindings/tcl/CMakeLists.txt 2009-02-20 21:18:33 UTC (rev 9565) @@ -29,6 +29,7 @@ include_directories( ${TCL_INCLUDE_PATH} ${CMAKE_SOURCE_DIR}/include +${CMAKE_SOURCE_DIR}/lib/qsastime ${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_BINARY_DIR} ${CMAKE_BINARY_DIR}/include Modified: trunk/bindings/wxwidgets/CMakeLists.txt =================================================================== --- trunk/bindings/wxwidgets/CMakeLists.txt 2009-02-20 19:43:15 UTC (rev 9564) +++ trunk/bindings/wxwidgets/CMakeLists.txt 2009-02-20 21:18:33 UTC (rev 9565) @@ -39,6 +39,7 @@ # Set the include path include_directories( ${CMAKE_SOURCE_DIR}/include + ${CMAKE_SOURCE_DIR}/lib/qsastime ${CMAKE_SOURCE_DIR}/bindings/c++ ${CMAKE_BINARY_DIR} ${CMAKE_BINARY_DIR}/include Modified: trunk/drivers/CMakeLists.txt =================================================================== --- trunk/drivers/CMakeLists.txt 2009-02-20 19:43:15 UTC (rev 9564) +++ trunk/drivers/CMakeLists.txt 2009-02-20 21:18:33 UTC (rev 9565) @@ -32,6 +32,7 @@ include_directories( ${CMAKE_SOURCE_DIR}/include + ${CMAKE_SOURCE_DIR}/lib/qsastime ${CMAKE_BINARY_DIR} ${CMAKE_BINARY_DIR}/include ) Modified: trunk/examples/ada/CMakeLists.txt =================================================================== --- trunk/examples/ada/CMakeLists.txt 2009-02-20 19:43:15 UTC (rev 9564) +++ trunk/examples/ada/CMakeLists.txt 2009-02-20 21:18:33 UTC (rev 9565) @@ -87,6 +87,7 @@ remove_definitions("-DHAVE_CONFIG_H") include_directories( ${CMAKE_BINARY_DIR}/examples/ada + ${CMAKE_SOURCE_DIR}/lib/qsastime ${CMAKE_BINARY_DIR}/bindings/ada ) endif(BUILD_TEST) Modified: trunk/examples/c/CMakeLists.txt =================================================================== --- trunk/examples/c/CMakeLists.txt 2009-02-20 19:43:15 UTC (rev 9564) +++ trunk/examples/c/CMakeLists.txt 2009-02-20 21:18:33 UTC (rev 9565) @@ -60,7 +60,11 @@ if(BUILD_TEST) remove_definitions("-DHAVE_CONFIG_H") - include_directories(${CMAKE_SOURCE_DIR}/include ${CMAKE_BINARY_DIR}/include) + include_directories( + ${CMAKE_SOURCE_DIR}/include + ${CMAKE_SOURCE_DIR}/lib/qsastime + ${CMAKE_BINARY_DIR}/include + ) endif(BUILD_TEST) foreach(STRING_INDEX ${c_STRING_INDICES}) set(c_SRCS ${c_SRCS} x${STRING_INDEX}c.c) Modified: trunk/examples/c++/CMakeLists.txt =================================================================== --- trunk/examples/c++/CMakeLists.txt 2009-02-20 19:43:15 UTC (rev 9564) +++ trunk/examples/c++/CMakeLists.txt 2009-02-20 21:18:33 UTC (rev 9565) @@ -63,6 +63,7 @@ include_directories( ${CMAKE_SOURCE_DIR}/bindings/c++ ${CMAKE_SOURCE_DIR}/include + ${CMAKE_SOURCE_DIR}/lib/qsastime ${CMAKE_BINARY_DIR}/include ) endif(BUILD_TEST) Modified: trunk/examples/f77/CMakeLists.txt =================================================================== --- trunk/examples/f77/CMakeLists.txt 2009-02-20 19:43:15 UTC (rev 9564) +++ trunk/examples/f77/CMakeLists.txt 2009-02-20 21:18:33 UTC (rev 9565) @@ -95,7 +95,11 @@ if(BUILD_TEST) remove_definitions("-DHAVE_CONFIG_H") - include_directories(${CMAKE_SOURCE_DIR}/include ${CMAKE_BINARY_DIR}/include) + include_directories( + ${CMAKE_SOURCE_DIR}/include + ${CMAKE_SOURCE_DIR}/lib/qsastime + ${CMAKE_BINARY_DIR}/include + ) endif(BUILD_TEST) foreach(STRING_INDEX ${f77_STRING_INDICES}) if(BUILD_TEST) Modified: trunk/examples/f95/CMakeLists.txt =================================================================== --- trunk/examples/f95/CMakeLists.txt 2009-02-20 19:43:15 UTC (rev 9564) +++ trunk/examples/f95/CMakeLists.txt 2009-02-20 21:18:33 UTC (rev 9565) @@ -67,7 +67,10 @@ ) set_source_files_properties(${CMAKE_CURRENT_BINARY_DIR}/plf95demos.inc PROPERTIES GENERATED ON) -include_directories(${CMAKE_CURRENT_BINARY_DIR}) +include_directories( + ${CMAKE_CURRENT_BINARY_DIR} + ${CMAKE_SOURCE_DIR}/lib/qsastime + ) if(BUILD_TEST) remove_definitions("-DHAVE_CONFIG_H") Modified: trunk/include/plstrm.h =================================================================== --- trunk/include/plstrm.h 2009-02-20 19:43:15 UTC (rev 9564) +++ trunk/include/plstrm.h 2009-02-20 21:18:33 UTC (rev 9565) @@ -30,6 +30,7 @@ #include "disptab.h" #include "pldll.h" +#include "qsastime.h" /*--------------------------------------------------------------------------*\ * Define the PLDev data structure. @@ -478,6 +479,15 @@ * for hexpower = 4-6 so there is room for expansion of this scheme into more * font attributes if required. (hexpower = 7 is reserved for the 0x8 marker * of the FCI.) + * + **************************************************************************** + * + * Time related variable + * + * qsasconfig is a pointer to a struct that keeps track of the details + * of the transformation between broken-down and continuous time used + * in the qsastime library. + * \*--------------------------------------------------------------------------*/ #define PL_MAX_CMAP1CP 256 @@ -711,7 +721,12 @@ */ void *psdoc; + /* pointer to a struct that keeps track of the details of the + transformation between broken-down and continuous time used in + the qsastime library. */ + QSASConfig *qsasconfig; + } PLStream; /*--------------------------------------------------------------------------*\ Modified: trunk/src/plbox.c =================================================================== --- trunk/src/plbox.c 2009-02-20 19:43:15 UTC (rev 9564) +++ trunk/src/plbox.c 2009-02-20 21:18:33 UTC (rev 9565) @@ -23,7 +23,6 @@ */ #include "plplotP.h" -#include "qsastime.h" #define STRING_LEN 40 #define FORMAT_LEN 10 @@ -1206,7 +1205,6 @@ const char *timefmt; double tm; double t; - QSASConfig *qsasconfig = NULL; /* Set plot options from input */ @@ -1253,10 +1251,10 @@ for (tn = tp; BETW(tn, vpwxmi, vpwxma); tn += xtick1) { if (ldx) { t = (double) tn; - configqsas(1./86400., 0., 0., 0x0, 1, 1970, 0, 1, 0, 0, 0., &qsasconfig); - ctimeqsas(1970,0,1,0,0,t,&tm, qsasconfig); - strfqsas(string, STRING_LEN, timefmt, tm, qsasconfig); - closeqsas(&qsasconfig); + configqsas(1./86400., 0., 0., 0x0, 1, 1970, 0, 1, 0, 0, 0., &(plsc->qsasconfig)); + ctimeqsas(1970,0,1,0,0,t,&tm, plsc->qsasconfig); + strfqsas(string, STRING_LEN, timefmt, tm, plsc->qsasconfig); + closeqsas(&(plsc->qsasconfig)); } else { plform(tn, xscale, xprec, string, STRING_LEN, llx, lfx); @@ -1304,10 +1302,10 @@ for (tn = tp; BETW(tn, vpwymi, vpwyma); tn += ytick1) { if (ldy) { t = (double) tn; - configqsas(1./86400., 0., 0., 0x0, 1, 1970, 0, 1, 0, 0, 0., &qsasconfig); - ctimeqsas(1970,0,1,0,0,t,&tm, qsasconfig); - strfqsas(string, STRING_LEN, timefmt, tm, qsasconfig); - closeqsas(&qsasconfig); + configqsas(1./86400., 0., 0., 0x0, 1, 1970, 0, 1, 0, 0, 0., &(plsc->qsasconfig)); + ctimeqsas(1970,0,1,0,0,t,&tm, plsc->qsasconfig); + strfqsas(string, STRING_LEN, timefmt, tm, plsc->qsasconfig); + closeqsas(&(plsc->qsasconfig)); } else { plform(tn, yscale, yprec, string, STRING_LEN, lly, lfy); Modified: trunk/utils/CMakeLists.txt =================================================================== --- trunk/utils/CMakeLists.txt 2009-02-20 19:43:15 UTC (rev 9564) +++ trunk/utils/CMakeLists.txt 2009-02-20 21:18:33 UTC (rev 9565) @@ -21,6 +21,7 @@ include_directories( ${CMAKE_SOURCE_DIR}/include + ${CMAKE_SOURCE_DIR}/lib/qsastime ${CMAKE_BINARY_DIR} ${CMAKE_BINARY_DIR}/include ) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |