Commit Graph

518 Commits

Author SHA1 Message Date
Campbell Barton
93e3107806 select loose wasn't working very usefully if you only wanted to select loose verts, now select loose verts/edges/faces depending on the selection mode. 2013-04-29 16:59:53 +00:00
Campbell Barton
9a269f3a1f update sphinx docgen
was missing context property attributes - context.mode for example. add RNA properties into context docs.

also minor updates
- exclude freestyle if its not enabled.
- add missing context member.
2013-04-29 16:20:49 +00:00
Bastien Montagne
eaf1e7a888 Py API doc generation: add bpy.app.translations module, and fix a few errors found while building the doc. Thanks to Campbell for review. 2013-04-19 13:00:21 +00:00
Mitchell Stokes
d2b14ed4f0 BGE: Adding mipmapping control to bge.render via bge.render.setMipmapping() and bge.render.getMipmapping(). 2013-04-14 00:40:24 +00:00
Mitchell Stokes
dbf4328f3f BGE: Adding a render.setFullScreen() and a render.getFullScreen() to allow fulscreening games via Python. 2013-04-13 21:09:02 +00:00
Campbell Barton
eb495b2a8a use lowercase name for freestyle module (as with all other blender modules). 2013-04-07 11:22:54 +00:00
Tamito Kajiyama
4c42f5c8a9 Missing updates in the doc/ and intern/ folders during the merger in revision 55847. 2013-04-07 06:56:49 +00:00
Brecht Van Lommel
d579ea2901 Fix #34863: bge.render.makeScreenshot from Blender was only saving PNG files,
while the docs said it followed the settings in the Output panel, other file
formats work now.

Benderplayer still only saves PNG now as documented, but I cleaned up the code
there to reuse existing imbuf functions rather than using own libpng code.
2013-04-04 14:00:31 +00:00
Mitchell Stokes
460d21af6f BGE: Adding docs for bge.logic.getProfileInfo(). 2013-03-19 04:56:51 +00:00
Lukas Toenne
4638e5f99a Merge of the PyNodes branch (aka "custom nodes") into trunk.
PyNodes opens up the node system in Blender to scripters and adds a number of UI-level improvements.

=== Dynamic node type registration ===
Node types can now be added at runtime, using the RNA registration mechanism from python. This enables addons such as render engines to create a complete user interface with nodes.

Examples of how such nodes can be defined can be found in my personal wiki docs atm [1] and as a script template in release/scripts/templates_py/custom_nodes.py [2].

=== Node group improvements ===
Each node editor now has a tree history of edited node groups, which allows opening and editing nested node groups. The node editor also supports pinning now, so that different spaces can be used to edit different node groups simultaneously. For more ramblings and rationale see (really old) blog post on code.blender.org [3].

The interface of node groups has been overhauled. Sockets of a node group are no longer displayed in columns on either side, but instead special input/output nodes are used to mirror group sockets inside a node tree. This solves the problem of long node lines in groups and allows more adaptable node layout. Internal sockets can be exposed from a group by either connecting to the extension sockets in input/output nodes (shown as empty circle) or by adding sockets from the node property bar in the "Interface" panel. Further details such as the socket name can also be changed there.

[1] http://wiki.blender.org/index.php/User:Phonybone/Python_Nodes
[2] http://projects.blender.org/scm/viewvc.php/trunk/blender/release/scripts/templates_py/custom_nodes.py?view=markup&root=bf-blender
[3] http://code.blender.org/index.php/2012/01/improving-node-group-interface-editing/
2013-03-18 16:34:57 +00:00
Dalai Felinto
748dd18de4 rst doc update: adding a link to Joystick class from bge.logic.joysticks
(so one can find more about the joystick class without having to search joystick)
code untested by the way. Sorry but I can no longer build sphinx docs here. I will try to fix that later.
2013-02-28 05:18:47 +00:00
Brecht Van Lommel
10f2ad1663 CMake: update cmake.txt documentation to remove some old information and link
to the wiki for detailed cmake build setup instructions.
2013-02-26 00:49:45 +00:00
Brecht Van Lommel
2f69029db6 bf-members.txt encoding changed from Mac Roman to UTF-8 so it displays properly
cross platform, patch by Lawrence D'Oliveiro.
2013-02-21 18:07:59 +00:00
Campbell Barton
a8ebc1b2de edits to document uploading script so the latest release docs can always be found at:
http://www.blender.org/documentation/blender_python_api

