KiCad PCB EDA Suite
|
#include "plugins/3d/3d_plugin.h"
#include "plugins/3dapi/ifsg_all.h"
#include "richio.h"
#include "vrml1_base.h"
#include "vrml2_base.h"
#include "wrlproc.h"
#include "x3d.h"
#include <clocale>
#include <wx/filename.h>
#include <wx/stdpaths.h>
#include <wx/string.h>
#include <wx/wfstream.h>
#include <wx/log.h>
#include <decompress.hpp>
Go to the source code of this file.
Classes | |
struct | FILE_DATA |
class | LOCALESWITCH |
Macros | |
#define | PLUGIN_VRML_MAJOR 1 |
#define | PLUGIN_VRML_MINOR 3 |
#define | PLUGIN_VRML_PATCH 2 |
#define | PLUGIN_VRML_REVNO 2 |
Functions | |
const char * | GetKicadPluginName (void) |
Function GetKicadPluginName returns the name of the plugin instance; for example IDFv3. | |
void | GetPluginVersion (unsigned char *Major, unsigned char *Minor, unsigned char *Patch, unsigned char *Revision) |
Function GetPluginVersion retrieves the version of the instantiated plugin for informational purposes. | |
int | GetNExtensions (void) |
Function GetNExtensions. | |
char const * | GetModelExtension (int aIndex) |
Function GetModelExtension. | |
int | GetNFilters (void) |
Function GetNFilters. | |
char const * | GetFileFilter (int aIndex) |
Function GetFileFilter. | |
bool | CanRender (void) |
Function CanRender. | |
SCENEGRAPH * | LoadVRML (const wxString &aFileName, bool useInline) |
SCENEGRAPH * | LoadX3D (const wxString &aFileName) |
SCENEGRAPH * | Load (char const *aFileName) |
reads a model file and creates a generic display structure | |
Variables | |
const wxChar *const | traceVrmlPlugin = wxT( "KICAD_VRML_PLUGIN" ) |
Flag to enable VRML plugin trace output. | |
static struct FILE_DATA | file_data |
bool CanRender | ( | void | ) |
char const * GetFileFilter | ( | int | aIndex | ) |
Function GetFileFilter.
Definition at line 134 of file vrml.cpp.
References file_data, FILE_DATA::filters, and NFILS.
const char * GetKicadPluginName | ( | void | ) |
Function GetKicadPluginName returns the name of the plugin instance; for example IDFv3.
This string may be used to check for name conflicts or to display informational messages about loaded plugins. This method must be implemented in specific instantiations of a plugin class.
char const * GetModelExtension | ( | int | aIndex | ) |
Function GetModelExtension.
aIndex | is the extension to return; valid values are 0 to GetNExtensions() - 1. |
Definition at line 119 of file vrml.cpp.
References FILE_DATA::extensions, file_data, and NEXTS.
int GetNExtensions | ( | void | ) |
Function GetNExtensions.
Definition at line 113 of file vrml.cpp.
References FILE_DATA::extensions, file_data, and NEXTS.
int GetNFilters | ( | void | ) |
Function GetNFilters.
Definition at line 128 of file vrml.cpp.
References file_data, FILE_DATA::filters, and NFILS.
void GetPluginVersion | ( | unsigned char * | Major, |
unsigned char * | Minor, | ||
unsigned char * | Patch, | ||
unsigned char * | Revision | ||
) |
Function GetPluginVersion retrieves the version of the instantiated plugin for informational purposes.
Do not confuse this with GetClassVersion which is used to determine API compatibility.
Major | will hold the Plugin Major version |
Minor | will hold the Plugin Minor version |
Patch | will hold the Plugin Patch level |
Revision | will hold the Plugin Revision |
Definition at line 72 of file vrml.cpp.
References PLUGIN_3D_IDF_MAJOR, PLUGIN_3D_IDF_MINOR, PLUGIN_3D_IDF_PATCH, PLUGIN_3D_IDF_REVNO, PLUGIN_VRML_MAJOR, PLUGIN_VRML_MINOR, PLUGIN_VRML_PATCH, and PLUGIN_VRML_REVNO.
SCENEGRAPH * Load | ( | char const * | aFileName | ) |
reads a model file and creates a generic display structure
aFileName | is the full path of the model file |
Definition at line 331 of file vrml.cpp.
References loadIDFBoard(), loadIDFOutline(), LoadVRML(), LoadX3D(), and S3D::WriteVRML().
Referenced by CADSTAR_ARCHIVE_PARSER::PART::DEFINITION::PIN::Parse().
SCENEGRAPH * LoadVRML | ( | const wxString & | aFileName, |
bool | useInline | ||
) |
Definition at line 170 of file vrml.cpp.
References _, WRLPROC::GetVRMLType(), WRL1BASE::Read(), WRL2BASE::Read(), WRL2BASE::SetEnableInline(), traceVrmlPlugin, WRL2BASE::TranslateToSG(), WRL1BASE::TranslateToSG(), VRML_V1, IO_ERROR::What(), and S3D::WriteVRML().
Referenced by WRL2BASE::GetInlineData(), and Load().
SCENEGRAPH * LoadX3D | ( | const wxString & | aFileName | ) |
|
static |
Referenced by GetFileFilter(), GetModelExtension(), GetNExtensions(), and GetNFilters().