Commit Graph

154 Commits

Author SHA1 Message Date
Campbell Barton 2721b937fb Cleanup: use braces in headers 2023-09-24 14:52:38 +10:00
Campbell Barton 5b9740c913 Cleanup: use braces for sources in intern/
Omitted intern/itasc as some of these sources are from KDL:
https://www.orocos.org/kdl.html
2023-09-17 09:05:40 +10:00
Campbell Barton e955c94ed3 License Headers: Set copyright to "Blender Authors", add AUTHORS
Listing the "Blender Foundation" as copyright holder implied the Blender
Foundation holds copyright to files which may include work from many
developers.

While keeping copyright on headers makes sense for isolated libraries,
Blender's own code may be refactored or moved between files in a way
that makes the per file copyright holders less meaningful.

Copyright references to the "Blender Foundation" have been replaced with
"Blender Authors", with the exception of `./extern/` since these this
contains libraries which are more isolated, any changed to license
headers there can be handled on a case-by-case basis.

Some directories in `./intern/` have also been excluded:

- `./intern/cycles/` it's own `AUTHORS` file is planned.
- `./intern/opensubdiv/`.

An "AUTHORS" file has been added, using the chromium projects authors
file as a template.

Design task: #110784

Ref !110783.
2023-08-16 00:20:26 +10:00
Campbell Barton 530ee6e7fa Cleanup: make class doc-strings directly above classes
In some cases it wasn't clear if a comment before a class was meant
to be it's doc-string. Remove blank lines between the class & it's
doc-string.
2023-07-25 14:11:42 +10:00
Campbell Barton 65f99397ec License headers: use SPDX-FileCopyrightText in all sources 2023-06-15 13:35:34 +10:00
Campbell Barton 49594c37ae License headers: use SPDX-FileCopyrightText for CMake files 2023-06-14 23:36:23 +10:00
Sergey Sharybin 4f7dc1e4b6 Fix set but unused variable in IK solver 2023-04-19 10:02:09 +02:00
Sergey Sharybin a12a8a71bb Remove "All Rights Reserved" from Blender Foundation copyright code
The goal is to solve confusion of the "All rights reserved" for licensing
code under an open-source license.

The phrase "All rights reserved" comes from a historical convention that
required this phrase for the copyright protection to apply. This convention
is no longer relevant.

However, even though the phrase has no meaning in establishing the copyright
it has not lost meaning in terms of licensing.

This change makes it so code under the Blender Foundation copyright does
not use "all rights reserved". This is also how the GPL license itself
states how to apply it to the source code:

    <one line to give the program's name and a brief idea of what it does.>
    Copyright (C) <year>  <name of author>

    This program is free software ...

This change does not change copyright notice in cases when the copyright
is dual (BF and an author), or just an author of the code. It also does
mot change copyright which is inherited from NaN Holding BV as it needs
some further investigation about what is the proper way to handle it.
2023-03-30 10:51:59 +02:00
Sergey Sharybin d32d787f5f Clang-Format: Allow empty functions to be single-line
For example

```
OIIOOutputDriver::~OIIOOutputDriver()
{
}
```

becomes

```
OIIOOutputDriver::~OIIOOutputDriver() {}
```

Saves quite some vertical space, which is especially handy for
constructors.

Pull Request: https://projects.blender.org/blender/blender/pulls/105594
2023-03-29 16:50:54 +02:00
Campbell Barton 427a2c920a Cleanup: spelling in comments, capitalize tags
Also add missing task-ID reference & remove colon after \note as it
doesn't render properly in doxygen.
2022-05-13 09:29:25 +10:00
Hallam Roberts 3da84d8b08 Cleanup: use M_PI_2 and M_PI_4 where possible
The constant M_PI_4 is added to GLSL to ensure it works there too.

Differential Revision: https://developer.blender.org/D14288
2022-03-11 18:27:58 +01:00
Campbell Barton bff0cf1030 Cleanup: remove white-space before headers 2022-02-11 14:23:54 +11:00
Campbell Barton c434782e3a File headers: SPDX License migration
Use a shorter/simpler license convention, stops the header taking so
much space.

Follow the SPDX license specification: https://spdx.org/licenses

- C/C++/objc/objc++
- Python
- Shell Scripts
- CMake, GNUmakefile

While most of the source tree has been included

- `./extern/` was left out.
- `./intern/cycles` & `./intern/atomic` are also excluded because they
  use different header conventions.

doc/license/SPDX-license-identifiers.txt has been added to list SPDX all
used identifiers.

See P2788 for the script that automated these edits.

