KiCad PCB EDA Suite
Loading...
Searching...
No Matches
JOB_PCB_RENDER Class Reference

#include <job_pcb_render.h>

Inheritance diagram for JOB_PCB_RENDER:
JOB

Public Types

enum class  FORMAT { PNG , JPEG }
 
enum class  QUALITY { BASIC , HIGH , USER , JOB_SETTINGS }
 
enum class  BG_STYLE { DEFAULT , TRANSPARENT , OPAQUE }
 
enum class  SIDE {
  TOP , BOTTOM , LEFT , RIGHT ,
  FRONT , BACK
}
 

Public Member Functions

 JOB_PCB_RENDER ()
 
wxString GetDefaultDescription () const override
 
wxString GetSettingsDialogTitle () const override
 
const std::string & GetType () const
 
const std::map< wxString, wxString > & GetVarOverrides () const
 
void SetVarOverrides (const std::map< wxString, wxString > &aVarOverrides)
 
void SetTitleBlock (const TITLE_BLOCK &aTitleBlock)
 
virtual void FromJson (const nlohmann::json &j)
 
virtual void ToJson (nlohmann::json &j) const
 
const std::vector< JOB_PARAM_BASE * > & GetParams ()
 
void ClearExistingOutputs ()
 
const std::vector< JOB_OUTPUT > & GetOutputs ()
 
void AddOutput (wxString aOutputPath)
 
void SetTempOutputDirectory (const wxString &aBase)
 Sets the temporary output directory for the job, this is used to prefix with a given output path when GetFullOutputPath is called.
 
void SetConfiguredOutputPath (const wxString &aPath)
 Sets the configured output path for the job, this path is always saved to file.
 
wxString GetConfiguredOutputPath () const
 Returns the configured output path for the job.
 
void SetWorkingOutputPath (const wxString &aPath)
 Sets a transient output path for the job, it takes priority over the configured output path when GetFullOutputPath is called.
 
wxString GetWorkingOutputPath () const
 Returns the working output path for the job, if one has been set.
 
wxString GetFullOutputPath (PROJECT *aProject) const
 Returns the full output path for the job, taking into account the configured output path, any configured working path and the temporary output directory.
 
bool GetOutputPathIsDirectory () const
 

Static Public Member Functions

static std::map< JOB_PCB_RENDER::FORMAT, wxString > & GetFormatNameMap ()
 

Public Attributes

wxString m_filename
 
FORMAT m_format = FORMAT::PNG
 
QUALITY m_quality = QUALITY::BASIC
 
BG_STYLE m_bgStyle = BG_STYLE::DEFAULT
 
int m_width = 0
 
int m_height = 0
 
std::string m_appearancePreset
 
bool m_useBoardStackupColors = true
 
SIDE m_side = SIDE::TOP
 
double m_zoom = 1.0
 
bool m_perspective = false
 
VECTOR3D m_rotation
 
VECTOR3D m_pan
 
VECTOR3D m_pivot
 
bool m_proceduralTextures = false
 
bool m_floor = false
 
bool m_antiAlias = true
 
bool m_postProcess = false
 
VECTOR3D m_lightTopIntensity
 
VECTOR3D m_lightBottomIntensity
 
VECTOR3D m_lightCameraIntensity
 
VECTOR3D m_lightSideIntensity = VECTOR3D( 0.5, 0.5, 0.5 )
 
int m_lightSideElevation = 60
 

Protected Attributes

std::string m_type
 
std::map< wxString, wxString > m_varOverrides
 
TITLE_BLOCK m_titleBlock
 
wxString m_tempOutputDirectory
 
wxString m_outputPath
 
bool m_outputPathIsDirectory
 
wxString m_description
 
wxString m_workingOutputPath
 
std::vector< JOB_PARAM_BASE * > m_params
 
std::vector< JOB_OUTPUTm_outputs
 

Detailed Description

Definition at line 39 of file job_pcb_render.h.

Member Enumeration Documentation

◆ BG_STYLE

enum class JOB_PCB_RENDER::BG_STYLE
strong
Enumerator
DEFAULT 
TRANSPARENT 
OPAQUE 

Definition at line 66 of file job_pcb_render.h.

◆ FORMAT

enum class JOB_PCB_RENDER::FORMAT
strong
Enumerator
PNG 
JPEG 

Definition at line 42 of file job_pcb_render.h.

