Difference between revisions of "Raytracing Module/sv"

From FreeCAD Documentation
Jump to: navigation, search
(Updating to match new version of source page)
(Updating to match new version of source page)
 
(4 intermediate revisions by the same user not shown)
Line 1: Line 1:
 
<languages/>
 
<languages/>
 +
{{docnav
 +
|[[Points Workbench|Points Workbench]]
 +
|[[Reverse Engineering Workbench|Reverse Engineering Workbench]]
 +
|IconL=PointsWorkbench.svg
 +
|IconR=ReverseEngineeringWorkbench.svg
 +
}}
 +
 
[[Image:Workbench_Raytracing.svg|64px]]
 
[[Image:Workbench_Raytracing.svg|64px]]
  
Line 10: Line 17:
 
Currently, two renderers are supported: [http://en.wikipedia.org/wiki/POV-Ray povray] and [http://en.wikipedia.org/wiki/LuxRender luxrender]. To be able to render from within FreeCAD, at least one of these programs must be installed and configured in your system. However, if no renderer is installed, you will still be able to export a project file to be rendered at another time.
 
Currently, two renderers are supported: [http://en.wikipedia.org/wiki/POV-Ray povray] and [http://en.wikipedia.org/wiki/LuxRender luxrender]. To be able to render from within FreeCAD, at least one of these programs must be installed and configured in your system. However, if no renderer is installed, you will still be able to export a project file to be rendered at another time.
  
A new Render Workbench has been in development to support multiple back-ends such as Lux Renderer and Yafaray. Information for using the development version can be viewed at [[Render project]]. For development status of the Render Module look into the [[Raytracing project]].
+
A new Render Workbench has been in development to support multiple back-ends such as Lux Renderer and Yafaray. Information for using the development version can be viewed at [[Render project|Render project]]. For development status of the Render Module look into the [[Raytracing project|Raytracing project]].
  
 
{{TOCright}}
 
{{TOCright}}
 
[[Image:Raytracing_example.jpg|1024px]]
 
[[Image:Raytracing_example.jpg|1024px]]
 +
 +
== Typical workflow ==
 +
# Create or open a FreeCAD project, add some solid objects ([[Part Module|Part-based]] or [[PartDesign Workbench|PartDesign-based]]); meshes are currently not supported.
 +
# Create a Raytracing project (povray or luxrender).
 +
# Select the objects that you wish to add to the Raytracing project and add them.
 +
# Export the project file or render it directly.
 +
 +
 +
[[Image:Raytracing_Workbench_workflow.svg|600px]]
 +
 +
 +
{{Caption|Workflow of the Raytracing Workbench; the workbench prepares a project file from a given template, and then calls an external program to produce the actual rendering of the scene. The external renderer can be used independently of FreeCAD.}}
  
 
=== Gränssnittsverktyg ===
 
=== Gränssnittsverktyg ===
Line 36: Line 55:
 
== Preferences ==
 
== Preferences ==
  
* [[Image:Std_DlgParameter.png|32px]] [[Raytracing_Preferences|Preferences]]: Preferences available in for the Raytracing tools.
+
* [[Image:Preferences-raytracing.svg|32px]] [[Raytracing_Preferences|Preferences]]: Preferences available in for the Raytracing tools.
  
== Typical workflow ==
+
== Tutorials ==
# Create or open a FreeCAD project, add some [[Part Module|Part-based]] objects (meshes are currently not supported)
+
* [[Raytracing_tutorial|Basic Raytracing tutorial]]
# Create a Raytracing project (luxrender or povray)
+
* [[Tutorial FreeCAD POV ray|Intermediate Raytracing tutorial]]
# Select the objects you wish to add to the raytracing project and add them to the project with the "Insert Part" tool
 
# Export or render directly
 
  
=== Creating a povray file manually ===
+
== Creating a povray file manually ==
The utility tools described above allow you to export the current 3D view and all of its content to a [http://www.povray.org/ Povray] file. First, you must load or create your CAD data and position the 3D View orientation as you wish. Then choose "Utilities->Export View..." from the raytracing menu.
+
The utility tools described above allow you to export the current 3D view and all of its content to a [http://www.povray.org/ Povray] file. First, you must load or create your CAD data and position the 3D View orientation as you wish. Then choose "Utilities Export View..." from the raytracing menu.
  
 
[[Image:FreeCAD_Raytracing.jpg|center]]
 
[[Image:FreeCAD_Raytracing.jpg|center]]
Line 57: Line 74:
 
=== Skript ===
 
=== Skript ===
  
See the [[Raytracing API example]] for information on writing scenes programmatically.
+
See the [[Raytracing API example|Raytracing API example]] for information on writing scenes programmatically.
  
 
=== Länkar ===
 
=== Länkar ===
Line 89: Line 106:
 
:Within WIndows 7 64-bit Kerkythea does not seem to be able to save these settings.
 
:Within WIndows 7 64-bit Kerkythea does not seem to be able to save these settings.
 
:So remember to do that each time you start Kerkythea
 
:So remember to do that each time you start Kerkythea
* if importing multiple objects in Kerkythea you can use the "File > Merge" command in Kerkythea
+
* if importing multiple objects in Kerkythea you can use the "File Merge" command in Kerkythea
  
==Links==
+
==Development==
 
* [[Render_project|Render project]]
 
* [[Render_project|Render project]]
* [[Raytracing_tutorial|Raytracing tutorial]]
 
  
 
<div class="mw-translate-fuzzy">
 
<div class="mw-translate-fuzzy">
 
{{docnav/sv|Drawing Module/sv|Draft Module/sv}}
 
{{docnav/sv|Drawing Module/sv|Draft Module/sv}}
 
</div>
 
</div>
 +
 +
{{Raytracing Tools navi}}
 +
{{Userdocnavi}}
 +
[[Category:Workbenches]]

Latest revision as of 10:39, 28 October 2019

Other languages:
čeština • ‎Deutsch • ‎English • ‎español • ‎français • ‎hrvatski • ‎Bahasa Indonesia • ‎italiano • ‎日本語 • ‎한국어 • ‎polski • ‎português • ‎português do Brasil • ‎română • ‎русский • ‎svenska • ‎Türkçe • ‎українська • ‎中文 • ‎中文(中国大陆)‎ • ‎中文(台灣)‎

Workbench Raytracing.svg

Denna modul är tänkt att skicka innehållet i din scen till en extern rendererare, för att generera fotorealistiska bilder på ditt arbete. Renderingsmodulen är fortfarande i ett mycket tidigt skede, så du har inte så många tillgängliga alternativ för tillfället. För närvarande finns endast ett grundläggande verktygsset för att exportera Del objekt som POV-ray filer. Dessa filer kan sedan laddas i POV-ray och renderas.

The Raytracing Workbench works with templates, which are project files that define a scene for your 3D model. You can place lights and geometry such as ground planes, and it also contains placeholders for the position of the camera, and for the material information of the objects in the scene. The project can then be exported to a ready-to-render file, or be rendered directly within FreeCAD.

Currently, two renderers are supported: povray and luxrender. To be able to render from within FreeCAD, at least one of these programs must be installed and configured in your system. However, if no renderer is installed, you will still be able to export a project file to be rendered at another time.

A new Render Workbench has been in development to support multiple back-ends such as Lux Renderer and Yafaray. Information for using the development version can be viewed at Render project. For development status of the Render Module look into the Raytracing project.

Raytracing example.jpg

Typical workflow

  1. Create or open a FreeCAD project, add some solid objects (Part-based or PartDesign-based); meshes are currently not supported.
  2. Create a Raytracing project (povray or luxrender).
  3. Select the objects that you wish to add to the Raytracing project and add them.
  4. Export the project file or render it directly.


Raytracing Workbench workflow.svg


Workflow of the Raytracing Workbench; the workbench prepares a project file from a given template, and then calls an external program to produce the actual rendering of the scene. The external renderer can be used independently of FreeCAD.


Gränssnittsverktyg

Project tools

These are the main tools for exporting your 3D work to external renderers.

  • Raytracing New.png New PovRay project: Insert new PovRay project in the document
  • Raytracing Lux.png New LuxRender project: Insert new LuxRender project in the document
  • Raytracing InsertPart.png Insert part: Insert a view of a Part in a raytracing project
  • Raytracing ResetCamera.png Reset camera: Matches the camera position of a raytracing project to the current view
  • Raytracing ExportProject.png Export project: Exports a raytracing project to a scene file for rendering in an external renderer
  • Raytracing Render.png Render: Renders a raytracing project with an external renderer

Utilities

These are helper tools to perform specific tasks manually.

Preferences

  • Preferences-raytracing.svg Preferences: Preferences available in for the Raytracing tools.

Tutorials

Creating a povray file manually

The utility tools described above allow you to export the current 3D view and all of its content to a Povray file. First, you must load or create your CAD data and position the 3D View orientation as you wish. Then choose "Utilities → Export View..." from the raytracing menu.

FreeCAD Raytracing.jpg

You will be asked for a location to save the resulting *.pov file. After that you can open it in Povray and render:

Povray.jpg

As usual in a renderer you can make big and nice pictures:

Scharniergreifer render.jpg

Skript

See the Raytracing API example for information on writing scenes programmatically.

Länkar

POVRay

Luxrender

Future possible renderers to implement

Exporting to Kerkythea

Although direct export to the Kerkythea XML-File-Format is not supported yet, you can export your Objects as Mesh-Files (.obj) and then import them in Kerkythea.

  • if using Kerkythea for Linux, remember to install the WINE-Package (needed by Kerkythea for Linux to run)
  • you can convert your models with the help of the mesh workbench to meshes and then export these meshes as .obj-files
  • If your mesh-export resulted in errors (flip of normals, holes ...) you may try your luck with netfabb studio basic
Free for personal use, available for Windows, Linux and Mac OSX.
It has standard repair tools which will repair you model in most cases.
  • another good program for mesh analysing/repairing is Meshlab
Open Source, available for Windows, Linux and Mac OSX.
It has standard repair tools which will repair you model in most cases (fill holes, re-orient normals, etc.)
  • you can use "make compound" and then "make single copy" or you can fuse solids to group them before converting to meshes
  • remember to set in Kerkythea an import-factor of 0.001 for obj-modeler, since Kerkythea expects the obj-file to be in m (but standard units-scheme in FreeCAD is mm)
Within WIndows 7 64-bit Kerkythea does not seem to be able to save these settings.
So remember to do that each time you start Kerkythea
  • if importing multiple objects in Kerkythea you can use the "File → Merge" command in Kerkythea

Development