Giter VIP home page Giter VIP logo

swephgo's People

Contributors

elvishp2006 avatar mshafiee avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

swephgo's Issues

How does swephgo manage the underlying C TLS variables ?

Context:

  • The C.swe_set_sid_mode call inside swephgo.SetSidMode func basically points to the C implementation of original swiss ephemeris set_sid_mode func (C swiss-ephemeris latest 2.10.3 version src code ref).
  • If you check the C implementation it basically sets the sid_mode inside a datastructure variable swed which is stored in TLS (thread local storage).

Problem Statement:

Go uses go-routines to execute a function. Let's say in between while executing the swephgo.SetSidMode func, what if the go-routine switches threads (say from thread_1 to thread_2), the sid_mode set in the TLS of the thread_1 won't be availabel in the thread_2 and the function would not have worked as expected right? Or am I missing something here?

Note: I observe that there is some Mutex lock and unlock happening, but that should still not help in this "go-routine switching" threads issue IMO.

during build few functions are skipped because of unsupported parameter or result

Hi,
I really appreciate the work you have done. I was trying to build using gomobile. The build went through fine and while i was debugging the results and trying to consume the built aar file there were only few functions than i was expecting. On further digging i found in jni header file that following functions were skipped

// skipped function Azalt with unsupported parameter or result types
// skipped function AzaltRev with unsupported parameter or result types
// skipped function Calc with unsupported parameter or result types
// skipped function CalcPctr with unsupported parameter or result types
// skipped function CalcUt with unsupported parameter or result types
// skipped function Cotrans with unsupported parameter or result types
// skipped function CotransSp with unsupported parameter or result types
// skipped function Cs2degstr with unsupported parameter or result types
// skipped function Cs2lonlatstr with unsupported parameter or result types
// skipped function Cs2timestr with unsupported parameter or result types
// skipped function DateConversion with unsupported parameter or result types
// skipped function Fixstar with unsupported parameter or result types
// skipped function Fixstar2 with unsupported parameter or result types
// skipped function Fixstar2Mag with unsupported parameter or result types
// skipped function Fixstar2Ut with unsupported parameter or result types
// skipped function FixstarMag with unsupported parameter or result types
// skipped function FixstarUt with unsupported parameter or result types
// skipped function GauquelinSector with unsupported parameter or result types
// skipped function GetAyanamsaEx with unsupported parameter or result types
// skipped function GetAyanamsaExUt with unsupported parameter or result types
// skipped function GetCurrentFileData with unsupported parameter or result types
// skipped function GetLibraryPath with unsupported parameter or result types
// skipped function GetOrbitalElements with unsupported parameter or result types
// skipped function GetPlanetName with unsupported parameter or result types
// skipped function HeliacalAngle with unsupported parameter or result types
// skipped function HeliacalPhenoUt with unsupported parameter or result types
// skipped function HeliacalUt with unsupported parameter or result types
// skipped function HouseName with unsupported parameter or result types
// skipped function HousePos with unsupported parameter or result types
// skipped function Houses with unsupported parameter or result types
// skipped function HousesArmc with unsupported parameter or result types
// skipped function HousesArmcEx2 with unsupported parameter or result types
// skipped function HousesEx with unsupported parameter or result types
// skipped function HousesEx2 with unsupported parameter or result types
// skipped function JdetToUtc with unsupported parameter or result types
// skipped function Jdut1ToUtc with unsupported parameter or result types
// skipped function LatToLmt with unsupported parameter or result types
// skipped function LmtToLat with unsupported parameter or result types
// skipped function LunEclipseHow with unsupported parameter or result types
// skipped function LunEclipseWhen with unsupported parameter or result types
// skipped function LunEclipseWhenLoc with unsupported parameter or result types
// skipped function LunOccultWhenGlob with unsupported parameter or result types
// skipped function LunOccultWhenLoc with unsupported parameter or result types
// skipped function LunOccultWhere with unsupported parameter or result types
// skipped function NewSweDataRef with unsupported parameter or result types
// skipped function NodAps with unsupported parameter or result types
// skipped function NodApsUt with unsupported parameter or result types
// skipped function OrbitMaxMinTrueDistance with unsupported parameter or result types
// skipped function Pheno with unsupported parameter or result types
// skipped function PhenoUt with unsupported parameter or result types
// skipped function RefracExtended with unsupported parameter or result types
// skipped function Revjul with unsupported parameter or result types
// skipped function RiseTrans with unsupported parameter or result types
// skipped function RiseTransTrueHor with unsupported parameter or result types

i would like to work on resolving these, if you know fixes for them would be happy to take it forward and enable all the functions to get exported. As you can see currently most of the major functions are skipped.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.