Objective-C style Rock and Roll with a dose of finely aged user interface design

Hello world!

//
//  RSBloomEffect.m
//  PhotoTouch
//
//  Created by 23 on 2/22/11.
//  Copyright 2011 RogueSheep. All rights reserved.
//

#import "RSBloomEffect.h"

#import "RSScalarEffectViewController.h"
#import "RSScalarFloatFilterDelegate.h"

static NSString* const kRSBloomEffect_Identifier    = @"kRSBloomEffect";
static NSString* const kRSBloomEffect_Name         = @"Bloom";


@implementation RSBloomEffect

+ (id) effect
{
   return [[[RSBloomEffect alloc] init] autorelease];
}

- (id) init
{
   self = [super initWithIcon:[UIImage imageNamed: @"Exposure.png"]];
    // TODO: Need real icon
   
   if ( self )
   {
       
   }
   
   return self;
}

- (NSString*) identifier
{
   return kRSBloomEffect_Identifier;
}

- (NSString*) name
{
   return kRSBloomEffect_Name;
}

- (BOOL) wantsLiveUpdate
{
   return NO;
}

- (NSString*) effectDescription
{
   return NSLocalizedString(@"kBloomEffectDescriptionKey", @"Human readable description of the bloom effect");
}

- (NSDictionary*) defaultValues
{
   return [NSDictionary dictionaryWithObject: [NSNumber numberWithFloat: 0.25] forKey: kRSScalarFilterAmountKey];
}

- (id<RSEffectFilterDelegate>) instantiateFilterDelegate
{
   return [RSScalarFloatFilterDelegate scalarDelegate];
}

- (NSString*) filterShaderName
{
   return @"FilterBloom";
}

- (RSScalarEffectParameters) effectParameters
{
   return (RSScalarEffectParameters) { .minValue_ = 0.0, .maxValue_ = 0.5, .defaultValue_ = 0.25 };
}

@end

One Response

  1. Hi, this is a comment.
    To delete a comment, just log in and view the post's comments. There you will have the option to edit or delete them.

    February 27, 2011 at 02:42

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>