Loading...
Processing Forum
Recent Topics
All Forums
Move this topic
Forum :
Share your Work
Programming Questions
Core Library Questions
Contributed Library Questions
Android Processing
Processing with Other Languages
Integration and Hardware
Library and Tool Development
Events and Opportunities
General Discussion
Sub forum :
Move this topic
Cancel
Contributed Library Questions
nardove
How to make a Slider increment by 2 in ControlP5?
in
Contributed Library Questions
•
1 month ago
I need a slider that increment its value by 2 because I need only the odd numbers within a range, any help will be much appreciated
1
Replies(3)
GoToLoop
Re: How to make a Slider increment by 2 in ControlP5?
1 month ago
Lazy fix:
Get the result from the slider (must be 1 of the whole data-types) and do this ->
result = result/2*2 + 1;
Leave a comment on GoToLoop's reply
hamzeen
Re: How to make a Slider increment by 2 in ControlP5?
1 month ago
Hi Ricardo, can you try this..
cp5.addSlider("sliderTicks2")
.setPosition(100,370)
.setWidth(400)
.setRange(25,1) // values can range from big to small as well
.setValue(13)
.setNumberOfTickMarks(13)
.setSliderMode(Slider.FLEXIBLE)
;
Leave a comment on hamzeen's reply
nardove
Re: How to make a Slider increment by 2 in ControlP5?
1 month ago
Thanks for both suggestions, all of them work but for my purposes I will have to go with GoToLoop anwser
Leave a comment on nardove's reply
Change topic type
Topic Type :
Discussions
Questions
No of days :
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
Change topic type
Cancel
Link this topic
Provide the permalink of a topic that is related to this topic
Permalink
Save
Close
Reply to nardove's question
Top
Reply
{"z3489723":[25080000002480100,25080000002480197],"z125760":[25080000002483169],"z21661383":[25080000002480107]}
Statistics
3
Replies
267
Views
0
Followers
Tags
Cancel
controlp5
slider
Actions
Permalink
Related Posts
ControlP5: Any way of displaying Ch...
[controlp5] how to change font size...
Modifying ControlP5 range sliders/l...
Why my controlP5 is blurry and how ...
Setting a second window undecorated...