Deuces
This is a list of succinct tasks that are expected to take most people familiar with the prerequisites less than two hours to complete. It's a great starting point for anyone interested in contributing to BRL-CAD.
The tasks are all roughly the same complexity with no prior BRL-CAD experience expected. A description is provided along with a list of references and files you'll probably need to edit. Can we make it any easier?
Getting Started
Contact us (via IRC or brlcad-devel mailing list) if you have questions, comments, or ideas of your own you'd like to suggest.
We've made an awesome virtual disk image that has everything you need preconfigured and ready to go:
- Download our BRL-CAD Virtual Machine (VM) disk image.
- Install VirtualBox.
- Import and start the VM, log in (the password is "Brlcad!" without the quotes).
- Run "svn up brlcad.svn" and get started!
Pick a Task
We break down all tasks into one of five categories. Don't be worried if the tasks all sound confusing to you. Just pick one and start reading the references we've provided. Join IRC or our mailing list and ask questions.
- Code (programming)
- Documentation and Training (writing)
- Outreach and Research (graphics)
- Quality Assurance (testing)
- User Interface (designing)
Contents
- 1 Getting Started
- 2 Pick a Task
- 2.1 Code
- 2.1.1 Fix bounding box function for our polygonal mesh (BoT) primitive
- 2.1.2 Close MGED when both windows are closed
- 2.1.3 Add MGED key-binding to reopen the command window
- 2.1.4 Implement a primitive surface area function
- 2.1.4.1 ... surface area function for elliptical hyperboloids (EHY)
- 2.1.4.2 ... surface area function for hyperboloids of one sheet (HYP)
- 2.1.4.3 ... surface area function for N-faced polysolid (ARBN)
- 2.1.4.4 ... surface area function for extruded bitmaps (EBM)
- 2.1.4.5 ... surface area function for gridded volumes (VOL)
- 2.1.4.6 ... surface area function for super ellipsoids (SUPERELL)
- 2.1.4.7 ... surface area function for polygonal meshes (NMG)
- 2.1.4.8 ... surface area function for NURBS objects (BREP)
- 2.1.5 Implement a primitive volume function
- 2.1.5.1 ... volume function for elliptical hyperboloids (EHY)
- 2.1.5.2 ... volume function for superellipsoids (SUPERELL)
- 2.1.5.3 ... volume function for extruded bitmaps (EBM)
- 2.1.5.4 ... volume function for triangle meshes (BOT)
- 2.1.5.5 ... volume function for solid polygonal meshes (NMG)
- 2.1.5.6 ... volume function for extruded sketches (EXTRUDE)
- 2.1.6 Implement a primitive centroid function
- 2.1.6.1 ... centroid function for right hyperbolic cylinders (RHC)
- 2.1.6.2 ... centroid function for gridded volumes (VOL)
- 2.1.6.3 ... centroid function for N-faced polysolids (ARBN)
- 2.1.6.4 ... centroid function for extruded sketches (EXTRUDE)
- 2.1.6.5 ... centroid function for superellipsoids (SUPERELL)
- 2.1.6.6 ... centroid function for solid polygonal meshes (NMG)
- 2.1.7 Implement a primitive UV-mapping callback
- 2.2 Documentation and Training
- 2.2.1 Add missing documentation (for any ONE command)
- 2.2.2 Document MGED's 'saveview' command options
- 2.2.3 Write a "BRL-CAD Commands Quick Reference" document
- 2.2.4 Doxygen cleanup
- 2.2.5 Write a manual page for MGED's "brep" command
- 2.2.6 Write up Wiki page tutorial on our Volumetric Primitive
- 2.2.7 Write article on BRL-CAD's code hardening efforts
- 2.2.8 Write a wiki tutorial on how to create a polygonal mesh (NMG) manually
- 2.3 Outreach and Research
- 2.4 Quality Assurance
- 2.5 User Interface
- 2.1 Code
- 3 When You're Done
Code
Tasks related to writing or refactoring code
See the When You're Done section above for details on submitting your changes.
Fix bounding box function for our polygonal mesh (BoT) primitiveBRL-CAD provides functions for its geometric primitives that define a bounding box - a box that completely encloses the volume described by the primitive. Ideally, these boxes are as small as possible while still enclosing the primitive. Currently the routine for BoTs is incorrect. You can use stl-g, obj-g, or any of our other *-g converters to import BoT geometry for testing. This task involves studying the current code for the function rt_bot_bbox() and determining what is causing the current inaccuracies (the mged 'bb' command is a good way to visualize primitive bounding boxes). Make changes to produce a more optimal bounding box. Reimplement it from scratch if you like. The raytracing prep code in rt_bot_prep does prepare a better bounding box, so that is one place to check. Code:
|
Close MGED when both windows are closedBRL-CAD has an interactive geometry editor called MGED. It's often the starting point for beginners and allows creation and manipulation of models using commands. When mged is run, it creates 2 windows: a text-console command window and an interactive graphics window. When the user closes one of those windows, there is a bug. Closing the graphics window closes the command window. This task involves fixing this behavior so that ONLY closing both windows terminates the process properly and that closing either window does not take the other along with it. Code:
|
Add MGED key-binding to reopen the command windowBRL-CAD has an interactive geometry editor called MGED. It's often the starting point for beginners and allows creation and manipulation of models using commands. When MGED is invoked, it creates 2 windows: a text-console command window and an interactive graphics window. If the user closes the text-console command window, they are left with the interactive graphics window. There is presently no way (correct us if we're wrong) to get the text-console back without restarting mged. A good way to test this is to run in classic mode and run the 'gui' command: sushi:~ morrison$ mged -c test.g BRL-CAD Release 7.22.0 Geometry Editor (MGED) Fri, 24 Aug 2012 00:02:42 -0400, Compilation 6 morrison@sushi.local:/usr/brlcad/rel-7.22.0 attach (nu|X|ogl)[nu]? mged> gui This task involves adding some mechanism, perhaps a simple key binding, to the graphics window so that you can get the command window back on-demand. Code:
|
Implement a primitive surface area functionBRL-CAD provides more than two dozen types of geometry "primitives" such as ellipsoids, boxes, and cones. Every primitive is described by a collection of callback functions, for example rt_ell_bbox() returns the bounding box dimensions for an ellipsoid. Wikipedia, Wolfram Mathworld, and various other math sites (and research papers) around the web include the equations for most of our basic primitives while others are a little more tricky to compute. This task involves writing a new callback function that takes an rt_db_internal object and calculates the surface area (units are mm^2). There are numerous examples in our code where we compute surface area for other primitives. The primitives that do not already have a centroid callback are itemized in following. References:
|
Implement a primitive volume functionBRL-CAD provides more than two dozen types of geometry "primitives" such as ellipsoids, boxes, and cones. Every primitive is described by a collection of callback functions, for example rt_ell_bbox() returns the bounding box dimensions for an ellipsoid. Wikipedia, Wolfram Mathworld, and various other math sites (and research papers) around the web include the equations for most of our basic primitives while others are a little more difficult to compute. This task involves writing a new callback function that takes an rt_db_internal object and calculates the volume (units are mm^3). There are numerous examples in our code where we compute volume for other primitives. The primitives that do not already have a volume callback are itemized in following. References:
|
Implement a primitive centroid functionBRL-CAD provides more than two dozen types of geometry "primitives" such as ellipsoids, boxes, and cones. Every primitive is described by a collection of callback functions, for example rt_ell_bbox() returns the bounding box dimensions for an ellipsoid. Wikipedia, Wolfram Mathworld, and various other math sites (and research papers) around the web include the equations for most of our basic primitives while others are a little more tricky to compute. This task involves writing a new callback function that takes an rt_db_internal object and calculates its centroid (as a point_t 3D point). There are numerous examples in our code where we compute centroids for other primtiives. The primitives that do not already have a centroid callback are itemized in following. References:
Code:
|
Implement a primitive UV-mapping callbackBRL-CAD provides more than two dozen types of geometry "primitives" such as ellipsoids, boxes, and cones. Every primitive is described by a collection of callback functions, for example rt_ell_bbox() returns the bounding box dimensions for an ellipsoid. One of those functions describes a UV mapping of the object's surface, which is used for things like texture and bump mapping. An example of this is rt_ell_uv() in the src/librt/primitives/ell/ell.c source file for an ellipsoid. Several of our more complex primitive types (such as BoT, NMG, and BREP/NURBS) do not presently implement a UV-mapping function leading to unexpected runtime behavior. This task involves implementing a UV-mapping callback for any of the primitives that do not already have a functional UV-callback defined. Note that this is an advanced task that might take you more than a couple hours if you don't have solid coding skills, but it's ultimately just a few lines of code. See other primitives that already implement a UV-mapping callback for reference. References:
|
Documentation and Training
Tasks related to creating/editing documents and helping others learn more about BRL-CAD
Add missing documentation (for any ONE command)BRL-CAD is an extensive system with more than 400 commands and more than a million pages of documentation, but there are approximately 120 commands that are entirely undocumented: a-d archer asc2g asc2pix bot-bldxf bottest brep_cube brep_simple brickwall btclsh burst bw-a bw-d bwish c-d chan_add clutter contours d-a damdf dauto dauto2 d-bw dconv ddisp d-f dfft d-i dmod double-asc dpeak dsel dsp_add dstat d-u dwin euclid_format euclid_unformat fbgammamod f-d fence fhor f-i g-adrt g-euclid1 g-jack globe g-off i-a i-d i-f ihist imod istat jack-g kurt lowp molecule nmgmodel nmg-sgp off-g pipe pipetest pix2g pix3filter pixcount pixelswap pixembed pixfields pixfieldsep pixflip-fb pixpaste pix-spm pix-yuv plstat pyramid rawbot remapid rlesortmap rletovcr room rtcell rtexample rtfrac rtrad rtsil rtsrv script-tab sketch solshoot sphflake spltest spm-fb ssampview syn tea tea_nmg testfree texturescale torii ttcp tube txyz-pl u-a u-bw u-d u-f umod ustat vcrtorle vegitation wall wdb_example xbmtorle xyz-pl yuv-pix This task involves writing basic documentation for JUST ONE of those commands in the Docbook XML format. The command documentation should provide a one-sentence description, a detailed paragraph description (200+ words), explanation of all available command-line options, and one or more examples on how to use the command. Code:
|
Document MGED's 'saveview' command optionsBRL-CAD's primary geometry editor (MGED) provides hundreds of commands. Two of those commands are the savewview and loadview commands that write current view settings out to a text file and read them back in. The saveview command provides -e -i -l and -o options, but they are not documented. This task involves writing documentation for those missing options. Consult the source code to see what they do and add the corresponding sections into our Docbook XML doc just like we do in our other documentation files. Test compilation to make sure your XML syntax is correct. References:
Code:
|
Write a "BRL-CAD Commands Quick Reference" documentThere is already a command quick reference for BRL-CAD's MGED geometry editing tool, but there is not a similar document for BRL-CAD's 400+ command-line commands. This task involves writing a quick reference document similar to the MGED quick reference but for BRL-CAD commands. The sheet should minimally include the following commands: mged, rt*, *-g, g-*, fb*, *fb, nirt, remrt, rtsrv, asc2g, g2asc, dbupgrade, pix*, *pix, *-*, brlman, benchmark References: |
Doxygen cleanupBRL-CAD uses Doxygen for most API documentation but the comment blocks are not optimally set up for Doxygen output. This task involves cleaning up the Doxygen comments in the library so that useful reports and API documentation automatically generated (correctly, completely, and cleanly). Verify/fix any Doxygen syntax. Verify/fix groups so that functions are organized neatly and all contained within a group. Provide patches that give clean (PDF) output from Doxygen. References:
|
Write a manual page for MGED's "brep" commandBRL-CAD's MGED geometry editor provides hundreds of commands. One of those commands for manipulating and visualizing geometry is the "brep" command. This task involves writing a manual page for that command in the Docbook XML format. There are lots of examples to follow. References:
Code:
Running "make" in a build directory will compile your documentation into html and man page format so you can validate the syntax and formatting. See Compiling for help. |
Write up Wiki page tutorial on our Volumetric PrimitiveBRL-CAD provides a couple dozen distinct primitives. Each primitive is defined by a set of parameters. Several of the more complex primitives have a wiki page describing them in more detail with an example on how to create them. This task involves writing up a page on the VOL primitive. Figure out how to use it (see the "in" command), create an example input data set, and write up a wiki page on exactly what steps are needed similar to our other wiki pages: References:
Show how to create a VOL with at least two layers/slices. Include images like the other examples. Put the write-up at http://brlcad.org/wiki/VOL |
Write article on BRL-CAD's code hardening effortsWe've been working for several years on "code hardening", improving the quality of BRL-CAD's source code through a variety of best practices and code cleanup efforts. This task has you write an article that succinctly summarizes all of our efforts. You'll need to become familiar with our HACKING file as well as read up on our various hardening efforts. You're welcome to ask our devs questions over IRC for more information too. Include at least one picture. Article should be 300-900 words long and be fully proof-read before submitting (check for grammar and spelling mistakes, please). Resources:
Add the article to http://brlcad.org/wiki/Community_Publication_Portal |
Write a wiki tutorial on how to create a polygonal mesh (NMG) manuallyBRL-CAD provides a couple dozen distinct primitives. Each primitive is defined by a set of parameters. Several of the more complex primitives have a wiki page describing them in more detail with an example on how to create them. This task involves writing up a page on the NMG polygonal mesh primitive. Figure out how to use it (not a simple task, will require some trial and error), create an example input, and write up a wiki page on exactly what steps are needed similar to our other wiki pages: References:
Note the "facetize" command in mged will convert an existing object into NMG format. The get/put commands should help from there like the sketch tutorial. Show how to create an NMG cube or wedge or similar simple shape. Include images like the other examples. Put the write-up at http://brlcad.org/wiki/NMG |
Outreach and Research
Tasks related to community management, outreach/marketing, studying problems, and recommending solutions
Investigate permuted vertex lists from g-iges + iges-gBRL-CAD has a geometry exporter and importer for the International Graphics Exchange Standard (IGES) file format. If you run our g-iges exporter on some geometry, then run iges-g on that same geometry to import it back to BRL-CAD format, the geometry will have permuted vertex lists. Particularly for geometry already in polygonal format, such as our NMG or BoT geometry, this conversion should result in identical geometry but presently does not. This task involves investigating why this occurs, reporting (in detail) why it occurs, and if obvious, making a recommendation on how to fix the problem. Code:
|
Quality Assurance
Tasks related to testing and ensuring code is of high quality
Fix single-precision floating point crashBy default, all of BRL-CAD compiles using double-precision floating point arithmetic. We provide a simple typedef, however, that converts almost the entire system over to single-precision floating point. This compilation mode was recently cleaned up and tested, but a bug was found. The problem is reproduced very simply by compiling in single precision mode and running our "rt" ray tracer tool. To compile in single precision, edit the include/bn.h header file and change the fastf_t typedef from double to float. To reproduce the bug, compile BRL-CAD and write this out to a text file named star.view: viewsize 2.500000000e+05; eye_pt 2.102677960e+05 8.455500000e+04 2.934714650e+04; viewrot -6.733560560e-01 6.130643360e-01 4.132114880e-01 0.000000000e+00 5.539599410e-01 4.823888300e-02 8.311441420e-01 0.000000000e+00 4.896120540e-01 7.885590550e-01 -3.720948210e-01 0.000000000e+00 0.000000000e+00 0.000000000e+00 0.000000000e+00 1.000000000e+00 ; start 0; end; Then run rt feeding it that view script as input. This is an example how to run within the gdb debugger: gdb path/to/bin/rt ... (gdb) run -F/dev/X -M .cmake/share/db/star.g all < star.view At this point, rt should crash due to an infinite recursion. A backtrace in the debugger will show lots and lots of calls to rt_shootray() and light_hit(). This task involves investigating and preventing the crash. Provide a patch that fixes the bug. References:
Code:
|
Fix closedbBRL-CAD geometry editor application (mged) has several hundred commands including two very simple commands for opening and closing a geometry database file. While the user rarely ever needs to close the file, as all changes are always immediately saved, it can be of use to scripting applications. However, at some point in the recent past, the closedb command was horked. It's undoubtedly something very simple but we haven't bothered to look due to other priorities. You can fix it. If you run these simple steps within graphical mged, you should see how commands stop working after calling closedb: mged> opendb test.g y mged> make sph sph mged> l sph mged> closedb mged> make sph sph mged> opendb test.g mged> l sph mged> exit Provide a patch that fixes the bug or tell us which SVN revision introduced the bug. Make sure you can reproduce the bug before claiming this task, which presumes you know how to download/install BRL-CAD from a source distribution. Code:
|
Create an utility library (LIBBU) API unit testThere are more than 300 library functions in our core LIBBU library. As a core library used by nearly every one of BRL-CAD's tools, testing those functions for correct behavior is important. This task involves implementing a new unit test for any of LIBBU's source files that do not already have a unit test defined. The test should run all of the public functions and be hooked into our build system. We have lots of existing unit tests to follow as an example. References:
Code:
|
Create numerics library (LIBBN) API unit testThere are more than 300 library functions in our core LIBBN library. As a core library used by nearly every one of BRL-CAD's tools, testing those functions for correct behavior is important. This task involves implementing a new unit test for any of LIBBN's source files that do not already have a unit test defined. The test should run all of the public functions and be hooked into our build system. We have lots of existing unit tests to follow as an example. References:
Code:
|
Find, reliably reproduce, and report any bug in ArcherArcher is our new modeling interface and a soon to merge with our long-standing MGED geometry editor. It undoubtedly has bugs. It's your job to find one, but do so in a manner that is so obvious that one of the other devs will be able to instantly reproduce the bug given your specific instructions. Find a way to make archer crash, become unresponsive, or otherwise behave incorrectly. You will have to explore the tool with minimal documentation. This task involves filing a bug report with verifiable and reproducible steps that clearly demonstrate the bug. It can't be a bug already reported or otherwise documented nor can it be merely behavior you don't like. References:
|
Reproduce any 10 unconfirmed open bug reportsBRL-CAD presently has approximately 75 open bug reports of which 50 are unassigned. Read the comments and status to see if the bug has been confirmed/reproduced. This task involves going through those reports and REPRODUCE at least 10 of the ones that have not been confirmed. When you can reproduce the issue being reported, you'll comment on the thread to state as much and attach any data you used to reproduce the crash. References: |
User Interface
Tasks related to user experience research or user interface design and interaction
When You're Done
For non-code, just send us your file(s). For code changes, you will be expected to provide a patch file. Make sure you read your patch file before submitting it. Make sure your patch file will apply cleanly to an unmodified checkout of BRL-CAD:
svn co https://brlcad.svn.sourceforge.net/svnroot/brlcad/brlcad/trunk brlcad.edit cd brlcad.edit # make changes svn diff > ~/my.patch # read ~/my.patch file with text editor cd .. svn co https://brlcad.svn.sourceforge.net/svnroot/brlcad/brlcad/trunk brlcad.fresh cd brlcad.fresh patch -p0 < ~/my.patch # submit your patch file to our patches tracker