GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
RTEXAMPLE(1) BRL-CAD User Commands RTEXAMPLE(1)

rtexample - shoots a single ray at objects in a geometry database

rtexample model.g objects...

        This is an example of a program that uses librt to shoot a single ray at some
        geometry in a geometry (.g) database.
        librt is a big library with lots of code, but basically all that the programmer
        needs to do is include `raytrace.h` and specify the following:
          a_rt_i    a raytrace instance, from 'rt_dirbuild()'
          a_ray     ray origin and direction
          a_hit     function to be called if ray hits something
          a_miss    function to be called if ray misses everything
        rtexample defines simple functions for a_hit and a_miss which simply
        output information about hit region (if hit) and log misses. Applications will
        typically define more complex tasks to fo if the ray hits, such as describing a
        reflected ray.
        

rtexample car.g wheel door

Here, a single ray will be shot at the geometry database car.g and hit reports generated if the ray hits the specified objects.

mged(1), rt(1), librt(3)

BRL-CAD Team

This software is Copyright (c) 2004-2019 United States Government as represented by the U.S. Army Research Laboratory.

Reports of bugs or problems should be submitted via electronic mail to devs@brlcad.org
06/07/2022 BRL-CAD

Search for    or go to Top of page |  Section 1 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.