Reviewed By: brecht, mont29, sergey

Ref D14069
2022-02-11 09:14:36 +11:00
Campbell Barton 81da638c44 Cleanup: move file descriptions into doxygen file section
Continuation of 19100aa57d.
2022-02-09 18:33:29 +11:00
Brecht Van Lommel 86141a75eb Cleanup: fix typos in source code in intern/
Contributed by luzpaz.

Differential Revision: https://developer.blender.org/D13532
2022-01-05 15:35:30 +01:00
Campbell Barton f6fd3a84c2 Cleanup: reorganize doxygen modules
- Nest compositor pages under the compositor module
- Nest GUI, DNA/RNA & externformats modules under Blender.
- Remove modules from intern which no longer exist.
- Add intern modules (atomic, eigen, glew-mx, libc_compat, locale,
  numaapi, rigidbody, sky, utfconv).
- Use 'intern_' prefix for intern modules since some of the modules
  use generic terms such as locale & atomic.
2021-12-14 20:56:11 +11:00
Leon Zandman c317f111c1 Cleanup: Spelling Mistakes
This patch fixes many minor spelling mistakes, all in comments or
console output. Mostly contractions like can't, won't, don't, its/it's,
etc.

Differential Revision: https://developer.blender.org/D11663

Reviewed by Harley Acheson
2021-06-22 10:54:50 -07:00
Campbell Barton 17e1e2bfd8 Cleanup: correct spelling in comments 2021-02-05 16:23:34 +11:00
Harley Acheson 3a7fd309fc Spelling: It's Versus Its
Corrects incorrect usage of contraction for 'it is', when possessive 'its' was required.

Differential Revision: https://developer.blender.org/D9250

Reviewed by Campbell Barton
2020-10-19 08:12:33 -07:00
Dalai Felinto 2d1cce8331 Cleanup: `make format` after SortedIncludes change 2020-03-19 09:33:58 +01:00
Lazydodo 6086a6d939 Cleanup: Fix build error with MSVC
Previously eigens internal include order somehow implicitly provided
M_PI and friends. The recent eigen version bump broke this implicit
behaviour, better to be explicit that we need the math defines for MSVC.
2019-08-21 10:38:33 -06:00
Campbell Barton 2425401a59 Cleanup: spelling 2019-08-04 12:51:44 +10:00
Campbell Barton 177a0ca131 Cleanup: comments (long lines) in various intern/ libs 2019-05-01 21:00:56 +10:00
Campbell Barton 108045faa0 ClangFormat: format '#if 0' code in intern/ 2019-04-17 08:17:13 +02:00
Campbell Barton e12c08e8d1 ClangFormat: apply to source, most of intern
Apply clang format as proposed in T53211.

For details on usage and instructions for migrating branches
without conflicts, see:

https://wiki.blender.org/wiki/Tools/ClangFormat
2019-04-17 06:21:24 +02:00
Campbell Barton 47adab4f99 CMake: prepare for BLENDER_SORTED_LIBS removal
No functional change, this adds LIB definition and args to cmake files.
Without this it's difficult to migrate away from 'BLENDER_SORTED_LIBS'
since there are many platforms/configurations that could break when
changing linking order.

Manually add and enable WITHOUT_SORTED_LIBS to try building
without sorted libs (currently fails since all variables are empty).
This check will eventually be removed.

See T46725.
2019-04-14 15:37:24 +02:00
Campbell Barton e7fd6c8f30 Cleanup: comment blocks 2019-03-19 15:17:46 +11:00
Campbell Barton de13d0a80c doxygen: add newline after \file
While \file doesn't need an argument, it can't have another doxy
command after it.
2019-02-18 08:22:12 +11:00
Campbell Barton eef4077f18 Cleanup: remove redundant doxygen \file argument
Move \ingroup onto same line to be more compact and
make it clear the file is in the group.
2019-02-06 15:45:22 +11:00
Campbell Barton ab5e69e660 Cleanup: remove contributors for CMake files
Following removal from C source code.

See: 8c68ed6df1
2019-02-05 09:10:32 +11:00
Campbell Barton 4ef09cf937 Cleanup: remove author/date info from doxy headers 2019-02-02 11:58:24 +11:00
Campbell Barton 3b57a0d854 Cleanup: remove original author
Missed when removing contributors.
2019-02-02 02:32:20 +11:00
Campbell Barton 65ec7ec524 Cleanup: remove redundant, invalid info from headers
BF-admins agree to remove header information that isn't useful,
to reduce noise.

- BEGIN/END license blocks

  Developers should add non license comments as separate comment blocks.
  No need for separator text.

