Gwyddion – Free SPM (AFM, SNOM/NSOM, STM, MFM, …) data analysis software

gwyddion

gwyddion — Base functions, library initialization

Functions

void gwy_type_init ()
gboolean gwy_threads_are_enabled ()
void gwy_threads_set_enabled ()

Includes

#include <libgwyddion/gwyddion.h>

Description

Gwyddion classes has to be initialized before they can be safely deserialized. The function gwy_type_init() performs this initialization.

Functions

gwy_type_init ()

void
gwy_type_init (void);

Makes libgwyddion types safe for deserialization and performs other initialization. You have to call this function from the main thread before using objects from libgwyddion.

It calls g_type_init() first to make sure GLib object system is initialized.

It is safe to call this function more than once, subsequent calls are no-op.

gwy_threads_are_enabled ()

gboolean
gwy_threads_are_enabled (void);

Obtains the state of internal multithread processing.

Returns

TRUE if multithread processing is enabled; FALSE otherwise (this includes the case of Gwyddion not built with multithread processing support at all).

Since: 2.53

gwy_threads_set_enabled ()

void
gwy_threads_set_enabled (gboolean setting);

Enables or disables internal multithread processing.

Multithread processing, if enabled, is utilised internally and transparently in Gwyddion functions. No threads are exposed in the API.

The default setting is FALSE. If you run programs or scripts based on Gwyddion in parallel, for instance in a simulation or batch data processing, it is recommended to keep multithread processing disabled. For GUI programs (like Gwyddion itself) or tasks run serially, it can be useful to enable it.

If Gwyddion was not built with multithread processing support, enabling threads does not do anything and gwy_threads_are_enabled() will continue to return FALSE.

Parameters

setting

TRUE to enable multithread processing; FALSE to disable it.

 

Since: 2.53

Types and Values

See Also

GwySerializable

© David Nečas and Petr Klapetek

Home Download News Features Screenshots Documentation Communicate Participate Resources Publications Applications Site Map

Valid XHTML 1.0 Valid CSS