Sha256: f6bf9fd2fe37fd674cc6c8b578546d07e151ad1ca4686fe1a3d9e22a79fa6116

Contents?: true

Size: 1.75 KB

Versions: 4

Compression:

Stored size: 1.75 KB

Contents

//
//  B2DDraw.h
//  Box2D
//
//  Created by Juan José Karam on 6/29/13.
//  Copyright (c) 2013 Joybox. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "Draw.h"

@class B2DColor;
@class B2DTransform;

typedef enum {
  
  kShapeDrawFlag = 0x0001,
  kJointDrawFlag = 0x0002,
  kAABBDrawFlag = 0x0004,
  kPairDrawFlag = 0x0008,
  kCenterOfMassDrawFlag = 0x0010
  
} B2DDrawingFlags;

typedef void (^drawPolygonCallback) (CGPoint *vertices, NSInteger vertexCount, B2DColor *color);
typedef void (^drawSolidPolygonCallback) (CGPoint *vertices, NSInteger vertexCount, B2DColor *color);
typedef void (^drawCircleCallback) (CGPoint center, float radius, B2DColor *color);
typedef void (^drawSolidCircleCallback) (CGPoint center, float radius, CGPoint axis, B2DColor *color);
typedef void (^drawSegmentCallback) (CGPoint point1, CGPoint point2, B2DColor *color);
typedef void (^drawTransformCallback) (B2DTransform *transform);

@interface B2DDraw : NSObject {
  Draw *draw;
  drawPolygonCallback drawPolygon;
  drawSolidPolygonCallback drawSolidPolygon;
  drawCircleCallback drawCircle;
  drawSolidCircleCallback drawSolidCircle;
  drawSegmentCallback drawSegment;
  drawTransformCallback drawTransform;
}

@property (nonatomic, assign) Draw *draw;
@property (nonatomic, assign) unsigned int drawFlags;
@property (nonatomic, copy) drawPolygonCallback drawPolygon;
@property (nonatomic, copy) drawSolidPolygonCallback drawSolidPolygon;
@property (nonatomic, copy) drawCircleCallback drawCircle;
@property (nonatomic, copy) drawSolidCircleCallback drawSolidCircle;
@property (nonatomic, copy) drawSegmentCallback drawSegment;
@property (nonatomic, copy) drawTransformCallback drawTransform;

- (void)appendDrawFlags:(unsigned int)flags;
- (void)clearDrawFlags:(unsigned int)flags;

@end

Version data entries

4 entries across 2 versions & 1 rubygems

Version Path
joybox-1.1.1 vendor/vendor-ios/box_2d/box_2d_include/B2DDraw.h
joybox-1.1.1 vendor/vendor-osx/box_2d/box_2d_include/B2DDraw.h
joybox-1.1.0 vendor/vendor-ios/box_2d/box_2d_include/B2DDraw.h
joybox-1.1.0 vendor/vendor-osx/box_2d/box_2d_include/B2DDraw.h