- Contributors

  This is often invalid, outdated or misleading
  especially when splitting files.

  It's more useful to git-blame to find out who has developed the code.

See P901 for script to perform these edits.
2019-02-02 01:36:28 +11:00
lazydodo 0de157a320 FIX T49899: Add EIGEN_MAKE_ALIGNED_OPERATOR_NEW to classes that use eigen's data types , to force aligned on 16 byte boundaries. 2016-11-15 13:21:01 -07:00
Campbell Barton a2db16ba58 CMake: add missing headers 2016-04-12 11:22:30 +10:00
Sergey Sharybin 5d99cde822 Remove SCons building system
While SCons building system was serving us really good for ages it's no longer
having much attention by the developers and started to become quite a difficult
task to maintain.

What's even worse -- there started to be quite serious divergence between SCons
and CMake which was only accumulating over the releases now. The fact that none
of the active developers are really using SCons and that our main studio is also
using CMake spotting bugs in the SCons builds became quite a difficult task and
we aren't always spotting them in time.

Meanwhile CMake became really mature building system which is available on every
platform we support and arguably it's also easier and more robust to use.

This commit includes:

- Removal of actual SCons building system
- Removal of SCons git submodule
- Removal of documentation which is stored in the sources and covers SCons
- Tweaks to the buildbot master to stop using SCons submodule
  (this change requires deploying to the server)
- Tweaks to the install dependencies script to skip installing or mentioning
  SCons building system
- Tweaks to various helper scripts to avoid mention of SCons folders/files
  as well

Reviewers: mont29, dingto, dfelinto, lukastoenne, lukasstockner97, brecht, Severin, merwin, aligorith, psy-fi, campbellbarton, juicyfruit

Reviewed By: campbellbarton, juicyfruit

Differential Revision: https://developer.blender.org/D1680
2016-01-04 14:20:48 +05:00
Brecht Van Lommel c7122b5391 IK Solver: remove unused and outdated test code. 2015-12-11 01:42:41 +01:00
Brecht Van Lommel 6e4802d712 IK Solver: replace TNT math library with Eigen.
Performance is about the same or slightly better for typical IK chains.
In extreme cases with many bones and multiple targets, of which some are
unreachable, I've seen 2x speedups.
2015-12-11 00:59:00 +01:00
Brecht Van Lommel aaa627d5f5 IK solver: replace Moto math library with Eigen. 2015-12-11 00:59:00 +01:00
Brecht Van Lommel 726727191a Fix T43715: IK pole target + stretch not working for a single bone chain. 2015-09-21 01:59:50 +02:00
Campbell Barton 5d30c23c35 doxygen: corrections/updates
Also add depsgraph & physics
2015-05-20 14:12:22 +10:00
Campbell Barton 1dc1d92dab Code cleanup: white space and cmake was broken on all platforms 2014-02-03 13:56:34 +11:00
Campbell Barton a288644b1e Code Cleanup: WIN32 defines, check for _MSC_VER instead of !FREE_WINDOWS 2014-01-03 20:46:12 +11:00
Martijn Berger 1c8a12ee61 Fix T37987: MSVC 2013 has C99 headers and warns for out define hypot _hypot for good reason it seems 2014-01-02 22:19:10 +01:00
Campbell Barton 02ba328ca8 clang/cmake - quiet warnings for external libs and reference moto as a system include. 2013-07-15 08:26:16 +00:00
Brecht Van Lommel 4f3ca854e1 Fix various warnings with clang build, and adjust cmake clang warnings flags
to include a few more that gcc is using too.
2013-02-26 21:58:06 +00:00
Bastien Montagne ab2c273b12 Added GPL header to sconscripts!
Also changed shebang to '#!/usr/bin/env python', this is more portable across unixes...
2012-12-17 08:01:43 +00:00
Brecht Van Lommel 68efcca5ea Fix issue reported in #32174: IK solver stretch was less stable after a code refactor
commit, epsilon was supposed to be 0.01 instead of 0.001.
2012-12-11 14:39:28 +00:00
Brecht Van Lommel d8c257faa7 IK Solver:
* Rename Legacy to Standard, it's not being deprecated as far as I know.
* Make option to toggle off Location solving work with Standard.
* Make it converge a bit better in some cases by enforcing a minimum number of
  iterations before giving up.
* Move IK solver choice out of bone panel, it's an armature level setting and
  should be set there.
2012-11-24 00:18:34 +00:00
Campbell Barton bc69b3a8df style cleanup 2012-09-20 01:32:13 +00:00