Go to advanced search

by ajstarks
Fri Aug 03, 2012 2:08 am
Forum: OpenVG
Topic: Example program to draw random shapes using the C compiler
Replies: 72
Views: 60808

Re: Example program to draw random shapes using the C compil

The API now includes transformations: Translate, Scale, Rotate, and Shear. Running the shapes program with two arguments: ./shapes 20 a shows the character "a" rotated 20 times around the center of the screen. Here's the function: void rotext(VGfloat x, VGfloat y, int w, int h, int n, VGfloat deg, c...
by ajstarks
Thu Aug 02, 2012 11:13 am
Forum: OpenVG
Topic: Example program to draw random shapes using the C compiler
Replies: 72
Views: 60808

Re: Example program to draw random shapes using the C compil

The style was removed because sometimes it was not required, and in some cases, it's redundant. For example in a loop you want to set the style once to be applied to subsequent objects. In the cases where you need individual style, you can make a helper function to apply the *precise* style needed--...
by ajstarks
Thu Aug 02, 2012 4:34 am
Forum: OpenVG
Topic: Example program to draw random shapes using the C compiler
Replies: 72
Views: 60808

Re: Example program to draw random shapes using the C compil

The API has changed, (shape functions don't do their own style), and the code has been cleaned up and refactored (for example the GL state stuff is moved into its own C file, making it easier to understand the higher-level functions. See: http://github.com/ajstarks/openvg I got @bloodline's mouse co...
by ajstarks
Wed Aug 01, 2012 12:32 am
Forum: OpenVG
Topic: Example program to draw random shapes using the C compiler
Replies: 72
Views: 60808

Re: Example program to draw random shapes using the C compil

The documentation has been updated to include the API, using fonts, and building and running:

https://github.com/ajstarks/openvg/blob ... /README.md
by ajstarks
Tue Jul 31, 2012 11:57 am
Forum: OpenVG
Topic: Example program to draw random shapes using the C compiler
Replies: 72
Views: 60808

Re: Example program to draw random shapes using the C compil

@bloodline -- the mouse changes seem interesting, Feel free to send a pull request.
by ajstarks
Mon Jul 30, 2012 12:51 am
Forum: Graphics programming
Topic: SVG on the Raspberry Pi
Replies: 5
Views: 5045

Re: SVG on the Raspberry Pi

Code for experimenting with OpenVG on the Raspberry Pi is at https://github.com/ajstarks/openvg. At this point, the code supports Text (via TrueType Fonts), Arc, Circle, Ellipse, Rectangle, Rounded Rectangle, Line, Polyline, Polygon, Quadratic and Cubic Bezier curves. Included in the repo is a tool ...
by ajstarks
Mon Jul 30, 2012 12:01 am
Forum: OpenVG
Topic: Example program to draw random shapes using the C compiler
Replies: 72
Views: 60808

Re: Example program to draw random shapes using the C compil

The code found here: https://gist.github.com/3196007 has been updated to display text using TrueType fonts. The gist now contains a Makefile and the font2openvg program, which will turn font information into C source that you can embed in your program. The Makefile makes font code from files found i...
by ajstarks
Sun Jul 29, 2012 4:23 am
Forum: OpenVG
Topic: Example program to draw random shapes using the C compiler
Replies: 72
Views: 60808

Re: Example program to draw random shapes using the C compil

In this update: https://gist.github.com/3196007 I've added more shapes (lines, polygon, polyline, cubic and quadratic bezier curves, arc, circles) and the ability to control the number of objects on the command line. Here's the Makefile: shapes: shapes.c cc -Wall -I/opt/vc/include -I/opt/vc/include/...
by ajstarks
Fri Jul 27, 2012 4:37 am
Forum: OpenVG
Topic: Working tiger demo?
Replies: 15
Views: 5803

Re: Working tiger demo?

See: http://www.raspberrypi.org/phpBB3/viewt ... 69&t=12575 for an example of using OpenVG to draw random shapes.
by ajstarks
Fri Jul 27, 2012 4:35 am
Forum: OpenVG
Topic: Example program to draw random shapes using the C compiler
Replies: 72
Views: 60808

Example program to draw random shapes using the C compiler

See: https://gist.github.com/3186193 for an example program that draws random shapes on the Raspberry Pi:
by ajstarks
Mon Jul 23, 2012 10:53 pm
Forum: Graphics programming
Topic: SVG on the Raspberry Pi
Replies: 5
Views: 5045

Re: SVG on the Raspberry Pi

Check out https://github.com/tnovelli/vsprite - I never finished it but it seems like a nice direct approach. It works in WebGL so it'll work in OpenGL ES. I have it built, after: $ sudo apt-get install libglfw-dev The test example parses fine, but building stencil-test in the test directory, g++ s...
by ajstarks
Mon Jul 23, 2012 9:44 pm
Forum: Graphics programming
Topic: SVG on the Raspberry Pi
Replies: 5
Views: 5045

Re: SVG on the Raspberry Pi

tnovelli wrote:Check out https://github.com/tnovelli/vsprite - I never finished it but it seems like a nice direct approach. It works in WebGL so it'll work in OpenGL ES.
Looks interesting. Taking a look now. Any porting hints?
by ajstarks
Sun Jul 22, 2012 12:31 pm
Forum: Raspbian
Topic: Wrong compile options for dev-lang/go
Replies: 6
Views: 929

Re: Wrong compile options for dev-lang/go

what is the package name?
by ajstarks
Sun Jul 22, 2012 2:35 am
Forum: Raspbian
Topic: Wrong compile options for dev-lang/go
Replies: 6
Views: 929

Re: Wrong compile options for dev-lang/go

Also note that the patches I cited may or may not make it in the official Go distribution, and you may need to re-do your distro. Also be aware that that the patches were applied to the tip, not the release, so beware.
by ajstarks
Sat Jul 21, 2012 10:47 pm
Forum: Other programming languages
Topic: The Go Programming Language on the Raspberry Pi
Replies: 36
Views: 37574

Re: The Go Programming Language on the Raspberry Pi

As of now, the best option is to build from source.
by ajstarks
Sat Jul 21, 2012 3:27 pm
Forum: Other programming languages
Topic: The Go Programming Language on the Raspberry Pi
Replies: 36
Views: 37574

Re: The Go Programming Language on the Raspberry Pi

If you apply the patches here: https://gist.github.com/3116118 you will not need to set GOARM=5. I have tested this build on the latest hardware-float Raspbian based wheezy distribution: [email protected] ~ $ uname -a Linux raspberrypi 3.1.9+ #168 PREEMPT Sat Jul 14 18:56:31 BST 2012 armv6l GNU/Linux p...
by ajstarks
Sat Jul 14, 2012 12:03 am
Forum: OpenVG
Topic: Working tiger demo?
Replies: 15
Views: 5803

Re: Working tiger demo?

Here's an updated main function based on the @smtihnerd's version. It was size the tiger based on command arguments, and quit then your press [Enter]. int main (int argc, char **argv) { int w, h; bcm_host_init(); memset( state, 0, sizeof( *state ) ); // clear application state init_ogl(state); // St...
by ajstarks
Fri Jul 13, 2012 11:14 pm
Forum: OpenVG
Topic: Working tiger demo?
Replies: 15
Views: 5803

Re: Working tiger demo?

Brilliant! works for me.
by ajstarks
Fri Jul 13, 2012 1:27 am
Forum: OpenVG
Topic: Working tiger demo?
Replies: 15
Views: 5803

Re: Working tiger demo?

great, @smithnerd. I previously got everything to compile, but was missing the initialization part. Is your code available?
by ajstarks
Thu Jul 12, 2012 12:43 pm
Forum: OpenVG
Topic: Working tiger demo?
Replies: 15
Views: 5803

Re: Working tiger demo?

I checked on the wheezy distro, but could not find it.
by ajstarks
Thu Jul 12, 2012 12:00 pm
Forum: Other programming languages
Topic: The Go Programming Language on the Raspberry Pi
Replies: 36
Views: 37574

Re: The Go Programming Language on the Raspberry Pi

Yes, my build took 51 minutes.

Note that the ARM fixes are under review now: http://codereview.appspot.com/6344078/
by ajstarks
Wed Jul 11, 2012 4:29 am
Forum: Other programming languages
Topic: The Go Programming Language on the Raspberry Pi
Replies: 36
Views: 37574

Re: The Go Programming Language on the Raspberry Pi

I installed on wheezy, have not tried any other distro. Recipe for building Go on the Raspberry Pi: Adjust your environment to include: GOARM=5 GOOS=linux GOARCH=arm GOPATH=<root for packages> $ sudo apt-get install mercurial # get mercurial $ sudo apt-get install git # for go get ... $ hg clone -u ...

Go to advanced search