Easier for linking wiki docs.
2013-02-20 14:22:36 +00:00
Campbell Barton
648f925017 misc changes
- update man page for new additions since last release.
- note that --start-console argument is windows only.
- correct own assertion in own recent commit.
2013-02-14 05:02:20 +00:00
Mitchell Stokes
372cf93309 BGE: Splitting up the bge.types docs so they are not all on the same page. This should make them much easier to browse. 2013-02-10 06:13:26 +00:00
Bastien Montagne
23aa0c9067 Fix uilists showing data names translated (reported on bf-translations ML by Satoshi Yamasaki aka yamyam, thanks!). 2013-02-08 16:01:21 +00:00
Campbell Barton
ec97183876 add python api docstring for 'bpy.types.Operator.bl_property' 2013-02-05 05:09:19 +00:00
Mitchell Stokes
9191b783bb BGE: Some various changes to make moving the character physics type easier:
* Undoing the previous applyMovement() changes for characters. This was causing bugs for the Motion Actuator.
  * Creating a Character Motion type for the Motion Actuator with specific controls for characters. This includes moving, rotating and jumping.
  * Adding a KX_CharacterWrapper.walkDirection to set the character's direction and speed.

Note, this also resolves the following bugs:
[#33585] "Setting dLoc of motion actuator [0,0,0] via python won't stop object" reported by Manuel Bellersen (urfoex)
[#33503] "Character physics type won´t accept more than one motion anymore" reported by Mr Larodos
2013-01-30 05:55:17 +00:00
Campbell Barton
a1a8e43d5a BGE Py API docs: correct references to bge.keys 2013-01-28 06:39:23 +00:00
Campbell Barton
97d8e34d61 correct addon tutorial section on keymap register/unregister and add label next to image color-depth option.
having buttons labelled [8, 16] on their own is not very meaningful.
2013-01-22 06:41:12 +00:00
Campbell Barton
769ab3eed8 code cleanup:
- cycles ui used 'cscene' for scene.cycles and scene.cycles_curves
- style cleanup
2013-01-15 23:17:45 +00:00
Campbell Barton
9f2e845181 code cleanup: use BMW_begin insode for loops body. 2013-01-14 09:53:56 +00:00
Lukas Toenne
123191881b Added some python API examples for the new get/set callbacks in bpy.props. 2013-01-05 15:50:51 +00:00
Bastien Montagne
9b9da2820b Adding some example for new UIList... 2013-01-05 11:14:35 +00:00
Campbell Barton
e9c7aaaa3c patch [#33609] Syntax highlighting for OSL in Text Editor
from Patrick Boelens (senshi). with modifications to split it into its own function.

also added C style multi-line comment support /* ... */

I've left out the part of this patch that sets the language in the space, since I think this might be better stored in the text block.

For now it simply uses OSL syntax highlighting when the extension is '.osl'.
2012-12-29 18:25:03 +00:00
Campbell Barton
4ed4be1fc2 example use of addon preferences. 2012-12-29 11:07:31 +00:00
Mitchell Stokes
18f134304c BGE: Adding a jumpCount to KX_CharacterWrapper. This can be used to have different logic for a single jump versus a double jump. For example, a different animation for the second jump. 2012-12-29 10:22:19 +00:00
Mitchell Stokes
13f49f3101 BGE: Adding a maxJumps to the character controller to adjust how many jumps a character can perform before having to touch the ground. By default this is set to 1, which means a character can only jump once before having to touch the ground again. Setting this to 2 allows for double jumping. 2012-12-26 01:25:53 +00:00
Mitchell Stokes
84966c3d0a BGE: Committing async LibLoad from Swiss. This does the lib loading in a separate thread to keep the BGE from freezing. Here is an example from the docs:
# Print a message when an async LibLoad is done
      import bge

      def finished_cb(status):
          print("Library (%s) loaded in %.2fms." % (status.libraryName, status.timeTaken))

      bge.logic.LibLoad('myblend.blend', 'Scene', async=True).onFinish = finished_cb

LibLoad() now returns a KX_LibLoadStatus object for information on the library loading. LibNew() and LibFree() are unaffected by this commit. In other words, the async option only works for LibLoad(). Furthermore it only works for Scenes, not Actions or Meshes.
2012-12-22 05:38:32 +00:00
Mitchell Stokes
f2f2b6153a BGE: Adding a Python interface for handling joysticks without needing logic bricks. These new SCA_PythonJoystick objects can be accessed using bge.logic.joysticks, which is a list of joysticks. The length of the list is the number of maximum supported joysticks, and indexes that do not have a joystick available are set to None. This means joysticks can be checked for using something like:
if bge.logic.joysticks[0]:
    activate_player_one()

if bge.logic.joysticks[1]:
    activate_player_two()

etc..

The interface exposed by SCA_PythonJoystick is very similar to the joystick logic brick except for one key difference: axis values are normalized to a -1.0 to 1.0 range instead of -32767 to 32767, which is what the logic brick exposed.
2012-12-21 02:28:59 +00:00
Campbell Barton
a6e9c9fda0 update api changelog 2012-12-11 02:13:42 +00:00
Campbell Barton
4fd9df25c6 Add 2 documents to the python api reference.
- Blender/Python Addon Tutorial: a step by step guide on how to write an addon from scratch

- Blender/Python API Reference Usage: examples of how to use the API reference docs

Thanks to John Nyquist for editing these docs and giving feedback.
2012-12-07 05:27:09 +00:00
Campbell Barton
57d7c1f226 pydna experimental ctypes DNA api was broken with more recent python versions, and some minor doc edits. 2012-12-05 03:38:01 +00:00
Campbell Barton
af51827dda add a message when solidify is used with only-edges, this isn't properly supported.
also minor edits to py-api-ref
-- This line, and those below, will be ignored--

M    doc/python_api/sphinx_doc_gen.py
M    doc/python_api/rst/include__bmesh.rst
M    source/blender/modifiers/intern/MOD_solidify.c
2012-12-05 01:02:41 +00:00
Campbell Barton
c0078a9879 osl style cleanup and update man-page. 2012-12-04 03:18:08 +00:00
Campbell Barton
ca25fd0307 fix [#33389] Curve points restricted to 0..1 range,
also added note on python3.3's faulthandler module.
2012-12-03 07:10:31 +00:00
Campbell Barton
61da29996a fix own mistake with recent commit to skip calculating tessface. If you were already in editmode the tessfaces wouldn't get recalculated.
also minor edits to bmesh rst.
2012-12-03 02:26:13 +00:00
Campbell Barton
f7f4148b40 change uiButGetStrInfo() to use a trailing NULL arg rather then passing the number of args as an arg. 2012-12-02 04:51:15 +00:00
Campbell Barton
b290f9a6cc add bmesh.free() to example & template 2012-12-01 07:16:08 +00:00
Brecht Van Lommel
c3e1813820 Fix related to #33340: add a warning to bge from_id documentation to not store id()
in game object integer properties since it may not fit in 32 bits integers.
2012-11-29 01:25:38 +00:00
Campbell Barton
f828a318f5 include an example in the api docs for using bmesh operators to make 2 links in a chain. 2012-11-28 15:08:45 +00:00
Campbell Barton
4fe35721e6 bmesh operator api reference - add in 'bmesh' arg at the start of each operator, also use :class: references. 2012-11-28 01:14:11 +00:00
Campbell Barton
9775f1d743 generate api reference for 'bmesh.ops', restructured text is extracted from bmesh_opdefines.c.
see:
http://www.blender.org/documentation/blender_python_api_2_64_9/bmesh.ops.html
2012-11-27 06:56:51 +00:00
Campbell Barton
0a5d44588c switch verious references from py3.2 -> 3.3 or just 3. 2012-11-26 13:58:06 +00:00
Mitchell Stokes
f22fb939d3 BGE Docs: Adding some docs for some of the Steering Actuator attributes. I grabbed the docs from the UI descriptions from RNA for the Steering Actuator. However, these aren't the best descriptions, and both the UI descriptions and the docs could use some attention. Also, steeringVec and facingMode didn't have corresponding UI elements, so I've left them undocumented for now. Someone who knows what they do can hopefully document them. 2012-11-23 07:47:53 +00:00
Mitchell Stokes
c6f98cfa95 BGE Docs: Adding docs for bge.logic.NextFrame() and bge.logic.PrintMemInfo() based on their doc strings. There was also an :rtype: in the bge.logic.setExitKey() docs that should have been :type:. 2012-11-22 22:38:31 +00:00
Mitchell Stokes
de57d61f62 BGE Docs: Adding docs for KX_Scene.drawObstacleSimulation() based on its doc string. 2012-11-22 22:25:12 +00:00
Mitchell Stokes
ff94827965 BGE Docs: Documenting missing Sound Actuator attributes based on RNA UI strings. 2012-11-22 22:13:27 +00:00
Mitchell Stokes
f90298bc0a BGE Docs: Adding docs for the KX_GameObject.playAction() play_mode constants. 2012-11-22 21:52:30 +00:00
Mitchell Stokes
2765f1fffc BGE Docs: Reordering the "Various" constants so they are in alphabetical order. 2012-11-22 21:37:12 +00:00
Mitchell Stokes
899290dd47 BGE Docs: Moving the KX_ArmatureSensor.type constant docs from bge.types.rst to bge.logic.rst where the rest of the constants docs are. 2012-11-22 11:09:42 +00:00
Mitchell Stokes
989b5983c8 BGE Docs: Changing ROT_* Armature Channel constants in the docs to be ROT_MODE_* to match the actual constants from bge.logic. 2012-11-22 09:20:36 +00:00
Mitchell Stokes
9b571c2d54 BGE Docs: Fixing indentation. 2012-11-22 09:12:21 +00:00
Campbell Barton
762016c746 indentation edits 2012-11-22 08:30:54 +00:00
Mitchell Stokes
74ffa7bb8a BGE Docs: Adding some basic docs for the KX_STEERING_* constants. Right now just their names and values are in the docs, not what they actually do. 2012-11-22 08:22:46 +00:00
Mitchell Stokes
d9f6edff14 BGE Docs: Moving the BL_ArmatureChannel.rotation_mode constant docs from bge.types.rst to bge.logic.rst where the rest of the constants docs are. 2012-11-22 08:16:30 +00:00
Mitchell Stokes
8dd96bcefb BGE Docs: Moving the BL_ArmatureConstraint constant docs from bge.types.rst to bge.logic.rst with the rest of the constants docs are. 2012-11-22 08:07:13 +00:00
Mitchell Stokes
5da6c02188 BGE Docs: Adding RM_* mode constants from KX_NavMeshObject.draw() 2012-11-22 08:01:02 +00:00
Mitchell Stokes
a660ebc16e Moving the Armature Actuator constant docs from bge.types.rst to bge.logic.rst with the rest of the constants docs are. Not only is this more consistent, but it also makes Campbell's script happier. 2012-11-22 07:52:17 +00:00
Mitchell Stokes
6a5d5ed206 Some KX_CONSTRAINTACT_* constants were incorrectly documented as KX_CONSTRAINT_*. 2012-11-22 07:31:51 +00:00
Mitchell Stokes
8a62ec63c8 Adding docs for KX_NavMeshObject based on doc strings found in KX_NavMeshObject.cpp. 2012-11-22 07:24:00 +00:00
Mitchell Stokes
30a292b61f BGE: KX_PhysicsObjectWrapper was not being used anywhere in the code base, but it was being maintained (style, docs, name changes, etc), so I'm removing it. 2012-11-22 07:08:02 +00:00
Campbell Barton
b7f5c1c121 more bge reference api docstrings, leaving KX_FontObject and KX_NavMeshObject as TODO. 2012-11-22 06:04:12 +00:00
Campbell Barton
89b0b0516e bge camera axix actuator was undocumented and python had incorrect limits on this attribute. 2012-11-22 05:33:05 +00:00
Campbell Barton
9d0334bc74 add missing bgl and gpu api docstrings (found using docstring completeness checker) 2012-11-22 05:15:52 +00:00
Campbell Barton
3370e3ca43 doc corrections and add bge.types.KX_ArmatureSensor 2012-11-21 08:53:04 +00:00
Campbell Barton
7c3db355b1 remove ifdef'd bevel code, current bevel works better then the previous code.
reduce strlen check in texttool_suggest_add()
use 'del list[:]' rather then 'list[:] = []' in python scripts which clear lists.
2012-11-14 09:45:15 +00:00
Mitchell Stokes
093854e564 Docs update for r52164 2012-11-13 17:50:18 +00:00
Campbell Barton
955b5db5e9 build fix: recent commit broke building on 64bit linux 2012-11-12 03:37:28 +00:00
Campbell Barton
d22c5d4341 update to python api Gotcha docs to reflect changes to the api. also add a section about modifying linked library data. 2012-11-12 03:23:47 +00:00
Campbell Barton
250109f5ac add argument so recent bge function mesh.transform_uv() so you can optionally transform between UV1 / UV2 2012-11-10 10:26:39 +00:00
Campbell Barton
fecc3b9d68 add 2 new utility functions to the BGE mesh py api.
mesh.transform(matid, matrix)
  mesh.transform_uv(matid, matrix, uv_index=-1))


much more efficient then looping over verts in python to transform them.
2012-11-10 09:45:43 +00:00
Mitchell Stokes
f6a110d6ea BGE: Committing patch [#32697] "New BGE gravity API" by HG1.
This patch adds a gravity attribute to KX_Scene.
2012-11-10 03:11:18 +00:00
Mitchell Stokes
f840bd4a9f BGE: This patch adds a character wrapper (similar to the already implemented vehicle wrapper) to control character physics options. Currently supported options are:
* jump() -- causes the character to jump
  * onGround -- specifies whether or not the character is on the ground
  * gravity -- controls the "gravity" that the character physics uses for the character

More options could be added (such as jump speed, step height, make fall speed, max slope, etc).
2012-11-04 20:56:02 +00:00
Campbell Barton
7353f8d58e remove unneeded string in datatoc.c and correct some of the context types in our documentation. 2012-11-03 09:14:06 +00:00
Campbell Barton
d24278635a auto-generated py api now shows bpy.context.* items in the 'References' section of each type. 2012-11-03 07:28:51 +00:00
Campbell Barton
aeba4950c3 style cleanup 2012-10-27 10:42:28 +00:00
Campbell Barton
7c846bbe75 add section on how to run scripts in blender for the API intro, found there were no simple docs like this in the wiki.
also set the window type to normal on start when -p argument is given, since the view could be maximized/fullscreen.
2012-10-24 16:55:06 +00:00
Benoit Bolsee
4213eca5fc BGE VideoTexture: add depth buffer access to ImageViewport and ImageRender.
2 new attributes to ImageViewport and ImageRender object:
depth: set to True to retrieve the depth buffer as an array of float
       (not suitable for texture source).
zbuff: set to True to retrieve the depth buffer as a grey scale pixel array
       (suitable for texture source).

A new mode 'F' is added to VideoTexture.imageToArray() to allow returning the image
buffer as a one dimensional array of float. This mode should only be used to retrieve
the depth buffer of ImageViewport and ImageRender objects.

Example:

viewport = VideoTexture.ImageViewport()
viewport.depth = True
depth = VideoTexture.imageToArray(viewport,'F')
# show depth of bottom left pixel
# 1.0 = infinite, 0.0 = on near clip plane.
print(depth[0])
2012-10-20 22:28:44 +00:00
Jiri Hnidek
13d829e57d * Fix small bug in Python operator example; improved example of modal operator 2012-10-12 18:19:39 +00:00
Campbell Barton
b1c4809f50 rename BGE KX_GameObject attrs
* group -> group_parent
* members -> group_children

so its more clear what direction the relationship is.
2012-10-09 06:03:57 +00:00
Campbell Barton
8d2835b5e5 patch [#31875] Patch to get scene access through a game object
from Jay Parker (battery)
2012-10-09 05:58:09 +00:00
Campbell Barton
acf3a2790e api changelog for 2.64 and 2.63 (which I missed last release) 2012-10-09 01:07:08 +00:00
Campbell Barton
7614428c09 style cleanup: pep8 2012-10-08 10:03:01 +00:00
Campbell Barton
d5de816a15 patch [#32791] Spelling mistakes corrected.
from Sunny Gogoi (darkowlzz)
2012-10-07 03:26:30 +00:00
Mitchell Stokes
7beff06950 BGE: Committing patch [#31442] "API improvements: Group references python api, for better control over groups and instances" by Martin Sell (moerdn). This patch adds a member and a group property to KX_GameObject:
* KX_GameObject.member returns the list of group members if the object is a group object, otherwise None is returned
  * KX_GameObject.group returns the group object that the object belongs to or None if the object is not part of a group
2012-10-07 00:09:02 +00:00
Campbell Barton
d8144ef0f5 style cleanup: comment blocks 2012-10-04 13:26:15 +00:00
Alex Fraser
27c4c1f417 Added example of KX_GameObject subclassing to game engine docs. 2012-10-02 14:15:02 +00:00
Campbell Barton
721c37072e uncomment data identifiers from sphinx docs (own error made r41509) 2012-09-03 02:08:56 +00:00
Campbell Barton
3ec93e8c35 doc type correction 2012-08-22 15:04:11 +00:00
Campbell Barton
994d75b6ae spelling cleanup: spelling corrections from user zeffii on IRC. 2012-08-19 15:28:24 +00:00
Campbell Barton
4c5925503e fix for building docs 2012-07-30 10:44:57 +00:00
Campbell Barton
4ef8f3f537 code cleanup: assign mode to a variable in the 3d view header and remove some unused imports 2012-07-29 14:07:57 +00:00
Thomas Dinges
4fc078001d Documentation:
* Some UI docs for the Best Practise guide. Still WIP.
2012-07-29 01:38:31 +00:00
Mitchell Stokes
7fb85e1fb7 BGE LibLoad: Allow the user to disable loading text datablocks if they want to attempt to increase security by not loading potential Python scripts. 2012-07-22 22:58:12 +00:00
Campbell Barton
2557eaf0dd print names of nodes/sockets when cycles complains about only being able to connect a closure to another closure. 2012-07-19 13:04:43 +00:00
Mitchell Stokes
9d73cbf2c4 As a response to issue [#28483] "Enable/Disable Rigid Body actuator do nothing" reported by Jean-Francois Gallant (pyroevil), I'm adding preliminary support to enable and disable rigid body physics on dynamic objects. This is can be done via the Edit Object Actuator or through KX_GameObject.enableRigidBody() and KX_GameObject.disableRigidBody(). Thanks to Sergej Reich for his help with the patch. 2012-07-09 04:57:21 +00:00
Mitchell Stokes
d77e658c91 Adding a note to KX_Camera.projection_matrix and KX_Camera.modelview_matrix to warn that both values are the identity matrix prior to the first frame of rendering. Both values are calculated when rendering, which is after Python scripts have a chance to run on frame 1. 2012-07-07 06:42:44 +00:00
Bastien Montagne
4d2a6a8e21 Spellfixes: colour -> color 2012-07-04 12:19:50 +00:00
Bastien Montagne
468ef74ed7 More spell and typo fixes (mostly visualise->visualize, grey->gray, normalise->normalize). 2012-07-03 19:09:07 +00:00
Campbell Barton
edf244cbf7 document calling operators with undo enabled. 2012-06-28 08:17:28 +00:00
Mitchell Stokes
ecc15e53bd Removing channel manipulation from the Action Actuator Python API since this has been broken since the animation changes from Pepper. BL_ArmatureObject.channels should be used instead. For more information see bug #28843 for more info:
http://projects.blender.org/tracker/index.php?func=detail&aid=28843&group_id=9&atid=306
2012-06-28 06:22:47 +00:00
Dalai Felinto
7016538974 bge.logic.keyboard.getClipboard() and .setClipboard methods
the idea of using methods instead of attributes is to avoid users abusing of the system calls.

Thanks Campbell Barton for reviewing and small corrections
2012-06-27 21:57:33 +00:00
Campbell Barton
15cb064e1b style cleanup 2012-06-25 07:24:48 +00:00
Campbell Barton
98e6912480 style cleanup 2012-06-19 22:17:19 +00:00
Campbell Barton
b5b8306685 code cleanup: includes, also correct some py example typos 2012-06-16 20:20:07 +00:00
Mitchell Stokes
418451fa03 KX_RadarSensor.getConeHeight() not longer exists, removing it from the docs. 2012-06-14 08:02:45 +00:00
Mitchell Stokes
c07c572373 Fix for [#31813] "bge.types.KX_RadarSensor incorrect attributes" reported by Monster.
KX_RadarSensor.angle was returning the angle that was used to construct Bullet's physics shape, which is calculated from the logic brick gui. KX_RadarSensor.angle now recalculates the original value from the gui. However, m_coneradius isn't actually used by KX_RadarSensor that I can see, so it might be better to just assign the original angle to m_coneradius instead of the calculated value. I've also made KX_RadarSensor.angle read-only, since setting m_coneradius does not appear to have any affect, which means writing to KX_RadarSensor.angle never worked properly.
2012-06-14 08:01:20 +00:00
Campbell Barton
5248ec57d9 minor fixes
- new compositor could use uninitialized var
- profile conversion could use uninitialized var
- set better warnings for clang+cmake.
- remove picky warnings from sphinx doc gen shell script.
2012-06-11 12:13:41 +00:00
Campbell Barton
abfe63d8aa updates to context docs and add missing member to node context 'node_context_dir'. 2012-06-11 09:24:25 +00:00
Sergey Sharybin
8849a78970 Added example of basic objects ooperations in Python, liek adding object
datablock, adding object, linking it to scene and making selected and active.
2012-06-06 10:01:17 +00:00
Campbell Barton
e2133842c0 patch [#31594] [Documentation]: fix for example in bge.render.rst
by Philipp Oeser (lichtwerk)
2012-05-25 12:37:14 +00:00
Dalai Felinto
800e79c088 expanding bmesh example (py api) 2012-05-22 18:14:34 +00:00
Campbell Barton
f16f545c6e style cleanup
also fix example for mesh uv's
2012-05-22 16:24:09 +00:00
Dalai Felinto
39f2f99794 fix for bmesh api example
worth noticing is that the example in bpy.types.Mesh is wrong too (Mesh type does not have an uv element)
but I would prefer someone more familiar with bmesh to take a look at those
2012-05-22 15:19:19 +00:00
Brecht Van Lommel
2151c2f28e Python: documentation about overriding context members. 2012-05-02 13:28:13 +00:00
Campbell Barton
c6051ea87b replace python3 command with python3.2, python3 isnt available on ubuntu. 2012-05-01 20:45:16 +00:00
Dalai Felinto
ac4b757287 patch [#31216] OpenGL urls updated by Julien DUROURE (julien)
update for the apidocs for the BGL module
2012-05-01 20:45:03 +00:00
Campbell Barton
657e62c912 code cleanup: tag unused vars 2012-05-01 18:57:32 +00:00
Sergey Sharybin
e75e40c972 Release commit, 2.63!
Special thanks to Mango team for awesome splash screen!
And everybody else who made this release! :)
2012-04-26 17:49:48 +00:00
Campbell Barton
a1b9608ddd add mesh example with docs explaining polygon / loop relationship 2012-04-23 00:20:32 +00:00
Campbell Barton
1642e2888c rename Mesh.uv_loop_layers --> uv_layers
add filtering for document generator to support --partial bpy.types.SomeType
2012-04-22 23:51:50 +00:00
Campbell Barton
15eb3452ec style cleanup: pep8, also quiet compiler warning. 2012-04-20 18:50:18 +00:00
Campbell Barton
f774384606 updated man page 2012-04-05 09:41:55 +00:00
Campbell Barton
20e2330434 added Mesh.calc_tessface(), needed to update mesh tessface after bmesh edits.
also add py api BMDeformVert.clear()
2012-03-29 13:44:30 +00:00
Campbell Barton
7f1e9b8c41 bmesh py api:
added access to deform weights, access to weights acts like a python dict so you can do...

  print(group in dvert)
  dvert[group] = 0.5
  print(dvert[group])
  del dvert[group]
  print(dvert.items())
2012-03-27 10:30:10 +00:00
Campbell Barton
81d8f17843 style cleanup: pep8, indentation 2012-03-24 07:36:32 +00:00
Howard Trickey
ef1d3a3993 Fixed a couple of typos in the Python API docs 2012-03-23 14:29:59 +00:00
Campbell Barton
174a46361f doc cleanup: minor corrections and improvements to docstrings + recent doc changes. 2012-03-23 01:55:38 +00:00
Campbell Barton
8e2efc1dbf rna/python api change: rename Mesh.faces --> tessfaces, since existing scripts are using this to modify the mesh and its confusing that the edits are not kept.
This also makes it clearer that the faces are for tessellated results only.

Added a section on the Gotcha's about upgrading scripts, the pros and cons of MeshTessFace/MeshPoly/BMFace.
and spesifically how to upgrade importers and exporters for 2.63+.
2012-03-23 00:28:29 +00:00
Sergey Sharybin
c3e37cf15f Fix #30622: documentation example code for bge.types.KX_MeshProxy did not work,
using fix suggested by Ryan King.
2012-03-21 14:13:54 +00:00
Campbell Barton
9773f87891 bmesh docs:
- add examples for custom-data access
- group BMesh types logically in docs
- added missing docstrings

needed to add grouping functionality to sphinx for this.
2012-03-21 05:33:37 +00:00
Campbell Barton
1d5922fbaf minor changes to sphinx doc generator title formatting 2012-03-21 04:43:17 +00:00
Luca Bonavita
4e6669cee3 == Python API docs ==
Small fixes (thanks Terry Wallwork for reporting)
- adding logger filehandler in main () so that ARGS.output_dir exists, otherwise we get an IOError
- the zip was not including files in a container directory
2012-03-16 14:49:16 +00:00
Luca Bonavita
cddca9f606 == Python API docs ==
Committing a patch similar to revision 44887 with fixes to my own bugs
(sorry Campbell, and thanks for reviewing :)

Fixes
------
- examples/ svn directory not removed anymore (in-source builds possible again)
- fixed "include references somehow stopped working"
+ using shutils.makearchive() to zip the file

New command line options
------------------------

-l: Log the output of the api dump and sphinx|latex warnings and errors
    If given, save logs in:
    * OUTPUT_DIR/.bpy.log
    * OUTPUT_DIR/.sphinx-build.log
    * OUTPUT_DIR/.sphinx-build_pdf.log
    * OUTPUT_DIR/.latex_make.log

    (using only one log directive instead of -l for bpy and -L for sphinx)

-P: builds the pdf

-R: pack the files in a dir ready for online deployment
    (including the zip and the pdf eventually)

Example usage:
./blender.bin -b -P doc/python_api/sphinx_doc_gen.py -- -p bmesh* -o ./<OUTPUTDIR> -B -P -R -l
2012-03-16 10:49:39 +00:00
Campbell Barton
d772b51b56 revert r44887, changes were OK but caused too many problems, better do this as a smaller patch.
sphinx_doc_gen.sh broke building docs - 
- examples/ svn directory was being removed since it assumed an out-of-source build.
- include references somehow stopped working (didnt find why).

also fixed an unrelated error with building docs in object_utils.py
2012-03-15 03:50:52 +00:00
Luca Bonavita
5788de8408 == Python API docs ==
New command line options:

-l: logs bpy dumping problems in OUTPUT_DIR/.bpy.log

-L: logs sphinx|latex problems in:
    * OUTPUT_DIR/.sphinx-build.log      (sphinx building html problems)
    * OUTPUT_DIR/.sphinx-build_pdf.log  (sphinx building latex problems)
    * OUTPUT_DIR/.latex_make.log        (latex make problems)

-P: builds the pdf

-R: pack the files in a dir ready for online deployment
    (including the zip and the pdf eventually)


Example usage:
./cmake/bin/blender -b -P ./blender/doc/python_api/sphinx_doc_gen.py -- -p bmesh* -l -o ./python_api -B -P -R -L
2012-03-15 00:12:31 +00:00
Campbell Barton
f15c15e992 bmesh py api: finished todo - editable select_history
eg:
  bm.select_history = vert, face, edge

  bm.select_history.add(edge)
2012-03-14 04:46:12 +00:00
Campbell Barton
2fbb5ce833 bmesh py api: more comprehensive intro page, also fix some spelling errors. 2012-03-13 06:22:43 +00:00
Brecht Van Lommel
74b7bc1228 Fix #30524: documentation example code for bge.types.KX_MeshProxy did not work,
using fix suggested by Ryan King.
2012-03-12 13:04:06 +00:00
Campbell Barton
4dc35836ad code cleanup: remove unused variable assignents and added bmesh submodule links, doc correction reported by dfelinto. 2012-03-09 21:23:15 +00:00
Luca Bonavita
e4253fa2b8 == Python API docs ==
- Enhanced the -T option:

  - we can now choose among custom themes (now 'blender-org' and later 'naiad')
    and Sphinx internal themes (use -h option to see which ones)

  - choosing a custom theme will copy the theme dir to the output dir

- Added two new command line options:

  -N: Add the theme name to the html dir name
      For example, if we choose the theme 'haiku'
      with using -N will create html files in sphinx-out_haiku/
      Useful to test separate themes without overwriting the smae folder each time
      
  -B: Builds the html docs running sphinx-build
      This is useful to avoid runing sphinx with a separate shell command

- Fixed the URL in undocumented_message()
2012-03-08 18:36:23 +00:00
Campbell Barton
ee84084f99 style cleanup: pep8 + picky edits 2012-03-08 05:36:05 +00:00
Luca Bonavita
4aadffa80e == Python API docs ==
(sphinx_doc_gen.py)

- file reorganization to use more functions (easier to read)

- adapting to work after a recent commit that made some of the members of bpy.app.*
  output bytes instead of strings (see [#30154])

- a couple of new command line optionsto avoid editing the script:
    -T: let you choose the sphinx theme: the theme dir get copied in the destination dir
    -b: choose if we want the bpy module page or not

    Current command line arguments optional arguments:
      -h, --help            show this help message and exit
      -o OUTPUT_DIR, --output OUTPUT_DIR
                            Path of the API docs (default=<script dir>)
      -T SPHINX_THEME, --sphinxtheme SPHINX_THEME
                            Sphinx theme (default='default')
      -f, --fullrebuild     Rewrite all rst files in sphinx-in/ (default=False)
      -t, --testdump        Dumps a small part of the API (default=False)
      -b, --bpy             Write the rst file of the bpy module (default=False)

(rst/info_best_practice.rst)

- fixed a typo
2012-03-07 17:36:38 +00:00
Luca Bonavita
0fe519f14a == Python API docs ==
Adding two new command line options (-f = full rebuild, -t = testing) so that we don't have to edit the file each time
2012-03-05 14:12:38 +00:00
Dalai Felinto
1f928833f3 option for the Armature Actuator to change the influence of a bone constraint.
Also adds DampedTrackTo to the list of supported constraints in the BGE

Test file:
http://www.pasteall.org/blend/11715

Patch developed as part of a project to NF-UBC Nereus Program.
Development time 'sponsored' by the project.
www.nereusprogram.org
2012-03-03 02:47:01 +00:00
Luca Bonavita
8856a9cbcd == Python API docs ==
- Works in macOSX now (hackish)
  (TODO: not check for OSX explicitly but handle exception if it fails)

- We can now generate rst files outside out of the source (was annoying)
  - Moved some vars at module level
  - Managing the command line args with argparse.
    Example usage:
    ./cmake/bin/blender -b -P ./blender/doc/python_api/sphinx_doc_gen.py -- -o ./python_api
2012-03-02 14:39:18 +00:00
Campbell Barton
d2cab3e8b0 move bmesh wiki docs into bmesh header and update doxygen.
also have doxygen ignore *.py files and fix some warnings.
2012-02-27 20:27:19 +00:00
Campbell Barton
edb04d1461 bmesh docs now written in sphinx doc generator.
* http://www.blender.org/documentation/blender_python_api_2_62_0/bmesh.types.html
* http://www.blender.org/documentation/blender_python_api_2_62_0/bmesh.utils.html
2012-02-24 09:53:29 +00:00