◆ QUALITY

enum class JOB_PCB_RENDER::QUALITY
strong
Enumerator
BASIC 
HIGH 
USER 
JOB_SETTINGS 

Definition at line 58 of file job_pcb_render.h.

◆ SIDE

enum class JOB_PCB_RENDER::SIDE
strong
Enumerator
TOP 
BOTTOM 
LEFT 
RIGHT 
FRONT 
BACK 

Definition at line 73 of file job_pcb_render.h.

Constructor & Destructor Documentation

◆ JOB_PCB_RENDER()

Member Function Documentation

◆ AddOutput()

void JOB::AddOutput ( wxString aOutputPath)
inlineinherited

Definition at line 215 of file job.h.

References m_outputs.

Referenced by PCBNEW_JOBS_HANDLER::JobExportPos().

◆ ClearExistingOutputs()

void JOB::ClearExistingOutputs ( )
inlineinherited

Definition at line 213 of file job.h.

References m_outputs.

Referenced by JOB_DISPATCHER::RunJob().

◆ FromJson()

void JOB::FromJson ( const nlohmann::json & j)
virtualinherited

Definition at line 60 of file job.cpp.

References m_params.

Referenced by from_json(), and from_json().

◆ GetConfiguredOutputPath()

◆ GetDefaultDescription()

wxString JOB_PCB_RENDER::GetDefaultDescription ( ) const
overridevirtual

Reimplemented from JOB.

Definition at line 130 of file job_pcb_render.cpp.

References _, GetFormatNameMap(), and m_format.

◆ GetFormatNameMap()

std::map< JOB_PCB_RENDER::FORMAT, wxString > & JOB_PCB_RENDER::GetFormatNameMap ( )
static

◆ GetFullOutputPath()

◆ GetOutputPathIsDirectory()

bool JOB::GetOutputPathIsDirectory ( ) const
inlineinherited

Definition at line 253 of file job.h.

References m_outputPathIsDirectory.

Referenced by EESCHEMA_JOBS_HANDLER::JobExportPlot().

◆ GetOutputs()

const std::vector< JOB_OUTPUT > & JOB::GetOutputs ( )
inlineinherited

Definition at line 214 of file job.h.

References m_outputs.

◆ GetParams()

const std::vector< JOB_PARAM_BASE * > & JOB::GetParams ( )
inlineinherited

Definition at line 211 of file job.h.

References m_params.

◆ GetSettingsDialogTitle()

wxString JOB_PCB_RENDER::GetSettingsDialogTitle ( ) const
overridevirtual

Reimplemented from JOB.

Definition at line 136 of file job_pcb_render.cpp.

References _.

Referenced by DIALOG_RENDER_JOB::DIALOG_RENDER_JOB().

◆ GetType()

const std::string & JOB::GetType ( ) const
inlineinherited

◆ GetVarOverrides()

◆ GetWorkingOutputPath()

wxString JOB::GetWorkingOutputPath ( ) const
inlineinherited

Returns the working output path for the job, if one has been set.

Definition at line 243 of file job.h.

References m_workingOutputPath.

◆ SetConfiguredOutputPath()

◆ SetTempOutputDirectory()

void JOB::SetTempOutputDirectory ( const wxString & aBase)
inherited

Sets the temporary output directory for the job, this is used to prefix with a given output path when GetFullOutputPath is called.

This is intended for use with running jobsets and otherwise has no impact on individual job runs outside jobsets.

Definition at line 86 of file job.cpp.

References m_tempOutputDirectory.

◆ SetTitleBlock()

◆ SetVarOverrides()

void JOB::SetVarOverrides ( const std::map< wxString, wxString > & aVarOverrides)
inlineinherited

Definition at line 198 of file job.h.

References m_varOverrides.

Referenced by CLI::PCB_EXPORT_GERBER_COMMAND::populateJob().

◆ SetWorkingOutputPath()

◆ ToJson()

void JOB::ToJson ( nlohmann::json & j) const
virtualinherited

Definition at line 67 of file job.cpp.

References m_params.

Referenced by to_json().

Member Data Documentation

◆ m_antiAlias

bool JOB_PCB_RENDER::m_antiAlias = true

Definition at line 98 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_appearancePreset

std::string JOB_PCB_RENDER::m_appearancePreset

Definition at line 88 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_bgStyle

BG_STYLE JOB_PCB_RENDER::m_bgStyle = BG_STYLE::DEFAULT

Definition at line 85 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_description

wxString JOB::m_description
protectedinherited

Definition at line 264 of file job.h.

Referenced by JOB().

◆ m_filename

wxString JOB_PCB_RENDER::m_filename

Definition at line 55 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_floor

bool JOB_PCB_RENDER::m_floor = false

Definition at line 97 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_format

FORMAT JOB_PCB_RENDER::m_format = FORMAT::PNG

◆ m_height

int JOB_PCB_RENDER::m_height = 0

Definition at line 87 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_lightBottomIntensity

VECTOR3D JOB_PCB_RENDER::m_lightBottomIntensity

Definition at line 101 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_lightCameraIntensity

VECTOR3D JOB_PCB_RENDER::m_lightCameraIntensity

Definition at line 102 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_lightSideElevation

int JOB_PCB_RENDER::m_lightSideElevation = 60

Definition at line 104 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_lightSideIntensity

VECTOR3D JOB_PCB_RENDER::m_lightSideIntensity = VECTOR3D( 0.5, 0.5, 0.5 )

Definition at line 103 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_lightTopIntensity

VECTOR3D JOB_PCB_RENDER::m_lightTopIntensity

Definition at line 100 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_outputPath

wxString JOB::m_outputPath
protectedinherited

Definition at line 262 of file job.h.

Referenced by GetConfiguredOutputPath(), GetFullOutputPath(), JOB(), and SetConfiguredOutputPath().

◆ m_outputPathIsDirectory

bool JOB::m_outputPathIsDirectory
protectedinherited

Definition at line 263 of file job.h.

Referenced by GetFullOutputPath(), GetOutputPathIsDirectory(), and JOB().

◆ m_outputs

std::vector<JOB_OUTPUT> JOB::m_outputs
protectedinherited

Definition at line 269 of file job.h.

Referenced by AddOutput(), ClearExistingOutputs(), and GetOutputs().

◆ m_pan

VECTOR3D JOB_PCB_RENDER::m_pan

Definition at line 94 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_params

◆ m_perspective

bool JOB_PCB_RENDER::m_perspective = false

Definition at line 92 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_pivot

VECTOR3D JOB_PCB_RENDER::m_pivot

Definition at line 95 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_postProcess

bool JOB_PCB_RENDER::m_postProcess = false

Definition at line 99 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_proceduralTextures

bool JOB_PCB_RENDER::m_proceduralTextures = false

Definition at line 96 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_quality

QUALITY JOB_PCB_RENDER::m_quality = QUALITY::BASIC

Definition at line 84 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_rotation

VECTOR3D JOB_PCB_RENDER::m_rotation

Definition at line 93 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_side

SIDE JOB_PCB_RENDER::m_side = SIDE::TOP

Definition at line 90 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_tempOutputDirectory

wxString JOB::m_tempOutputDirectory
protectedinherited

Definition at line 260 of file job.h.

Referenced by GetFullOutputPath(), JOB(), and SetTempOutputDirectory().

◆ m_titleBlock

TITLE_BLOCK JOB::m_titleBlock
protectedinherited

Definition at line 258 of file job.h.

Referenced by GetFullOutputPath(), and SetTitleBlock().

◆ m_type

std::string JOB::m_type
protectedinherited

Definition at line 256 of file job.h.

Referenced by GetType(), and JOB().

◆ m_useBoardStackupColors

bool JOB_PCB_RENDER::m_useBoardStackupColors = true

Definition at line 89 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_varOverrides

std::map<wxString, wxString> JOB::m_varOverrides
protectedinherited

Definition at line 257 of file job.h.

Referenced by GetVarOverrides(), JOB(), and SetVarOverrides().

◆ m_width

int JOB_PCB_RENDER::m_width = 0

Definition at line 86 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().

◆ m_workingOutputPath

wxString JOB::m_workingOutputPath
protectedinherited

Definition at line 265 of file job.h.

Referenced by GetFullOutputPath(), GetWorkingOutputPath(), JOB(), and SetWorkingOutputPath().

◆ m_zoom

double JOB_PCB_RENDER::m_zoom = 1.0

Definition at line 91 of file job_pcb_render.h.

Referenced by JOB_PCB_RENDER(), and PCBNEW_JOBS_HANDLER::JobExportRender().


The documentation for this class was generated from the following files: